• Community
  • Products
  • Marketplace Apps
  • Questions
  • How do you allow a parent CR to not progress to the next transition until all CR-Subtasks have been closed? I need the button to be visible but throw an error message when clicked.

How do you allow a parent CR to not progress to the next transition until all CR-Subtasks have been closed? I need the button to be visible but throw an error message when clicked.

How do you allow a parent CR to not progress to the next transition until all CR-Subtasks have been closed? I need the button to be visible but throw an error message when clicked.

1 answer

0 votes

There's two questions here, sort of.

1. To prevent a parent from moving on while it's got open subtasks, the standard approach is to use the "subtask status blocking" condition. That lets you set conditions on a workflow like "only show this transition if all the subtasks are in status X, Y or Z"

2. Answer 1 above works, but does not meet your "visible/error message" criteria. In Jira, a "condition" stops a user from seeing the option to try a transition. What you're asking for is a "validator" - these don't stop a user seeing or starting a transition, but stops them completing it if the data is wrong.

I've not seen a plugin that will provide a validator that will look at the subtask-status, so I think you might need to do a bit of coding. Of course, you can "borrow" the code from the condition, it'll be almost identical.

Note - I use the condition, and have never really needed to look for a validator style way to do it, so I don't want to tell you there is nothing out there, just that I've never looked.

Thank you. Would you be able to tell me how I can view the code for the blocking condition?

Ah, the one I use is in Jira off-the-shelf, so it's part of the core code, and that's closed so I can't share it.

If you've got a commercial licence, you can download the source for Jira from your my.atlassian account and find it in there. Shouldn't be hard to extract the condition and convert to a validator.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Nov 29, 2018 in Marketplace Apps

How to set up an incident workflow from the VP of Engineering at Sentry

Hey Atlassian community, I help lead engineering at Sentry, an open-source error-tracking and monitoring tool that integrates with Jira. We started using Jira Software Cloud internally last year, a...

1,375 views 0 8
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you