/
Copy the reporter and watchers on duplicate issues
Copy the reporter and watchers on duplicate issues
Required apps
Power Scripts™ for Jira (server)
Level: BASIC
Problem
Yet another small trick to make your user's life bearable: when developers close an issue with resolution duplicate, you should normally copy the watchers and the reporter to the original issue.
Solution
Writing the code
This is done in SIL™ in the following way:
string u; number n=0; n=size(fieldHistory(key, "Link")); if (n>0 and resolution=="Duplicate") { string dKey=getElement(fieldHistory(key, "Link"),n - 1); // history %dKey%.watchers=addElementIfNotExist(%dKey%.watchers, reporter); for (u in watchers) { %dKey%.watchers=addElementIfNotExist(%dKey%.watchers, u); } }
You just need to put this on the postfunction on the transition Resolve issue and that's all.
See also
- Block 'Close' Transition Until All Subtasks are Closed
- Create an issue of a certain issue type when there is no Create permission
- Forbidding specific priorities for certain projects
- Restricting resolutions based on issue type
- Restrict sub-tasks based on Issue Type
Related content
Copy watchers to sub-tasks
Copy watchers to sub-tasks
Read with this
Copy the reporter and watchers on duplicate issues
Copy the reporter and watchers on duplicate issues
More like this
Copy the reporter and watchers on duplicate issues
Copy the reporter and watchers on duplicate issues
More like this
How to restrict auto creation of duplicate issues when an issue is reopened
How to restrict auto creation of duplicate issues when an issue is reopened
More like this
Limit transitions based on the status of dependent issues
Limit transitions based on the status of dependent issues
More like this
Close Parent Issue When All Subtasks Are Closed
Close Parent Issue When All Subtasks Are Closed
More like this