Copy or Set Value Fields on Linked Issue Creation
This is the documentation of JSU for Jira Server/Data Center. If you are using JSU on Jira Cloud, see our JSU Cloud documentation.
Goal | Automate the creation of linked issues and their associated issue fields |
---|---|
Scenario | Let's say you are a Hiring Manager and you are onboarding a new Marketing Assistant. Your tasks to complete the onboarding could include:
Let’s see how JSU can create these linked tasks and associated issue fields when an origin Jira issue called Hiring a Marketing Assistant moves to IN PROGRESS. |
JSU Components | Create a Linked Issue post function |
Setup
First, create your origin issue which you’ll call Hiring a Marketing Assistant. Instead of manually creating linked issues and copying field values, JSU’s operations can help automate these tasks. These operations can do three things:
Copy a field value from the origin issue to a new linked issue
Copy the value from one field to another field within the origin issue, and
Set the value of a field in a new linked issue
Below we illustrate how you can use JSU's Create a Linked Issue post function to automate the creation of the linked tasks and associated issue fields when an origin Jira issue called Hiring a Marketing Assistant moves to In Progress.
How to configure this workflow
Go to your project settings and choose the Workflows option from the left sidebar.
Click Edit for the required workflow to create a draft version.
Select the In Progress transition. We will perform our automation on the In Progress transition, so that when the task moves to In Progress, two sub-tasks will automatically be created.
Select the Post Functions tab then click Add post function.
Select the Create Linked Issue(JSU) post function then click Add.
Select Inside Same Project for the target project. We want to perform the automation within the same project.
Select Sub-task for the New Issue will be related via option. You can then select any issue type for this option but in this example we choose Sub-task.
Now it's time for a little magic. Click Add configuration. You can copy a field value from the origin issue to the new issue or within the origin issue. You can also set a field value to a field in the new issue. In this case, we want to copy a field value from the original issue (our task) to the new issue (a new sub-task).
Click Add for the Copy to New operation.
Let's copy the assignee of the task to the assignee of the sub-task. Then, you can copy a value from a field of the origin issue to another field of the origin issue. We'll try it by copying the summary to the description and prepending it with a dash.
Configure the last operation by setting a value for the summary of the new issue. We'll set it to Create contract.
Click Add to save your configuration.
Repeat the process to add one more sub-task for ordering a PC. Add the create linked issue post function and configure the value of the fields you prefer. Set the summary of your new issue to "Order PC".
Publish your workflow.
Test your workflow
Go to your project and create a task for hiring a Marketing Assistant. Edit the assignee and the description of your task and put it in progress.
The JSU post function automatically created 2 subtasks for you! The description of your task is updated because of the "copy within origin" functionality. Your new sub-tasks have been assigned to the assignee of the task due to the "copy to new" functionality and their summary is set as configured by the "set" functionality. That's it! JSU automated the work for you!
This was only a sample of JSU in action. See our documentation for some more examples and configuration screenshots.