PR release workflow - issue in mulitple level approval
I have developed a new workflow for PR release strategy.
Business object: BUS2105 ( Purchase Requistion )
Triggerring event: ReleaseStepCreated
Step1: Workflow started ( Releasestepcreated)
Step2: Approve PR ( Agent1)
If yes --> Released to next level (Agent 2 )
If No --> Rejected and notified initiator
Step3: Check if final PR released happened(loop)
If Yes --> Notify intiator and exit
If no --> based on next release code and release
group get the next level agent and go to
Step4: Workflow ends.
For single step PR release, workflow is working fine.
When PR created with multiple level release, a workflow triggers and notifies the 1st level agent, when the agent releases the PR at 1st level and saves it , workflow proceeds to further steps to find the next level agent . At the same time, when 1st level approver releases the PR for the next level, this same workflow triggers again and notifying the 1st level approver again. ( ie. 2 workflow instance got triggered for the same document )
If anyone faced similair kind of issue, please address me,
or is there anyway to restrict the triggering event subject to one time trigger for a document?
Please reply back. thanks in advance.