Hello,
I am trying to create a system that gathers weekly data and builds a report to send out in a weekly email. I am using the schedule trigger for every 7 days with a JQL search condition that returns a list of items that have been updated in the last week to a send email action. The goal is to have two lists: One for items that have been created in the last week, and another for items that have been updated in the last week.
In the body of the email action, I have been attempting to use if statements to parse out items from the list and display them in the desired fashion. However, I have not been able to get the if statements to function. I have found contradictory information on this site for how to format the if statements. Here is what I have at the moment:
{{#issues}}
{{#if(created.gt(now.minusBusinessDays(5)))}}
<a href="{{toURL}}">{{key}}</a> was created on {{created.shortDate}}
{{/}}
{{summary}}
Updated on {{updated.shortDate}} at {{updated.shortTime}}
Assignee: {{assignee.displayName}}
Status: {{status.name}}
.
{{/}}
I have tested with several different conditions, including ones that should always return true, without luck, even though the rest of the message executes properly. One comment I found suggested putting spaces in front of the #if and / characters, but that seemed to make the if statement execute every time even if the condition was untrue.
Any suggestions on how to fix my formatting to get these statements to work would be much appreciated.
Note: I am not using Jira Cloud, if that matters