Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Control the parent ticket status based on the count of approved subtasks

VVC August 15, 2024

Have an internal business requirement where we would like to control the displaying of a specific status on the parent ticket based on the count of subtasks that are approved.

For instance, a parent change ticket should display the status "INSTALLED" only when 2 subtasks or more (namely one subtask for QA and another for PROD) are in approved status. Is this something possible to script in Script Runner and can anyone please share a working prototype?

1 answer

Suggest an answer

Log in or Sign up to answer
0 votes
Aron Gombas _Midori_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 22, 2024

This is absolutely possible with ScriptRunner, but if you don't have programming experience I think you can implement it also with automation rules.

You would have to trigger an automation rule by "status transitions" (of the subtasks) and test the  status of the siblings (maybe with running JQL queries?), then update the status of the parent.

VVC August 22, 2024

Hi, Aron - I'm not looking to update the status of the parent ticket automatically as there is some vetting process involved prior to setting up the parent status manually.

It looks like the only option is Script Runner and trying to find some references for scripting. I should not be able to change to a specific status on the Parent ticket, if I have a subtask that is not marked as Done.

VVC August 22, 2024

Looks like one of the conditional parameters in the workflow status transition is helping us out in this scenario. If a subtask is NOT in Done status, then the Parent ticket won't display the desired status transition to progress to next level.

New Workflow Condition.jpg

VVC August 22, 2024

The only downside to this out of the box condition in the workflow is that it bypasses the condition check if there is no subtask created in the first place.

Would it be possible for Jira in enforcing user(s) to have a subtask created?

I understand that this could be a simple process related thing but we're looking for Jira system to enforce this process technically.

TAGS
AUG Leaders

Atlassian Community Events