Participant Mapping - NextApprover

Confluence User - 25 May, 2018

Hi There,

I have a simple approval workflow where multiple approvals are needed and multiple approver email addresses are known upfront (no need for dynamic approval solution).

I use a combination of beanshell and form update tool plugin functions to loop and clear/reset to the next approver's details and all new values are set as required.  Issue is however that when 1st approver approves, 1st status is set and workflow details cleared and datalist filter works as it does not reflect a pending assignment for 1st approver anymore (by now it should only open for 2nd approver) yet a form still opens up immediately again for 1st approver where it should be for 2nd approver. 

In my process, I also have "Show The Next Assignment When Completed" unticked so I'm not sure why the 2nd approvers form opens up for 1st approver again.  Am I perhaps missing a beanshell to indicate assignment completed? 

 

datalist;assignment

8


28 May, 2018
confluenceUser
confluenceUser

HI, not to sure how ur flow work. Maybe you want to attach a sample app here for others to understand your app?

What I think is maybe you mapped the participant to a group of users? In this case, anyone in the group is allowed to complete the assignment. I think you can map to workflow variable and assign only 1 user to the workflow variable after the previous 1 complete the assignment.

29 May, 2018
confluenceUser
confluenceUser

Hi Panda,

For server access security reasons I have to map approver role in "Map participants to users" (I've not assigned to "approver" workflow variable in participant mapping though). 

My app loops and sets 1st approver as workflow variable approver one by one and clears this info each time until next assignment/approver.  Yet I still get below.  Requirement is that only one approver should be stated in 'next user.'

INFO  29 May 2018 13:18:37 org.joget.workflow.shark.WorkflowAssignmentManager  - [processId=4100_App, processDefId=App#10#App, participantId=Approver, next user=[approver1, approver2]]

30 May, 2018
confluenceUser
confluenceUser

I think u need to provide sample app or screenshot. Without it, I find very hard on understanding what you had done.

30 May, 2018
confluenceUser
confluenceUser

Hi Panda,

Here's my loop process.  Objective is that a specific 1st, 2nd and 3rd approver need to be selected for the approval activity.  Not any of the users linked in the approver group.  Form and workflow variable values for the temporarily set 'status' and 'approver' values are then set as other fields after the approval activity is completed.

30 May, 2018
confluenceUser
confluenceUser

Hey there,

I think my design here is simple enough. We don't need any script to update stuff and compare. You can consider this.

31 May, 2018
confluenceUser
confluenceUser

Thank you very much Walter.  I'll give it a try.

30 Aug, 2018
confluenceUser
confluenceUser

Did this workflow work

30 Aug, 2018
confluenceUser
confluenceUser

Hi Ashvitha,

Unfortunately I could not use it for the fact that we have set plugins in place for "map participants to users" limiting the use of this logic.

I managed to get it to work by using field id's as temporary ids eg: "approver" across all approval loops and after one loop completes, setting the value of approver as approver1, clearing approver, then next loop to set approver2, etc.  

RELATED QUESTIONS

Your answer


To answer a question you'll need an account.

Print