Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Automation to create stories on epic creation when the give a component or a field value matches

Sai Praveen Aminigadda February 12, 2021

we have a requirement to create stories in different projects when we create an epic. but it should create only when the predefined custom field or a component filled 

 

For example:

1. when I'm creating Epic in a project "A" with a component "X", it should create stories Story 1, Story 2, and Story 3 in the project" B".

2. if i'm creating epic with a component "Y", it should create stories in the project "C"

 

if I create an epic without that component "X", "Y" it should not create any stories just the epic.

 

We have JSU, Script runner plugins, version is 8.8.

 

any help would be appreciated. 

2 answers

0 votes
Ravi Sagar _Sparxsys_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 12, 2021

Hi @Sai Praveen Aminigadda 

You can create an issue using a post function or a listener. To get started you can take a look at this script here. Hopefully it will give you some ideas.

Ravi

Sai Praveen Aminigadda February 12, 2021

@Ravi Sagar _Sparxsys_ thanks for responding. i want this to happen only when the predefined a custom field value given while creating a epic.

i don't see any condition in the script. how can I modify it?

Ravi Sagar _Sparxsys_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 12, 2021

You will have to write a custom script for that.

Sai Praveen Aminigadda February 15, 2021

I'm not good at scripting. do know where can I get help with this?

 

Thanks

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 12, 2021

Hi @Sai Praveen Aminigadda 

What have you tried thus far for your rule?  Would you please post an image of it?

If you are just getting started, you could use an issue created trigger, conditions for the issue type of epic and and if/else on component, and then create issue actions to select the project and fields.

Please see here for more information:

Triggers: https://confluence.atlassian.com/automation/triggers-993924804.html

Conditions: https://support.atlassian.com/jira-service-management-cloud/docs/automation-conditions/

Actions: https://confluence.atlassian.com/automation/actions-993924834.html

Examples library: https://www.atlassian.com/software/jira/automation-template-library#/label/all/1453

Best regards,

Bill

Sai Praveen Aminigadda February 12, 2021

@Bill Sheboy thanks for responding. I have tried with a post function based on the field "Team" as shown in the screenshot. but it is creating stories by selecting any team. but, i want that to create stories only when the team selected "A"Capture.PNG

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 12, 2021

Hi @Sai Praveen Aminigadda 

Sorry, I missed that you were trying to do this with ScriptRunner.  @Ravi Sagar _Sparxsys_ has given you advice for using that add-on tool.

I was suggesting the use of the Automation for Jira features, which were the links to documentation I provided.  There is a free Lite version if you want to try that add-on.

Best regards,

Bill

Sai Praveen Aminigadda February 12, 2021

@Bill Sheboy due to our company policies, I cannot install another add-on even it free. i have to achieve this with existing add-ons only. 

Suggest an answer

Log in or Sign up to answer