Automatically change the issue status from "completed" to "in progress" after new sub-task added.

If a issue has been in the status of "completed", then add a new "sub-task" to it. The issue's status should automatically be changed to "inprogress". But now, it still in status of "completed".how to config this?

3 answers

1 accepted

0 votes
Tarun Sapra Community Champion Feb 18, 2014

You can do as suggested by Nic, or you can write a script in the post function of create transition which validates that the current issue is a sub-task of project X and if it's parent is in state "complteted" then to transition the parent to "in-progress"

Thank you for reply . I have added a post function on create transition . The name of this function is "Transition parent issue" , but it doesn't work ,any suggestion??

How have you configured it? You must need to do some, as you need to tell it what transition to run, and youhaven't told us how you've configured it.

Tarun Sapra Community Champion Feb 23, 2014

Hi Xin,

In the "Transition parent issue" postfunction provide the transition ID of workflow of parent which is from the status of "completed" to "In progress"

That is my mistake , I forget to click "Publish Draft".Thank you for your support. And I can compare the status by using "parentIssue.get("status").getName() == "Completed"" , Is there a document I can see the property of the object? just like "issue" or "parentIssue" or "status",because when I want get some property from parentIssue, I don't know what the object parentIssue like , So I need this

another question :

What I need is when create a sub-task for US which is Completed , I need the parent issue changed to "in progress".

now the parent issue can change to the "in progress" , but the parent of the parent issue can't be changed , the change is not Inheritance。

My configuraiton is :

I have two workflow , one for sub-task A , one for story B.

I add the "Transition parent issue" postfunction to A ,the transition is "Create"

I add the "Transition parent issue" postfunction to A ,the transition is "In Process"

the Conditional execution are all "parentIssue.get("status").getName() == "Completed"


Fix it , the relationship between issue and parent issue is not "parent" , is linkd , so we need to add a "Transition linked issues" post function and the "Conditional execution" is linkedIssue.get("status").getName() == "Completed"

There is no "parent of a parent", Jira only has three layers - project, parent and child.

I'm guessing you're using the structure plugin or something like it - you'll need to write more code to go find this additional parent - the plain Jira API simply won't recognise it.

0 votes

You probably need to find/write a "listener" that can pick up "issue created", read the new issue, check the parent issue matches the criteria and then tell the issue to go through the transition from completed to in-progress.

Fix it , the relationship between issue and parent issue is not "parent" , is linkd , so we need to add a "Transition linked issues" post function and the "Conditional execution" is linkedIssue.get("status").getName() == "Completed"

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

3,000 views 12 18
Join discussion

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
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot