This Document is about how paralel approval process can be done in Workflow.

Scenario:

Some cases for one approval we

need send separate approval task to many approvers. If all the Approvers approves then only the next step should be processesed in workflow.

Process:

In Workflow We have blockstep type through which we can achieve this parallel approval process.

Step1.Block Step Type

We need to create Step using Step type Block.

BLOCK_1.jpg

Step 2:

In Control Tab we need to choose Block type as ParForEach

Then we need to choose Multi line element in Parallel Processing

/wp-content/uploads/2014/01/block_2_354438.jpg

STEP 3:Determine Approver

Choose Activity step type and pass _ZAPPROVER_LINE to the work item container
it can be used to determine Approver

End Condition we can give in which condition this loop should stop All the pending tasks will be cancelled

/wp-content/uploads/2014/01/block_7_354442.jpg

/wp-content/uploads/2014/01/block_4_354447.jpg

/wp-content/uploads/2014/01/block_5_354448.jpg

STEP4: User Decision –

Approval task for Approvers
Choose Step Type User Decision for Approval Task
In Expression select Approver Elemet which has Approver User Id’s

/wp-content/uploads/2014/01/block_3_354452.jpg

STEP 5:

According to User Decision Next step can be Processed.

Regards,

Deepika.

To report this post you need to login first.

14 Comments

You must be Logged on to comment or reply to a post.

  1. Rashmi ranjan behera

    Hi please guide as i have to impliment a workflow.My scenario is i have to change a particular user status when 2 approver will approve it.That is i have 3 status like A,B,C.When the user will change the status to “B” workflow should get initiated and after the approval from both the person the status should get changed to C.Please guide me

    (0) 
    1. Deepika Chandrasekar Post author

      Hi,

      You can have event for status change, in that event you can check the status = ‘B’ trigger Workflow manually using

      I hope you know how to create Workflow.. if else please check this link

      Workflow Scenario – ABAP Development – SCN Wiki

      CALL FUNCTION ‘SWE_EVENT_CREATE’

            EXPORTING

              objtype           = ‘BUS2000111’

              objkey            = key

              event             = lv_event”event name

            TABLES

              event_container   = lt_event_cont

            EXCEPTIONS

              objtype_not_found = 1

              OTHERS            = 2.

          IF sysubrc = 0.

            COMMIT WORK.

          ENDIF.

      Then in Block you need to add user decision step type and in block -> multiline element have two approvers and use that variable element_line as expression in user decision . follow the steps for end conditions like if one approver rejects it keep flag and end the block.

      Take the result from user decision from element result and change the staus according to decision in activity step type.

      Regards,

      Deepika.

      (0) 
    1. Rashmi ranjan behera

      Hi

      thanks for Ur reply,i don’t have much knowledge about it.can you please clarify me what is the difference between sequential workflow and block workflow.My requirement is that it should simultaneously go to both approvers.Is it possible in block ?please explain me as i am new to SAP

      Thanks in advance

      (0) 
      1. ajeet choudhary

        yes, it is very much possible through block.Block in workflow is generally used when we have to send work item for approval to amy person simultaneously whereas in sequential approval goes one by one. Hope it helps.

        Please refer Pactical workflow for SAP book for starting workflow development,

        rgards

        Ajit

        (0) 
  2. Prateek Agarwal

    Hi Deepika,

    Great Blog!!…:)

    Could you please let me know in case of parallel processing, when one of the two agents reject the request it is going to the requester, but when it resubmits it goes only to that agent who rejects it previously, how can this be achieved?

    Regards

    Prateek

    (0) 
  3. Pavan Kumar

    Hi ,

    How are you getting value into ZAAPROVERID?

    and in the step 3 , how value is flowing from _ZAPPROVER_LINE to ZAPPROVER?

    can you please elaborate on this?

    (0) 

Leave a Reply