Hi,
For context, I am trying to send a list of issues to Slack that have been in development for more than a week without a comment. The list of issues that have been in development for more than a week is quite easy, the comment part I am close but can't seem to finalize it.
I am attempting to use a logical statement within the lookup and can't seem to get the formatting right, currently what I have is:
{{#lookupIssues}}
{{#if({{comments.last.created.plusDays(7).compareTo(now)}})}}
YES #1
{{//}}
{{//}}
It complains:
First thing, try using a single slash to close expressions like iterators and logical conditions: {{/}}
Second, when inside of a conditional test, you do not need the extra curly brackets for the issue fields.
Next, I believe that compareTo() returns -1, 1, or 0: https://support.atlassian.com/cloud-automation/docs/jira-smart-values-date-and-time/
Finally, to test in the conditional, I believe you need to use something like equals() test for this:
{{#lookupIssues}}
{{#if(equals(comments.last.created.plusDays(7).compareTo(now),1))}}
here is the key of a found item: {{key}}
{{/}}
{{/}}
Another idea: what do you mean by "in development" for this? It seems you are instead checking for things with the last comment date/time rather than, for example, in progress. Without seeing your entire rule and the JQL used for the Lookup Issues it is difficult to discern.
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.