Hi all,
I would like to get a list of work items that contain an attachment that has a filename longer than 50 chars. Then, I'd like to send this list as an email.
What I tried is:
Smart value comparison:
- Run a scheduled rule with a JQL search (attachments is not empty)
- Compare smart value {{attachment.filename.length}} greater than 50
- Then send an email.
- Caveat: Sends multiple emails because of the 'Scheduled' trigger. Works OK with logging to audit log
Conditional expression
- Run a scheduled rule (or manual for testing)
- Lookup work items (attachments is not empty)
- Send an email with a conditional smart value expression
- Caveat: Doesn't work. I have tried
({{#if(issue.attachment.filename.length.gt(50))}} {{lookupIssues}} {{/}} or
{{#lookupIssues}}
* {{#if(attachment.filename.length.gt(50))}} {{key}} {{/}}
{{/}} I can't seem to be able to get the syntax right.
What does everyone think? I'm tempted to tag the automation goat @Bill Sheboy , I think you might like this.