Forums

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

Using jira automation tool to create a rule . When I am trying to use if clause its not working

Girish Vidhani
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 9, 2023

 

<table style="width:100%;border-collapse: collapse;border:1px solid black">
<tbody style="border: 1px solid black;>
<tr>
<th style="border: 1px solid black;">Issue Key</th>
<th style="border: 1px solid black;">Summary</th>
<th style="border: 1px solid black;">Assignee</th>
<th style="border: 1px solid black;">Reporter</th>
<th style="border: 1px solid black;">Break Description</th>
</tr>
{{#issues}}
<tr>
<td style="border: 1px solid black;"><a href={{url}}>{{key}}</a></td>
<td style="border: 1px solid black;">{{summary}}</td>
<td style="border: 1px solid black;">{{assignee.displayName}}</td>
<td style="border: 1px solid black;">{{reporter.displayName}}</td>
<td style="border: 1px solid black;">
{{#if(issue.customfield_10006.lt(1))}}
This issue is missing story points.{{/}}
{{#if(issue.customfield_10202.isEmpty)}}This issue is missing acceptance criteria.{{/}}</td>
</tr>
{{/}}
</tbody>
</table>

 

the if  clause should print the string provided but its not , can you please help?

2 answers

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.
October 9, 2023

Hi @Girish Vidhani -- Welcome to the Atlassian Community!

First thing: when posting a question like this, please include an image of the complete automation rule, images of any relevant actions, and an image of the audit log details showing the rule execution.  Those will provide context for the community to offer suggestions.

Until we see those...

It seems you are using Jira Cloud.  Is that correct?

If so, the smart value {{issues}} for bulk-handling of issues is only supported in Jira Server / Data Center, not Jira Cloud.

Instead Jira Cloud uses the Lookup Issues action, and the smart value {{lookupIssues}}.  Please look here to learn more about that action: https://support.atlassian.com/cloud-automation/docs/jira-automation-actions/#Lookup-issues

Next...you appear to be using smart value, list filtering inside of the iterator: https://community.atlassian.com/t5/Automation-articles/Filtering-smart-value-lists/ba-p/1827588

When that conditional filtering is used, you are already inside of the iterator and so the {{issue}} prefix is not used with smart values; only the field name is used, such as for your field customfield_10006.

Kind regards,
Bill

0 votes
Piero Giacomelli
Community Champion
October 9, 2023

Dear Girish,

It's a little bit difficult to undestand you question based on html code.

 

Could you pls share some more information or some screen.

 

Thanks.

 

pg.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events