cancel
Showing results for 
Search instead for 
Did you mean: 

Able to submit a shopping cart with errors

Former Member
0 Kudos

HI there everyone,

First of all, our SRM version is 7.02 of an OneClient implementation.

We have implement the DOC_CHECK_BADI to validate some of the data during the creation of the shopping cart.   We generate error messages that prevents the creator from ordering the cart (i.e when they push button "Order").

However, during the approval process (Approval with Completion) the approver is able to change the data that would cause an error, but the DOC_CHECK_BADI  does not prevent the approver from approving the SC (i.e. when they push button "Submit").

As a result, the shopping cart continues to be processed, even though it contains errors.   The errors do appear when the user presses the "Check" button, but they do not appear when they "Submit" the cart.

During the troubleshooting I was able to determine that  DOC_CHECK_BADI gets called with the IV_MODE = "U" and IV_SAVE = "X" during the "Order" process and then returns the to application, however, during  the "Submit" process, it does call with the same values above, but it also calls the BADI a second time with the IV_MODE = "T" and IV_SAVE = "", and the SC is then approved and moved on the the next approver.  I am assuming that this is the reason it allows the SC to be saved/processed with errors.

I've looked at configuration in SPRO looking for a setting that would allow the "Submit" action have the same behaivour as the "Order" action, but I have not be able to do so.

I would appreciate any insight in this matter.

Thanks in advance.

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi there,

Once again, thanks for your input.

As it turns out, this was an error in SAP and they created an OSS note to correct the problem.

The OSS note is 1807067.   I've applied it and it corrected the problem.

Former Member
0 Kudos

Hi Joe,

     I have been searching the OSS note but seems to be that OSS note is not released. How have you implemented it?


Thanks in advance for your help.

Jose.

Former Member
0 Kudos

Hi all,

     I answer myself. I have fixed the problem using the OSS note 1361411 (disallow approver to delete items on a completion level). I've applied it and it corrected the problem.

Best Regards.


Former Member
0 Kudos

Hi there,

Thank you for your replies.

Lin:  The approval step needs to be approval with completion, so as SAP allows it, the use can make changes to the shopping cart, such as adding/changing a vendor, perform account coding, etc...

Jeff: We do have a DOC_CHECK_BADI enabled, and the "hard error" messages do appear when "Check" is clicked, but when the user clicks the "Submit" button the cart is saved and the process continues.   This is not the same behavior that happens when the SC is first created and the use clicks the "Order" button.

As an example, a SC can not be "Order"ed without a Shopping Cart Name (SAP standard message), but if one of the approvers with completion removes the Shopping Cart Name, even though the "hard error" appears when the "Check" is performed, the use is able to save and continue by clicking on the "Submit" button

Thanks in advance for your help.

Former Member
0 Kudos

Your developer should be able to make the same check using the DOC_CHECK_BADI that is required.

Former Member
0 Kudos

I think you can use config to avoid the approver to change the SC.

In process levels, choose A (approval) , not C (Approval with completion).

A (approval): approver cannot change the sc;

C (Approval with completion): the approver can change the sc.