(Beginner) How can I automate the population of a subtask list based on the Issue type?

JT Jung I'm New Here Dec 13, 2017

I'm completely new to JIRA Script Runner. I tried doing the research to figure out how I can automate the addition of 15 subtasks upon parent issue creation, but could not get any code to work.

I'm currently on the Script Console. Can someone provide me with detailed steps from the very beginning on how to add the script for this purpose?

1 answer

1 accepted

1 vote
Jenna Davis Community Champion Jan 05, 2018

Hello, 

I believe the easiest way for you to do this would be to use the built-in create sub-task post function. You can get to this by going to your workflow > then click Add a Post Function > then click Script Post Function > finally click Create a sub-task. You'll have to make one of these post-functions for each sub-task you want to make, so if you want to make 15 sub-tasks, create 15 post functions. 

You could also custom code this, but for ease-of-use sake I would recommend the above method even though it is a bit tedious. 

Please let me know if you need any further help!

Jenna

Suggest an answer

Log in or Join to answer
Community showcase
Teodora [Botron]
Published Feb 15, 2018 in Marketplace Apps

Jira Inferno: The Nine Circles of Jira Administration Hell

If you spend enough time as a Jira admin - whether you are managing a single, mid-sized instance, a large enterprise one or juggling multiple instances at once - you will eventually find yourself in ...

1,134 views 6 19
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot