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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,460,661
Community Members
 
Community Events
176
Community Groups

Script Listener to update an Epic field when the same field is updated in a parent issue

Good morning all,

I have been researching the various community discussions on Script listeners and cannot seem to find one that would support my needs. You all are too advanced...

I am trying to ensure that any epics linked to a Parent issue using the Parent Link field from Portfolio for Jira are updated with values that are identical to the ones in the Parent Issue. The kicker here is that the Parent issue is actually being updated via post function from a service desk request.

An example: As a service desk request gets a final approval, it will trigger an update to an Initiative that was created in support of a sizing activity. Part of the activity was to also create Epics, which are linked via the Parent Link field. The update will change a field, Approval Status, which is a single-select with 2 options (Awaiting Approval & Approved).

What I need to do is have a listener trigger the update of the Epics, as they also have the same field. The reason for this is that this will populate a team board with the issue type indicating that they can prioritize their work for the upcoming PI.

My thought was that this should not be too difficult, so I referred myself to the experts within the community, however; I just can't seem to find a simple example and am asking for assistance.

1 answer

0 votes

Hi Thomas

It should be possible to do what you are asking. You essentially have to get the links for the issue that is being updated and then look for the links of type "Parent-Child Link" which is what Portfolio uses by default so it should be the same unless someone changed it.

I created an example of how I might push field updates between Portfolio parent and child issues and also from child to parent issues.

I have not tested this on a server with many different link types so you should run tests of the script on a test server to make sure it doesn't cause problems on your server and that it works as you expect it to. You may need to alter it to fit your needs but hopefully, this will help you make some progress on the script you want to create.

Here is the script I wrote: Script Listener (Issue Update) script

Regards
Matthew

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events