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

Parent Issue Inherits User from Multi-Select User Field

Ryan Ruhland
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
December 1, 2023

Hello,

 

I have an issue hierarchy where we have Initiatives (Parent) and Epics (Child).  We have a custom field in both issue types that is Custom Field type "User Picker (multiple users)."

 

What I'd like to do is to use Automation so that any time a user is added to the Custom Field in an Epic, they are also added to the Custom Field in it's Parent Initiative.  I don't want to copy the Custom Field from Epic to Initiative because that may not be accurate.

Example Situation:

Epic 1 currently has Users A, B, and C in Custom Field
Epic 2 currently has Users X and Y in Custom Field

Epic 1 and Epic 2 both have a Parent Link to Initiative 100

Initiative has Users A, B, C, X, and Y in Custom Field

If I go to add User Z to Custom Field in Epic 2, I would like automation to update the Initiative Custom Field to now hold users A, B, C, X, Y, and Z.

 

Thank you in advance!

2 answers

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 1, 2023

Hi @Ryan Ruhland 

There are occasionally problems with the changelog for list fields (like multiple select users), and so please try this to confirm it works...

When the rule trigger is Value Changes for your field, this smart value will contain the added and deleted values, respectively:

{{addedFieldChange.values}}

{{deletedFieldChange.values}}

With those, you can create a JSON update expression to edit the field: by iterating over the values.  This cannot be done in a branch, but instead must be done in one single edit to prevent collisions. 

https://support.atlassian.com/cloud-automation/docs/advanced-field-editing-using-json/#Multi-user-picker-custom-field

Kind regards,
Bill

0 votes
Erin Quick-Laughlin
Contributor
December 1, 2023

@Ryan Ruhland This seems helpful:

  https://confluence.atlassian.com/automationkb/automation-for-jira-how-to-update-the-request-participants-or-a-multi-user-picker-field-from-the-content-of-other-fields-1216971334.html 

I would imagine the job would be something like:
* When value changes for <field>
* Branch: for Parent
  * Edit Issue Field, using the suggestions from the link above, and pulling source values from either the changelog or the fieldChange smartvalue - focusing on accountId.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events