Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

User exit or BADI to not allow the user to change FI document when in approval status

Former Member
0 Kudos

Hi,

We have implemented workflows for approval of accounting documents (Customer). While the accounting document is in approval status, it should not be allowed for a change by the user.

Is there a BADI or User exit available in SAP so that we could write code based on some condition and provide error message to the user (later only display the accounting document).

1 ACCEPTED SOLUTION

raymond_giuseppi
Active Contributor
0 Kudos

Are you asking for 'parked' documents, in this case did you consider some validation rules (tr. OB28 with some user exit code to check workflow status)

10 REPLIES 10

sivaprasad_ml
Participant
0 Kudos

Hi Siva,

You can check for a BADI and put your validation there.

for eg : ACC_DOCUMENT badi definiton., try to implement this. It may help

Rgds

Sivaprasad

0 Kudos

Hi Siva,

We implemented ACC_DOCUMENT for substitution and it will be triggered only during save/posting document.

I am looking for some place where it even displays the document in change mode saying not allowed to change.

thanks for your reply, anyway.

former_member226519
Active Contributor
0 Kudos

Lakshmipathi
Active Contributor
0 Kudos
for approval of accounting documents (Customer)

Can you be specific what exact this accounting document is? From your post, it is not clear as to why an accounting document should go for approval as it is predominently, this accounting document would be generated based on other transactions from SD and MM side in which case, you need to correct that preceding document and not the accounting document.

0 Kudos

Hi Lakshmi,

This is not reference to any SD/MM document. Sorry, if I was not clear.

It is a customer invoice which is created via FV70, that is to be approved by the manager. While it is in the inbox for approval, the same cannot be changed.

We implemented implicit enhancement if the user tries to change the invoice via FBV2. However, if the user goes to FV70 and then clicks on tree on button, the list of parked invoices will be shown.

If the user double clicks on the invoice, it is open for change and the implicit enhancement written for FBV2 doesn't trigger.

thanks

Lakshmipathi
Active Contributor
0 Kudos

You can create a screen variant via shd0 where I think you can set either Tree Off or in Display only option

raymond_giuseppi
Active Contributor
0 Kudos

Are you asking for 'parked' documents, in this case did you consider some validation rules (tr. OB28 with some user exit code to check workflow status)

0 Kudos

Hi Raymond,

Thank you very much for your reply. Yes, I am asking for the parked documents. I would try this option.

If we write the validation using OB28 user exit at header level, any idea does this trigger irrespective of a change in header fields?

I will explore further on this option. thank you.

0 Kudos

AFAIK if you only indicate 'true' as condition, the rule will always been called during a change transaction before posting/parking.

0 Kudos

Thank you very much, Raymond. Much helpful.