Hello,
is there any way to make an automation rule that will create several sub-tasks, where the summary will be the key from one text field?
We have a text field where the user can enter several keys. I am able to create variables with these keys via regex.
I would need to create a rule that will create n-issues (sub-tasks), where the summary will always have one key.
For example, I have 3 keys XXX-123, XXX-456, XXX-789 in a text field. I need to create 3 sub-tasks whose summary will be "Sub-task for XXX-123", "Sub-task for XXX-456" and "Sub-task for XXX-789".
Is this possible to do in an automation rule?
Is it possible to do this via a loop? The number of keys in the text field can be different.
Hi @Petr Michna _EXT_ -- Welcome to the Atlassian Community!
Unfortunately, Jira Data Center automation does not have the Advanced Branch feature to iterate over values in a list. Here is the suggestion to add it, which you may watch / vote for to see progress: https://jira.atlassian.com/browse/JIRAAUTOSERVER-749
I believe there are two workarounds for your scenario, although I have not tried them as I am not using the Data Center Version:
As both of these use Send Outgoing Web Request, please see this article from Atlassian describing how to use the action:
Kind regards,
Bill
Hi Petr and welcome to the community,
I do hope that someone has an idea to solve your request, but while it is pretty easily doable in Cloud, it doesn't seem possible - or at least not straightforward - in Data Center.
In Cloud you would create a Branch in your Automation in which you can provide a smart value (instead just selecting a work item relationship as it is in DC).
Using a smart value like "{{issue.description.match("([A-Z]{3}-\\d+)")}}" would then both extract the issue keys from your text field and also save it as array.
The branch would then iterate over each entry in this array and with the help of the Create Work Item action you create your work items using the key in the summary of them.
I'm sorry this isn't of much help for your Data Center instance, but maybe you are on Cloud after all - then you'd have your solution. :-)
Have a great day!
Greetings
Philipp
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.