Skip to Content
0
Former Member
Dec 12, 2011 at 06:15 PM

Absence workflow - Changing Req. status

107 Views

Hello, I'm using workflow for absence requests in ESS.

I created a FM with the following code, which is used in a BOR method and included in a workflow task:

  • get request from guid

CALL METHOD ca_pt_req_header=>agent->get_request

EXPORTING

im_request_id = request_id

IMPORTING

ex_request = request.

  • Change state only for existing request object

IF request IS BOUND.

  • execute state transition

CALL METHOD request->initiate_state_transition

EXPORTING

im_transfer_event = event

IMPORTING

ex_new_status = new_status.

ENDIF.

COMMIT WORK AND WAIT.

When I test the workflow, it doesn't change the status of the request, but if I have tested the FM and the method and I can change the status request. I have checked the bindings and it seems ok.

Any help?