cancel
Showing results for 
Search instead for 
Did you mean: 

Find all the recipients after workitem executed

shah_viraj
Active Participant
0 Kudos

Hello All,

     I have a workitem number say 711461 which is residing in the inbox of three people A, B and C. Now, before the execution of the workitem 711461, I can have the recipient list using FM SAP_WAPI_WORKITEM_RECIPIENTS.

Now, my problem is I want to have the same recipient list (A, B and C) after the execution of workitem. FM SAP_WAPI_WORKITEM_RECIPIENTS does not give this list once the workitem is executed.

Please guide me how can I achieve this?

Thanks,

Viraj.

Accepted Solutions (1)

Accepted Solutions (1)

paul_bakker2
Active Contributor
0 Kudos

Hi,

You could execute a method to do the agent determination in the step before (the real dialog step), and store the resulting agents in the workflow container.

But I have to ask - why would you want this information?

cheers

Paul

shah_viraj
Active Participant
0 Kudos

I have a customized PO approval workflow. Now, I have requirement of a report where they want all the persons name who could approve that PO(All the agents who has PO workitem in their inbox before PO was approved) if the PO is approved already.

paul_bakker2
Active Contributor
0 Kudos

Hi,

I still don't understand why. If a user asked me for that report, I would question/fight it.

If they want to know who is receiving PO approval workitems, they could look at the agent list for approval items that are currently in status READY. This will give them an up-to-date list.

This is information you get for free, without having to create / run a custom report.

cheers

Paul

shah_viraj
Active Participant
0 Kudos

Well Paul this is not the only requirement for what the report is made for. The report is basically giving information about PO status tracking. So, if PO is yet not approved, it will show all the agents under whom it is pending for approval. And if PO is already approved it should show the person who has approved and the persons who could possibly approved it.

paul_bakker2
Active Contributor
0 Kudos

Hi,

OK. The users can get (almost) all this information by looking in the workflow log.

Except for the set of current agents and the set of could-have-been agents.

This doc shows you how to make a simple report showing all the current agents of a workitem:

For the agents who 'could have' approved a workitem, I think (like I said above) your best bet is to store the set of responsible agents in the workflow, and get your report to retrieve them from the container afterwards.

Unless someone has a better idea..!

good luck

Paul

shah_viraj
Active Participant
0 Kudos

Thanks paul for providing the best possible way..!!!

Answers (0)