I am using Jira Assets and would like to set up an automation rule when a new object is created. I am just having an issue with the syntax. I have an attribute 'Prepared By' that I would like to set to the current user if the object is created and there is no value for that attribute. The Prepared By type is User. I have been setting the rule as follows :
When: Object created
If (condition): Prepared By = null
Then: Action: Attribute Value
Attribute Name: Prepared By
Value: currentUser{}
Thanks.
Hello @Bill Parlock
What is the output in the rule execution log file?
Is the problem that your rule doesn't get past the condition, or that the attribute is not set to the expected user?
Actually, both. I am doing testing where I removed the condition so when the object is created the 'Prepared By ' field would be populated. That would be the simple case. As another person has recommended, I am trying to use the {{initiator.displayName}} value to populate the field. So far though the field is not being populated. Once I get the field populated then I will try to add the condition, I need to check the execution file as you suggested.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
For the person / user who performed the action that triggered the rule, please use the {{initiator}} smart value: https://confluence.atlassian.com/automation/jira-smart-values-users-993924862.html
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.
Thank you for the link. I am continuing with the {{initiator.displayName}} value. So far I have not been able to populate the field though.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If that field is a user, please try using {{initiator.name}} instead.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have tried {{initiator.name}} and {{initiator.accountId}}. Not successful though. From the log file:
' Error when updating object rlabs-insight-attribute-... At least one value must be set; '
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Would you please post an image of your complete rule, an image of the action using that smart value, and of the audit log details showing the rule execution? Thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.