Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

JIRA: On Sub Task creation, inherit custom fields from Parent

In JIRA, is there a way when a sub task is created, to have it inherit custom field values from the parent?

For example, we have custom fields called "Epic" and "Feature". If the story has an "Epic" value of "Email" and the "Feature" value of "Stylesheets". When you click the "Create sub task", the sub task should automatically have "Epic" = "Email" and "Feature" = "Stylesheets".

What ways have you done this in the past?

Thanks

like image 736
Kevin Lamb Avatar asked Jul 14 '11 23:07

Kevin Lamb


2 Answers

I do this two ways:

  1. Use the Create and Link plugin. You can specify which fields will inherit values, alter or append the values, or explicitly set values. This works for both standard and custom field.
  2. Add a post-function to the "Create" step of the subtask's workflow. When the task is created it could check the parent for the values of "Epic" and "Feature" and use those values to populate the subtask. I used the Jira Scripting Suite plugin to write the post-function in Jython.
like image 81
Logan Avatar answered Oct 09 '22 04:10

Logan


It would be nice to have a one step way to do this. The best I've found is two steps - clone the issue, which will duplicate all the field values, and then change it to a subtask.

like image 24
gareth_bowles Avatar answered Oct 09 '22 03:10

gareth_bowles