The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Trigger both Parents in automation when subtasks moved

Yuri
April 5, 2023

Hello all,

I have 2 parents in Jira and have automation. If i moved sub-task from parent 1 to parent 2, triggered only parent 2. How i can trigger (current)parent 2 AND (previous)parent 1?

I want to check and change status both parents.

1 answer

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

0 votes
Tessa Tuteleers
Community Champion
April 5, 2023

Hi @Yuri , 

Welcome to the community! 

You have not tagged the hosting type of your instance. As Automation is quiet different in Server / DC / Cloud, it is very important to mention the correct hosting type. 

In any case, for triggers that have editted the issue, you can use the changelog smart value. 

For cloud, you can use the smart value {{changelog.Parent.FromString}} to get the key of the parent before you moved it to a new parent, and {{changelog.Parent.ToString}} to get the key of the new parent (after change).

Be aware that your trigger must be an "issue editted", with the appropriate conditions, and not "issue moved", I don't think it triggers when you move a subtask to a new parent.

More info can be found here: https://support.atlassian.com/cloud-automation/docs/jira-smart-values-issues/

Hope this helps! 
- Tessa

Yuri
April 5, 2023

Oh yes. thank you, but now can i somehow change status by this {{changelog.Parent.FromString}}?

Yuri
April 5, 2023

Or maybe i can call trigger update for: {{changelog.Parent.FromString}}?

Tessa Tuteleers
Community Champion
April 5, 2023

Hey Yuri, 

The smart value gives you the key of the issue. You can use that key to find the issue (branch rule action -> related issues -> JQL ) and then use a transition action on that issue. 

- Tessa

Like Bill Sheboy likes this