Forums

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

Automation for Jira display subtasks into an Email

Albert Manuel
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.
December 19, 2022

Hi all,

I have a process like this:

When a certain task is created, I add two more subtasks under him. Now i need to send a specific email to some people and i want to somehow display the subtasks key / name etc in this email template, but nothing works for me, i have something like this

Hi all,

A new employee named {{customfield_11037}} will join our department starting {{customfield_11038}}.

There are two subtasks created under his onboarding ticket {{issue.key}} that we need to take care of:

1) Subtasks 1

2) Subtask  2

Thanks

Now how do i replace Subtasks 1 and Subtasks 2 with the actual subtasks that were created? What smart value should i use?

Thanks

 

 

 

2 answers

1 accepted

0 votes
Answer accepted
Vamsi Kandala
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.
December 19, 2022

Hi @Albert Manuel 

This was already answered before and you can reference this article: https://community.atlassian.com/t5/Jira-questions/Subtask-smart-value-in-Jira-Automation/qaq-p/2096643

Hope this helps.

Albert Manuel
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.
December 20, 2022

Hi @Vamsi Kandala thanks for your input, for some reasons when i use {{issue.subtasks}} is not displaying anything in my email, it's blank - but i have the subtasks - the automation dosen't throw any error either.

I will keep looking.

@Bill Sheboydo you have any ideea hon this case?

Thanks

Vamsi Kandala
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.
December 20, 2022

Hi @Albert Manuel

I have tested it out and it is working fine for me.

Can you send us the screenshot of your ticket with the sub-tasks as well as the contents of the email body in your automation rule?

Thanks,
Vamsi

Like Bill Sheboy likes this
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.
December 20, 2022

Hi @Albert Manuel 

Please post images of your complete rule and the audit log details showing the rule execution.  Those may provide context to explain what you are observing.  Thanks!

Kind regards,
Bill

0 votes
Albert Manuel
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.
December 21, 2022

@Vamsi Kandala/ @Bill Sheboy I have succeeded in implementing this - the problem was that the email was sent before the subtasks were created, so I have added a "Re-fetch issue," and now it's working.

The only problem I have left is that I have two subtasks under an issue, and when I send the email, i cannot say which subtasks I want to display:

I have something like this:

1) Here need to be the first subtasks + some text description

2) Second subtasks + text description

I have used:

{{issue.subtasks[1].key}} + text 

This one is working, but for the second subtask i have used:

{{issue.subtasks[1].key}} 
{{issue.subtasks[2].key}}
{{issue.subtasks.second.key}}

Nothing is working, i cannot pull the second one - maybe you guys have any ideea how to solve this?
Vamsi Kandala
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.
December 21, 2022

Hi @Albert Manuel

You can try this way:

{{#issues}}
    Parent issue key {{key}}
    Parent issue summary: {{summary}}
    Parent issue description: {{description}}
    {{#subtasks}}
        Subtask key {{key}}
        Subtask summary: {{summary}}
        Subtask description: {{description}}
    {{/}}
{{/}}

Hope this helps.

Thanks,
Vamsi

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events