cancel
Showing results for 
Search instead for 
Did you mean: 

BRF-- How to reevaluate approvers if document is changed?

former_member184111
Active Contributor
0 Kudos

Hi Forum,

We have implemented the BADIs /SAPSRM/BD_WF_PROCESS_CONFIG and /SAPSRM/BD_WF_RESP_RESOLVER for dynamically creating process levels and assigning approvers to the same.

If we create a new RFQ the BADI triggers as soon as RFx Type is selected and Start button is pressed, since there is no data in the RFQ at this point approval tab shows only the Automatic Approval step but even after entering the relevant data in RFQ screen like plant and item details and publishing the RFQ, it shows only the same Automatic Approval step and approvers are not determined according to our logic since the BADI is not triggered.

This works fine if we copy from an existing RFQ since it already contains the relevant data but in the copied RFQ also if we change the field values the approvers are not reevaluated.

Is this the standard behaviour of SRM system? If yes how to reevaluate of trigger the BRF logic again on publishing the docunent to changing the field values?

Thank you,

Anubhav

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member184111
Active Contributor
0 Kudos

I followed the below steps

1. Create static process levels for the corresponding process schema

2. Create an implementation foe the BADI /SAPSRM/BD_WF_PROCESS_CONFIG and put the beloow code

CS_PROCESS_LEVEL-RESOLVER_NAME  = 'YOUR_RESP_RESOLVER_VALUE_HERE'.

    CALL METHOD IO_LEVEL_SERVICE->CREATE_PROCESS_LEVEL
      CHANGING
        CS_PROCESS_LEVEL = CS_PROCESS_LEVEL.

3. Implement the BADI /SAPSRM/BD_WF_RESP_RESOLVER methods /SAPSRM/IF_EX_WF_RESP_RESOLVERGET_APPROVERS_BY_AREA_GUID and /SAPSRM/IF_EX_WF_RESP_RESOLVERGET_AREA_TO_ITEM_MAP to determine approvers and assign to corresponding levels.

Thank you,

Anubhav Jain