Forums

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

How do you evaluate a cascading field for empty in an automated email template

Tom Scoggin
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.
January 7, 2025

I have an email template that needs to show a cascading fields value if not empty. I've tried {{#if not(issue.fields.customfield_12909.value.isEmpty)}} or just {{#if issue.fields.customfield_12909.value}} and neither evaluates to true or false. I can add the field data to the email using {{issue.fields.customfield_12909.value}} - {{issue.fields.customfield_12909.child.value}} so I know it works in the email but it will just not evaluate in an #if statement.

Looking forward to any help.

1 answer

1 accepted

4 votes
Answer accepted
Marc - Devoteam
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.
January 7, 2025

Hi @Tom Scoggin 

What if you would use:

{{#if(issue.customfield_12909.value.isNotEmpty()) }}
issue.customfield_12909: {{issue.fields.customfield_12909.value}} - {{issue.fields.customfield_12909.child.value}}
{{/}}

Tom Scoggin
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.
January 7, 2025

That worked. Thanks!

Note: Just before you provided this, I was able to also perform this by creating a variable for the cascade field and evaluate against the variable. See below.

Capture.PNG

Like Marc - Devoteam likes this

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, atlassian community, journeys for jira service management, journeys for jsm, eap jsm atlassian, early access program atlassian, early access program journeys atlassian, early access program journeys jira service management, join atlassian eap

Join the Early Access Program (EAP) - Journeys for Jira Service Management 🚪

Journeys is a brand new feature in Jira Service Management that helps you streamline various processes in your organization that may cross multiple departments, such as employee onboarding or off-boarding that require action from different teams. ✨

Join the EAP →
AUG Leaders

Atlassian Community Events