Automatically transition Epics AND Stories as sub-tasks transition? Edited

I'm currently using Automation for Jira Cloud, but I'm open to ANY solutions that will work in the Jira Cloud. I'm able to transition Epics when 1st-level child issuesTypes transition. I'm also able to transition the 1st-level child issueTypes when their sub-tasks transition. However, I'm unable to figure out a way to have the sub-task autotransition up through the hierarchy. Is it possible for the transition of a sub-task to automatically transition its parent issueType AND automatically transition the parent's corresponding parentEpic? 

Our use case is that Epics always have Issues, but Issues don't always have sub-tasks, so people-driven transitions could occur at either the issue or sub-task level.

If anySubTask -> In Progress
then anyParentIssue -> In Progress
then parentEpic -> In Progress

Also doing the same for Resolving the sub-tasks, issues & epics, but I assume solution would be basically the same if it is possible.

If allSubTask -> Done
then allParentIssue -> Done
then parentEpic -> Done

I have the same problem with Portfolio's custom "Parent Link", but I'll save that for another discussion.

2017-05-02_16-58-40.png2017-05-02_17-00-01.png

 

 

1 answer

0 vote
Andreas Knecht Community Champion May 07, 2017

Hi Lloyd,

So this type of things is a little complex at the moment, however it should be possible.  I think the specific problem you have is, that you are struggling to access the Epic issue when a sub-task is transitioned (since that's 2 levels up in the hierarchy via the sub-task's parent issue).

To get access to this you can use a related issues action and select 'JQL'.  Then use this in your JQL:

key = {{issue.parent.fields.Epic Link}}

So this would be for the rule that's triggered when a sub-task transitions.  What this action will do is to run a search for an issue with the key, that matches the sub-task parent's epic link value (the issue key of the epic).  It will then put that issue into the context on that branch and you can transition it.

So your rule would look like:

  • Trigger: issue transitioned
  • JQL Condition: type = sub-task
  • Related issues action: (with parent)
    • Do stuff for parent issues
  • Related issues action: (with the jql above)
    • Do stuff for the epic

Hope this helps. Also apologies for the slow response - we were at Atlassian Summit last week!

Cheers,
  Andreas

 

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Bridget Sauer
Published Thursday in Marketplace Apps

Calling all developers––You're invited to Atlas Camp 2018

 Atlas Camp   is our developer event which will take place in Barcelona, Spain  from the 6th -7th of   September . This is a great opportunity to meet other developers and get n...

198 views 0 6
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