Forums

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

Automate the updating of "Fix versions" on linked support tickets.

Deleted user
November 4, 2022

Hello,

I'm using ScriptRunner for Jira Cloud and I basically have the following workflow that I'm trying to automate.

  1. A fix version (field name "Fix versions") is updated on a bug/story
  2. I have a script listener triggering on issue update which checks if the "Fix versions" field was updated, if it was it drops into a "do something" block.
  3. I would like to update any linked "support ticket" type issue to have the same Fix version which was just entered in the bug/story.

Basically I want any updates to the fix version to propagate out to any linked support tickets, I've managed a solution which unfortunately will only work on Jira server, and I'm struggling a little getting this to work on cloud having just migrated.

Here's the shell:

def fixVersionChanged = changelog?.items.find { it['field'] == 'Fix versions' }

if (!fixVersionChanged) {
//logger.info("Fix Version was not modified")
return;
}

//logger.info("Fix Version was modified")

Assistance would be much appreciated.

Thank you 

3 answers

Suggest an answer

Log in or Sign up to answer
0 votes
Jay Salvay
January 11, 2018

Thanks Alexey!!!!

0 votes
Jay Salvay
January 11, 2018

Hi Alexey! Thansk for your quick reply! I tried already, and I'm getting this message (and no items on the search result): "Field 'issueFunction' does not exist or you do not have permission to view it."

 

I tried running "issueFunction in subtasksOf("status = Open") and status = Open" and "issueFunction in subtasksOf("status = Open")" and same mesage on both.

 

So, I believe that something is missing in the configuration or something. BTW, I'm using Jira Clouding + SR clouding

 

Any thoughts?

Alexey Matveev
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 Champions.
January 11, 2018
0 votes
Alexey Matveev
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 Champions.
January 10, 2018

Hello, 

You can open the Issue Navigator and enter the following JQL query in the advanced search

issueFunction in subtasksOf("status = X") and status = X

This will give you all subtasks which are in status X and their parents are also in status X

Alexey Matveev
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 Champions.
January 11, 2018
TAGS
AUG Leaders

Atlassian Community Events