Saturday 18 July 2015

Workflow : Demo12-Uses of Local Workflow in Main Work flow

-------------------------------------------------------------------------------------------------------------------------------
Post Summary: In the process, local workflow is used to send a mail to the user.
The local work flow is triggered by a local event defined in the work flow header.
The main work flow should wait ( without complete) so that the local work flow can be processed successfully. If the local event triggers the local work flow and simultaneously the main work flow completed then the local work flow is not processed and set as logically deleted.


  • Go to Tx- SWDD and start creating a new work flow and save it.



  •  Provide the name and description and continue.

  • Go to the header of the work flow.


  • Go to the tab under local events in  version dependent tab.


  • Here provide a name  like below. This is a local event defined in the work flow which can be later used to trigger any local process like starting a local work flow or etc.


  • Double click on the step and choose event creator. As already we have a local event defined in the work flow header, This step evnet creator will trigger the local event which in turn will process the local work flow in the main work flow.


  • Provide the event creator step name and the triggering event i.e the local event name. Continue.




  •  Now after the event creator step let's define a local work flow. 

  • Choose local work flow.


  • Choose the local work flow name and the local event who is going to start it. Continue.


  • The result is something like this. So the local work flow is now a parallel branch of the main work flow.




  •  Let's define a send mail step in the local workflow.

  • Provide the mail title, subject and continue.


  • Fill the task name and continue.




  •  Now there are two parallel branches at the event creator point. Ons is triggering the local event which will start the local work flow and sending the mail and the other is proceeding ahead with the main work flow to complete it. Let's test it.



  •  Check Tx- SWBP .

  • Execute.


  • Check the work flow log.




  •  Click on the Icon.

  • As the  main work flow is completed, the local work flow is logically deleted. That means it is not executed. So to trigger the local work flow the main work flow should wait after triggering the local event. 


  • So let's put a user decision step so that the main work flow will wait.




  •  Select a User Decision step.

  • Provide the user decision step details. Continue.




  •  Now activate the work flow and execute.

  • Execute.




  •  As per the design if we select yes or no the main work flow will finish without triggering the local work flow. Select Cancel. So that the main work flow will wait for the user decision for either Yes/No .

  • Check the work flow log.




  •  Select the icon.



  •  So here is the track log.

  • here we have a mail in the Tx- SBWP.






-------------------------------------------------------------------------------------------------------------------------------


No comments:

Comments system

Disqus Shortname