Hello -- we want to automate the update of fields on the sub-tasks. Question, is there a rule someone might want to share to propagate (copy) the labels field to all the sub-tasks? Much in the same way the Sprint value is copied down to the sub-tasks.
Thanks.
Hello Claudio,
To copy labels to subtasks, create a rule "For Sub-tasks", then a new action, "Edit issue fields" (see screenshot below).
As an alternative, you could add an action to run a script via Power Scripts (see screenshot below).
The SIL script would look something like:
string [] subtasks = subtasks(key);
for (string subtask in subtasks) {
%subtask%.labels = key.labels;
}
The advantage of a SIL script is flexibility. Let's say you wanted to copy a label only if the subtask status is closed. For example:
string [] subtasks = subtasks(key);
for (string subtask in subtasks) {
if (subtask.status == "Done") {
%subtask%.labels = key.labels;
}
}
Please let the community how everything goes!
Regards,
Hyrum
Due to Confluence Cloud security features, you may need to open the documentation in incognito mode or by logging out of Confluence.
Please note that I am a product engineer for Power Scripts and I work for Anova Apps (Appfire).
Thanks Hyrum, I have enabled such a rule except that for now, I want to manually trigger it and not do it as part of a status transition.
Question - where can I see a button or click to execute a rule from the current issue. See below my rule for reference.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Hyrum, I worked out how to run the rule from within the parent issue. Also the precise setting was to copy labels from parent issue (see below) and it worked. Tks again.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello @Claudio Rouillon ,
You can use Automation for Jira, and use the branchs to do this.
Using the component -> Branch rule/ relate issues, and setting "Sub-tasks" then you can copy the values using the action "Edit Issue" to set the fields and values that you want to copy or define.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Pramod,
The solutions posted above should work in Jira DC/Server without modification.
Hyrum
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.