cancel
Showing results for 
Search instead for 
Did you mean: 

Map data from class CL_PT_REQ_WF_ATTRIBS with workflow

former_member16044
Active Participant
0 Kudos

Hi All,

I am using the standard class CL_PT_REQ_WF_ATTRIBS with DUMMY method for approval workitem which uses webdynpro ABAP. The webdynpro person is passing one variable RESULT after the approval, and RESULT with its value is shown in the log but there is no workflow container element named RESULT in the workflow. so, I created one with that name. But when I use this vaiable in the task after mapping, it is not showing any value. Am I missing something or doing anything wrong?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

If i understood your requirement correctly, you are

trying to complete the decision task programmatically.

Though you are using SAP_WAPI_WORKITEM_COMPLETE,

before completing the workitem you should update the

container elemets _RESULT, WIRESULT with correct

values ( either 0001, 0002 etc based on the decsion)

using SAP_WAPI_WRITE_CONTAINER. Are you doing this?

Edited by: Saud Shaikh on May 18, 2011 10:54 AM

former_member16044
Active Participant
0 Kudos

Saud,

Thanks for the reply. I was doing incorrect binding between task which has the class and workflow container. My doubt was, even thogh there's no explicit binding between the class and task container element, how data passes to task.

All,

Thanks for you suggestions, during which I learned alot.

Answers (1)

Answers (1)

bpawanchand
Active Contributor
0 Kudos

Hi

After creating the container element in Approve Leave request Task did you try to refresh the buffer and Refresh Org assignement.

And also make sur ethat the webdynpro developer is writing back the decision to Approve Leave request Task

and also make sure you do a proper bidning between Task container to workflow container. Check in the workflow log whteher in atleast the task container the value is populate. Also please let us know how the webdynpro developer is assigning the result value is it something like he is using SAP_WAPI_WRITE_CONTAINER function module then make sure that the container element is CAse Sensitive. so ask him to define as you decalred in the task/workflow container.

Regards

Pavan

Edited by: Pavan Bhamidipati on May 17, 2011 2:18 PM

Edited by: Pavan Bhamidipati on May 17, 2011 2:18 PM

Edited by: Pavan Bhamidipati on May 17, 2011 2:19 PM

former_member16044
Active Participant
0 Kudos

Pavan,

Thanks for your suggestion. Dynpro person is using sap_wapi_workitem_complete FM to complete the workitem as well as to update the conatiner element RESULT. I can see that in log, but it is not updating the value when I use it in task, it means it is not in workflow container also.

Former Member
0 Kudos

Hi RahulKulkarni,

So the task to workflow binding is done but still the data's are not passed to workflow, right?

Try to clear the buffer using the transaction SWU_OBUF.

Still if the probelem is not fixed, then delete the current task and create a new task with the binding.

Thanks,

Viji.

bpawanchand
Active Contributor
0 Kudos

Hi,


 I can see that in log, but it is not updating the value when I use it in task,
 it means it is not in workflow container also.

A bit confusing You are saying that you able to see the value in the log but what do you mean by when you are using in the task.?

Can you please be more clear.

See what I would suggest to re check is that when he is calling the SAP_WAPI_WORKITEM_COMPLETE make sure you are executing COMMIT WORK after executing FM.

And more over can you clear me that when you are executing the workitem then what is the status of the workitem I mean completed or still inprocess.

Regards

Pavan

Edited by: Pavan Bhamidipati on May 17, 2011 3:58 PM