on 11-02-2012 8:08 AM
Hello experts,
we use the badi BBP_DOC_CHECK_BADI.
In the BADI we call the function BBP_PD_SC_GETDETAIL and check all positions of the shopping cart (Tables: e_item).
Now we want to check only the approved items. And not the rejected item. Is it possible?
System: SRM 7 EHP 1
Regards,
Florian
Yes it is possible. You can find the status of the shopping cart line items in the table "E_STATUS" in the FM "BBP_PD_SC_GETDETAIL".
With Regards,
Malay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Malay,
thank you for your reply!
In the table "E_STATUS" we received the following values:
1 5091B51739CB65CDE100000002886807 I1015
2 5091B51739CB65CDE100000002886807 I1021
3 5091B51739CB65CDE100000002886807 I1038
4 5091B51739CB65CDE100000002886807 I1106
E_STATUS : The guid and the status is from the header (not from the item?).
We have a shopping cart with two items. One item was approved and the other item was rejected. The shopping cart is partially approved. Can we check the status of the item separately?
Regards,
Florian
Hi Florian,
How is your workflow set up in SRM 7.0? Application controlled or Process Controlled? Also, Do you guys have workflow defined at line item level? If one line item is approve then create PR or PO? While other one goes into requester inbox to accept rejection?
Because if you do not have that line item level workflow feature then other workflow if one line item rejected it goes into requester inbox for accept / reject and once requester make decision lets say accept the rejection of one line item that line item gets deleted and Del_IND is set. You can find that in the Function module.
There is one FM you can try which give details on line item level BBP_PD_SC_ITEM_GETDETAIL where you have to give GUID of line item not SC.
Thank you
Ritesh
Hi experts!
We have solved this problem!
Enclosed you find the solution:
System/Settings:
SRM 7 EHP 1
WF: Process Controlled (line item level)
Code:
DATA:
dummy TYPE /sapsrm/wf_agent_id,
header_guid TYPE guid,
es_process TYPE /sapsrm/s_wf_process.
header_guid = ......
CALL METHOD /sapsrm/cl_wf_apv_facade=>get_current_process_state
EXPORTING
iv_document_guid = header_guid
iv_agent_id = dummy
iv_language = sy-langu
* iv_workitem_id =
IMPORTING
es_process = es_process.
Result:
The item status is located in the following deep-structure:
es_process-> DECISIONSET_LIST-> ITEM_STATUS_LIST-> ITEM_STATUS
ITEM_STATUS:
APPROVED
REJECTED
INQUIRED
OPEN
<null>
Many thanks for your help!
Regards,
Florian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Florian,
check the fields DEDUCT_IND and REJECT_WI.
Should be not empty until requester accepts rejection.
Best Regards
Konstantin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Florian,
There is another workaround to find out whether shopping cart item is approved or not.
If Shopping cart line item is approved, then follow-on document will get created immediately.
If shopping cart line item is not approved, then follow-on document object for that line will not be available in the system.
So you can retrieve SC line item GUID from CRMD_ORDERADM_I table.
Then input it in BBP_PDBEI table to check whether any value exist in BE_OBJ_ITEM or BE_OBJECT_TYPE or BE_OBJECT_ID. If no value exist, that means line item is awaiting approval or not approved or rejected.
Using this you can filter out line items which are approved.
Hope this helps,
Cheers,
Ravi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.