cancel
Showing results for 
Search instead for 
Did you mean: 

parked SC the agents must be updated

Former Member
0 Kudos

Hi Friends

I don't intend to construct an atomic bomb all what I need is just

an advice how to achieve this requirement. We are using SRM 5.00.

After editing the SC which was parked the agents must be updated

since the Cost Center was changed by the user. Later in the "approver preview"

after ordering the SC the agents were not updated they are still the

same as before. The User has the Security Level 4 in the personalization.

I have implemented EBP_WFL_SECUR_BADI for this purpose as follows. All my efforts went into vain pls.

help.

Regards

Marco M.

IF i_e_header-created_by =  actual_user.
 
 SELECT * FROM sww_wi2obj INTO TABLE lt_sww_wi2obj WHERE
    instid = object_id
    AND typeid = 'BUS2121'.
 
 
    LOOP AT lt_sww_wi2obj INTO ls_sww_wi2obj.
      SELECT * FROM swwwihead INTO TABLE iswwwihead WHERE
        wi_id = ls_sww_wi2obj-wi_id AND
        wi_stat = 'WAITING'.
      IF sy-subrc = 0.
        new_sec_level = 2.
        EXIT.
      ENDIF.
    ENDLOOP.
 
ENDIF.

Accepted Solutions (1)

Accepted Solutions (1)

masa_139
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi,

Which workflow template do you use?

What is your implemented logic for agent determination?

Standard workflow template finds approver from Organization structure. Is is not based on Cost Center.

Regards,

Masa

Former Member
0 Kudos

Hi Masa,

thx for your reply.

Currently we are using WF Template WS90100003 -> Two Step Approval of shopping cart.

Indeed you are right in our case Workflow finds approver from Organization structure too (ppoma_bbp),. It is not based only on Cost Center.

We have within ppoma_bbp two additonal attributes for "Approver of the Budget" + "Approver of Cost center"

Z_BUDG_GEN + Z_KR_GEN. These attributes getting organisational units or persons assigned. Furthermore there is also

a customizing table for the WBS Elements assigned to fixed person. The user can change his privously made entries in the parked

SC to WBS element, in this case the agents should be updated.

Note:

Before clicking order button at the last step after changing account assignments in the approver preview

I can see the correct agents but after saving the SC I see the privously agents again. Approver preview

shows right agents but actually in the t-code bbp_pd you dont see them, still displaying the wrong agents.

Regards

Marco

masa_139
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi,

It looks you have custom workflow template and custom logic for agent assignment.

Where do you assign approver agent? If it is assigned by workflow container biding, please check the workflow log.

What is the test result for normal SC order process without save/park? Does it get correct approver?

Regards,

Masa

Former Member
0 Kudos

Hi Masa

To your questions pls see inline.

Where do you assign approver agent?

I don't know exactly where ?

It was not implemented by me. I am also tryingto find it out. Where this happens normally, do you know that ?

What is the test result for normal SC order process without save/park?

Everything works well

Regards

Marco

Former Member
0 Kudos

Hi,

I think your security badi logic won't trigger at all.. the workflow instance will be created only when you order the SC not at the time of SAVE the SC. so the loop statement won't be successfully called. that is the reason system is not restarting the workflow..

is the workflow copy from standard workflow template WS10000031? does it have any custom role attached in it? you can do one thing.. if it is development system, then put the infinite loop in security badi and debug through SM50..

Saravanan

Former Member
0 Kudos

Hi

in order to debug through the security badi it is not necessary to put an infinite loop.

Or do you mean for other purposes ?

Yes you are right I thing the same, at the time of Order SC (clicking on order button ) the breakpoint in the secure badi doesn't stop.

This is a common problem in this case. Normally I am expecting Secure badi call at the last step-> order SC.

Even I have deleted the whole logic in the badi and wrote only new_sec_level = 2

The result was the same as before

Regards

Marco

Answers (0)