cancel
Showing results for 
Search instead for 
Did you mean: 

Issue in Process Level Workflow

Former Member
0 Kudos

Dear SRM Workflow Experts,

I have following issue for workflow in SAP SRM 7.0

We have configured item level shopping cart approval workflow using process level configuration. Total four process Levels are configured for Audit/Deman Challenge/Tax and Financial approval.

Process Level Config Details

Level. Apr.Type Evval.Id Description Resp.Resover Decision Type

100 Approval ZEV_SC_DMCH_LEVEL1 Demand Challenge Workflow ZRR_DEMAND_CHALLENGE 4

200 Approval ZEV_SC_AUDT_LEVEL1 Audit Approval Workflow ZRR_AUDIT 4

300 Approval ZEV_SC_ITAX_LEVEL1 Tax Approval Workflow ZRR_TAX 4

400 Approval ZEV_SC_LEVEL3 Financial approval ZRR_COSTCENTER_APPROVE 4

We have a issue for the shopping cart with multiple items, once process level is applicable for first item it becomes mandatory for another items even though BRF expression rule for process level is not valid. It looks like my BRF event is executing only once for Shopping Cart and it's not getting trigerred for each line item.

Please suggest how I can resolve this issue.

Thanks & Best Regards,

Navnath Bondarde

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hello Everyone involved in this message,

In order to crack the logic of the Process controlled workflow, First we need to understand BRF expressions and their behaviour at run time.

1. The expressions defined under the evaluation events at Process Level analyze all the items of a shopping cart. So we have to be smart in order to write the expressions for the process level events. This becomes important if we ve complex evaluations for process levels.

In the example mentioned in this post, there are 4 process levels, all process levels will get activated if BRF finds at least one item in the shopping cart satisfying the criteria.

2. If you have parallel approval at one level for example, few items going to Finance Group, another group going to Audit Group and so on, then have one process level defined in your schema and group items by area responsibility and then send the respective items to different sets of approvers using decision type 4. Refer to implementation /SAPSRM/BD_WF_SC_RR_PGRP given by SAP - this implementation groups items for approval based on Purchase Group Values in the SC.

3. If you have multi step approval e.g. Finance team will approve whole shopping cart first, then Audit team, then Tax deptt etc, then you configure multiple process levels and define the agent determination accordingly at each step.

I hope this will clear few doubts for you....Please revert back with specific problems in case you need further assistance.

Regards

Virender Singh

Former Member
0 Kudos

Hi Bhanu,

Concerning the triggering of the events is due to an option in BRF expression, " Application Buffering " .

If the option is active this means that if the expression is used in multiple events, it is only calculated once and then re-used for the other events. Unmark this option and try again.

In my case i'm using a FM ( Expression) to map my process schemas it' working fine.

Rewards points for useful answers,

Regards,

Mário.

masa_139
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi,

The process step is for whole document. Only Decision Type has option for item level.

If you want to exclude some of items for approval, you can use GET_AREA_TO_ITEM_MAP method in the /SAPSRM/BD_WF_RESP_RESOLDER BADI.

Regards,

Masa

Former Member
0 Kudos

Thanks for quick response,

Actually I am using GET_AREA_TO_ITEM_MAP method in the /SAPSRM/BD_WF_RESP_RESOLDER BADI.

I am not creating the Responsibility Area for the items for which Approver not needed.

Please refer following code, please note AREA_ID field will be empty for the items for which approver not needed. For these items workflow is getting triggered with error "Strategy ZRR_AUDIT' did not determine any approver.

LOOP AT lt_item_to_area_map REFERENCE INTO lr_item_to_area_map.

AT NEW area_id.

  • For each area id a new responsibility area is created, this instance can

  • later be retrieved in

  • method GET_APPROVERS_BY_AREA_GUID to return the list of responsible

  • agents

IF not lr_item_to_area_map->area_id is initial.

lo_area = /sapsrm/cl_wf_area=>/sapsrm/if_wf_area~create_instance(

iv_area_type = /sapsrm/if_wf_process_c=>GC_AREA_TYPE_ADHOC

iv_leading_object_id = lr_item_to_area_map->area_id

).

ls_area_to_item_map-area_guid = lo_area->get_guid( ).

ELSE.

ls_area_to_item_map-area_guid = /sapsrm/if_wf_process_c=>gc_nil_guid.

ENDIF.

ENDAT.

IF NOT ls_area_to_item_map-area_guid EQ /sapsrm/if_wf_process_c=>gc_nil_guid.

ls_area_to_item_map-item_guid = lr_item_to_area_map->item_guid.

APPEND ls_area_to_item_map TO rt_item_to_area_map.

ENDIF.

ENDLOOP.

Thanks & Best Regards,

Navnath Bondarde

Former Member
0 Kudos

Hello,

I'm having a similar problem, as i'm trying to use the BADI /SAPSRM/IF_EX_WF_PROC_CONFIG method CREATE_PROCESS_LEVEL_CONFIG for determining the process levels i will have for the shopping cart (i have a different approval circuit accordingly to the total amount of the purchase) but this BAdI only is called twice: when the shopping cart is instanciated (no items) and when we add the first item, just before i can input the price. Therefore any other items i migt add to the shopping cart won't be considered, neither the amount of the first item.

Is this a bug? shouldn't the Badi be invoked each time i make changes to the shopping cart, either be modifiing the price in one item, or simply add new items?

Best regards,

Diogo Henriques

Former Member
0 Kudos

Hi Diogo,

I am also facing same problem. Did you get a solution for this. If yes please share with me .

Thanks in advance.

Regards.

Bhanu

Former Member
0 Kudos

Hi Masa

I am trying to run a process level workflow for Bid Invitation. The thing is the control is coming in /SAPSRM/IF_EX_WF_PROC_CONFIG~CREATE_PROCESS_LEVEL_CONFIG when I am creating the Rfx. Actually it should be triggered at the time of publishing the Rfx.

Can you please guide.

Regards

Pardeep Kumar

SAP SRM Technical Consultant.