I am looking to create an automation where is checks all issues within in project and sends an email for each issue to the requestor warning custom field "Contract End" is in 7 days.
So far I have a schedule set to run every day at 8:00
Then: Lookup issues - project = "projectname"
If: {{Contract End}} less than {{now}}(-7d)
Then: Send Email - using smart values in subject and body {{issue.key}} and {{issue.Employee Name_Starter}}
The email is sending and the written text is coming through but the smart values are blank?
Hi Fraser,
In the if statement you're not referring to any issue at all. So it compares null to a date.
you should have
if {{lookupIssues.Contract End}} less than {{now}}(-7d)
to include the looked-up issues in your if statement.
More on the power of smart values with lookupIssues on this page
Thank you and I have changed the If to include your changes. I have run the automation and the email has come through but the smart values are still missing?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have changed to the custom field ID and run. The email has come through but no smart values again I am afraid?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Fraser - Welcome to the Atlassian Community!
The {{issue.key}} should be working with no problems.
For the other field, try: {{issue.Employee Name_Starter.displayName}}
The real question is, are there really any issues that are meeting the query.
So, run the query separately in the search function to be sure there is an issue that should send an email. Then run the rule manually to see what it sends.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have used the query in the main search function and returns no results. Strange thin though is that when I trigger the automation manually an email is sent just with the smart values missing.
Am I doing something wrong with the query?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I should also have said thank you for the welcome and the assistance :)
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.