Im writting a report to display retrospectively the usernames of the last approvers of a company's purchase requisitions for auditing purposes.
After searching the forum I found a way to do this:
1) use SAP_WAPI_WORKITEMS_TO_OBJECT to retrieve the Workitem Id of PR.
2) read table SWWWIHEAD with TOP WI_ID as the workitem id and WI_TYPE as W and WI_STAT not equal to Completed
3) use SWWWIHEAD-WI_ID from previous step in SAP_WAPI_WORKITEM_RECIPIENTS to get the recipients.
Does this sound right to you?
should not wi_stat be EQUAL to 'completed' instead?
why can I not just do select wi_agent from SWWWIHEAD after getting wi_id from the first step?
Thanks in advance for your help.