Forums

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

Automate trigger on state change: Cloning, linking and moving clone

Avery Jacobson
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!
September 30, 2019

I have a bunch of projects in jira. One redlines project and a bunch of system projects. Redline tickets will have tags and other references needed to their system projects. I want to make it so that when a redlines ticket gets put in a done state it gets cloned, linked to the original ticket and move to the appropriate project into an open state based on its tags or whatever need be. I have been doing reasearch and I think I might be able to do this two  or three ways. 1) Through simple issue language / power scripting 2) With a plugins and 3) REST API. Can someone please give me some guidance on how to go about this?

1 answer

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 Leaders.
May 18, 2020

Hello @Avery Jacobson !

I want to provide a solution with Power Scripts.

1. Create this script:

/* custom fields */
string[] custom_fields_mapping;

string newProjectKey = "SYSTEM";

custom_fields_mapping = "STDUP|fmanaila|STDGP|jira-users";
string k = createIssue(
newProjectKey,
"",
issueType,
summary ,
priority,
description,
components,
dueDate,
originalEstimate,
securityLevel,
custom_fields_mapping
);

linkIssue(k, key, "Relates");

2. Add this script as a post function for the Done transition.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events