I need to allow multiple managers to approve an issue at the same time

Darren Weaver March 3, 2016

I have two managers that need to approve an issue to transition to the next step; I am able to get two radio buttons to display:

"Request blue team manager approval"

"Request red team manager approval"

 

However when I click one of the buttons the issue automatically transitions.  I'd like to make my issue stay in the same status until BOTH managers click their respective buttons.  Also, the ordering of who approves first is unimportant, rather, the ability for either manager to approve in any order as long as both of them have approved.  Having one approve, transition, then another approve is not a good workaround.

2 answers

1 vote
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 3, 2016

I don't think you can do it without either an intermediate status, or code that can execute extra transitions when certain conditions are met.

 

Darren Weaver March 3, 2016

How do I code the transition to wait  until both buttons have been clicked? What language do I need for a development resource internally?

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 3, 2016

A bit of Java would do it, but there are off-the-shelf add-ons that can do auto-transition too - the one I'm familiar with is the Script Runner.

It can be done with a couple of flag fields and some clever conditions on workflow and no code, but that does need an intermediate status.

Steven F Behnke
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 18, 2016

As Nic indicates, I would do this purely with Update Custom Field post-functions and Value Field conditions. Knowing that fields that are not on the edit screen cannot be edited manually...

You can do this in 4 transitions off the top of my head...

  • Approval Transition A is visible to manager A if Approval B is not checked and updates Approval A field to checked
  • Approval Transition B is visible to manager B if Approval A is not checked and updates Approval B field to checked
  • Approval Transition C is visible to manager B if Approval A is already checked, updates Approval B to checked, and transitions to next status
  • Approval Transition D is visible to manager A if Approval B is already checked, updates Approval A to checked, and transitions to next status

If you need more detail or workflow, many people use a similar method but with Sub-Tasks.

 

You could also perform this logic in Script Runner or other scripting add-ons.

Marat May 20, 2019

@Nic Brough -Adaptavist- 

Hi Nic!

Can you tell us more about how to do "multiple approval" with ScriptRunner?

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 30, 2019

Let's say you have a flow that goes open -> approvals -> closed, but needs approval from someone in the blue team and red team.

You will need two flag fields (I usually set them up to record the current person who approves so I can report on it easily later, without digging through the history)

Two options:

1.  With one approval status:

  • Have a flow that has the three status, but has three transitions out of approvals
    • "Add blue approval" has
      • a condition on it saying "only members of the blue team"
      • a post-function that sets the blue flag field
    • "Add red approval" has
      • a condition on it saying "only members of the red team"
      • a post-function that sets the blue flag field
    • "Approved" has
      • a condition on it saying "only if both approvals present"

2.  With two status

Have a workflow that goes open -> approval 1 -> approval 2 -> closed

  • Open -> approval 1 is two transitions though,
    • transition 1 has
      • a condition saying "only members of the blue team"
      • a post-function that sets the blue flag field
    • transition 2 has
      • a condition saying "only members of the red team"
      • a post-function that sets the blue flag field
  • Approval 1 -> approval 2 is also two transitions,
    • transition 1 has
      • a condition saying "only members of the blue team"
      • a condition saying "only if the blue flag is empty"
      • a post-function that sets the blue flag field
    • transition 2 has
      • a condition saying "only members of the red team"
      • a condition saying "only if the red flag is empty"
      • a post-function that sets the red flag field

You can see the second one needs more work, but it has a massive advantage over the first - you can see which issues are waiting for one approval or two without adding any fields to your searches.

0 votes
Venu Madhav August 22, 2018

Hello Experts,

I have the same requirement and I need it urgently.

Could you please guide me with code or any alternate solution or manipulation.

Please please please...........

Thanks in advance

Suggest an answer

Log in or Sign up to answer