how to run daily script to update Fix Version to let Fix Version consistency?

Cecilia Chu February 19, 2019

The requirement is that use JQL find the Defect which linked a work package, the work package is defect's parent. If defect's fix version is different with work package's fix version, will scheduler to run this script to set defect's fix version equal to work package's fix version. But I don't know why it not works when I use sil scheduler to run this script. Could you please tell me how to achieve?

My code:
string subJql = "issuetype in (Defect) AND issueFunction in linkedIssuesOf('issuetype = 'Work Package'', 'is a parent of')";

string[] issues = selectIssues(subJql);

for(string issue in issues)
{
string[] linkissues = linkedIssues(issue, "Parent/Child",-1);
for(string linkIssue in linkissues){
if(%issue%.fixVersion != %linkIssue%.fixVersion)

{ %issue%.fixVersion = %linkIssue%.fixVersion; }

}
}
Thanks,
Cecilia

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events