Does conditional logic work for jira software 8.20.10?

Jar Lady April 10, 2024

I want to include if condition in the email template of jira automation as I cannot use the normal IF operators because I had to send email like this:

Hi Person,

<if field A is not empty>

Field A

<if field B is not empty>

Field B

<if field C is not empty>

Field C

I realise if B is really empty, then it will leave a large line break in between. So i had to use if conditional logic in jira automation. Does anyone know how to incorporate the conditional logic in jira software 8.20.10?


1 answer

1 accepted

0 votes
Answer accepted
Kalyan Sattaluri
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.
April 10, 2024

Hello @Jar Lady 

Yes. You can use conditional logic like below in your email.

{{#if(exists(issue.Field A)) }} - Field A. {{/}}

{{#if(exists(issue.Field B)) }} - Field B. {{/}}

{{#if(exists(issue.Field C)) }} - Field C. {{/}}

Now depending on the field type, you may have to do below syntax:

{{#if(equals(issue.Field A,"")) }} - Field A. {{/}} OR similar. But do try the exists logic first and log the value and let us know.

Jar Lady April 11, 2024

{{#if(exists(issue.Field A)) }} - Field A. {{/}} works. Thanks a lot!

Suggest an answer

Log in or Sign up to answer
AUG Leaders

Atlassian Community Events