Hello wonderful, knowledgeable people.
I have been asked by management to extend our customer comment notifications to include the history of all the comments for the ticket.
The default notification covers the last comment just fine with:
*${event.user.name} commented:*
${comment}
Beyond this, I now want to include the rest of the comments in reverse order. That part is pretty easy. However, since the last comment is already included above, I wanted to avoid including that one a second time and just start with all the comments after the last one. After working with it for an hour, below is what I came up with but it doesn't work. Any ideas what I am doing wrong?
*Comment History:*
{{#issue.comments.reverse}}
{{#if(not(equals(issue.comments.last.body, body)))}}
*{{author.displayName}}* on *{{created.convertToTimeZone("America/Los_Angeles").jiraDate}}* at *{{created.convertToTimeZone("America/Los_Angeles").shortTime}}*
-----------------------------------------------------------
{{body}}
{{/}}
{{/issue.comments.reverse}}