on 09-09-2010 8:47 AM
Hi Gurus,
Currently, i have used an implementation of the BADI BBP_DOC_CHECK_BADI and this implementation should trigger for Shopping Cart only. The problem is that it is also being triggered foir the Template. I am planning on setting up a flag in which if the flag is populated, it will skip the codes of the implementation (meaning the Template triggerred the implementation.) Else, it will continue with the logic of the implementation (meaning the SC triggered the implementation).
How can i know if the Shopping Cart or Shopping Cart Template is callign the BADI implementation?
Thanks in advance.
shockadis.
Hi
SY-UCOMM = 'SEL_YOUR_ITEM_SLCT'.
'SEL_YOUR_ITEM_SLCT' - you may use this field
muthu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
long back we used this trick to delete any vendors already assined to old template.
since we find lot of difficulty to identify the field it is ordering from old po templates . atlast we found this one only.
now i am wondering that OLD PO templates dont triger doc check badi validation too.
what are the data you are checking in the old po tempalte and not trigering your check badi.
muthu
I am sorry even i asked SAP how to differentiate both old PO template and other shopping carts but i did not get proper reply .
why one baby offering sugar and another baby giving salt
why dont you want not to validate doc check badi for old template shopping cart.
indeed templates carried bad data in my experience rather that regualr carts.
check badi for whole business object - bus2121
Let us wait for others reply.
Muthu
thanks for the effort muthu,
the scope of the develment only includes the shopping cart, not the shopping cart template.
i have checked that business object, but to no avail, i have not found anything useful.
assigning a vendor to an item is mandatory for shopping cart, but its not applicable to shopping cart template.
thanks again and regards,
shockadis.
How about appending a customer indicator field (Something like a indicator for old SC or template SC) to table INCL_EEW_PD_HEADER_CSF_SC and INCL_EEW_PD_HEADER_CSF..
Logic
When a New SC created populate this indicator (X), This means when we use the same SC again as template with this indicator we can able to identify whether its new SC or Template SC..
Hoop this will be helpful..
Thanks!!
Bharath
i dont want the badi to trigger when im using the shopping cart template. the implementation checks everything in the shopping cart. what should i check?
I have to repeat what Masa had suggested - check the SUBTYPE field of the shopping cart header. When the implementation of BBP_DOC_CHECK_BADI is called, the iv_doc_guid would be available to you. You could use it to call BBP_PD_SC_GETDETAIL at the beginning of the routine. In the returned header structure, check the SUBTYPE value. If it is 'ST' (for SC template), skip the rest of the implementation. You can NOT avoid the BADI implementation to be triggered completely. But with the above mentioned logic, it takes barely any time to run through and get out.
Hi,
Please go to transaction BBP_PD. You see "Subtype" field for document. You can check the subtype field for template in the BADI.
Regards,
Masa
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Masa,
the BADI implemenation needs to know the subtype before the shopping cart template is processed (while the user is making the template). the problem is, the field GUID wont be generated until the shopping cart template is processed. we will be using the GUID to select thhe subtype from table BBP_PDHGP right?
thanks for the reply.
shockadis
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.