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

How to trigger an automation rule when Parent changes?

jake
Contributor
July 31, 2020

I want to edit a field when the Parent issue changes, specifically when I associate a Story to an Epic, or move a Story from one Epic to another.

Parent does not seem to be an option for "Fields to monitor" though help specifies that all fields and custom fields are available. Supposedly you can also match field names by regex, but I cannot figure out how to add a regex to this "Fields to monitor" field.

We are using a next-gen project on jira cloud here, if that makes a difference.

1 answer

1 vote
Ste Wright
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 31, 2020

Hi @jake 

It is a little different in Next-Gen I've found.

For some reason, the rule does not activate when I change the Epic itself - it is not being counted as an issue update. I have to also update a field during the modification of the Epic - so I added an extra custom field which I modify after changing the Epic (although you could use any standard field too).

Here's how I did it:

  1. Create a new field in all issue type(s) under an Epic - eg. a short-text field called "Automate"
  2. Go to Project Settings > Apps > Project Automation and create a new rule
  3. For the trigger, use - Issue Updated
  4. Add a condition - Issue Fields Condition. Add the field Issue Type, the condition "does not Equal" and value Epic. This ensures the rule doesn't run when you update Epics.
  5. Add the Action - Edit Issue - choose the field you wish to replicate. To change this to copy from the Epic, select the 3-dots icon next to the field and choose "copy from" - choosing "Copy from Epic"
  6. Publish the rule

With the extra step of modifying my "Automate" field, it seems to work :)

Ste

jake
Contributor
August 3, 2020

Unfortunately this automation is only updating a single field, and it can keep the field in sync between an Epic and its children after it's initially set (because as you say, the Parent change is the only edit that seems to not be considered an issue update).

Because it's just one field, creating another field that we'd have to edit afterward as a means of kicking off automation isn't very helpful, we can just set our single field manually the first time instead.

I was hoping for some other way to identify modifications to the Parent. Oh well, thank you for the suggestion!

Like # people like this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events