Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How do I select a custom field for a field value change rule?

Dave Stillwell October 21, 2024

I am creating automation that is to be triggered by a field value change and the field I want monitor for changes is not listed in the drop-down.  So, I am trying to use the smart value for the field (e.g. {{issue.Affected part number}} but I am getting a "Value must contain a valid regular expression." error when I try to publish the automation.  Could the issue be because the data in the field is an Asset?  If so, is there a workaround?

1 answer

1 accepted

1 vote
Answer accepted
Trudy Claspill
Community Champion
October 21, 2024

Hello @Dave Stillwell 

To enable us to help you, please provide screen images showing the rule you've constructed, and the details from the rule execution Audit Log.

Dave Stillwell October 22, 2024

Screenshot 2024-10-22 151420.png

I can't post an Audit Log because I can't publish the rule due the error.  Basically, what I am trying to do when the value in the Custom Field "Affected part number" changes I want to look up the key for the asset value in the field and update Cost field with cost associated with the asset (using {{lookupAsset.attributes.cost}}) and the Total Cost (using {{lookupAsset.attributes.cost}}*{{issue.Number of Units}}).  When field is initially populated everything work as it should, but if the wrong PN was entered and we edit record to change the value the Cost field would not update with the cost of the new item.  I created a manually triggered automation, and everything would update as expected but I would like to make the automation trigger automatically after the field value changes.

Trudy Claspill
Community Champion
October 23, 2024

Thank you for that additional information @Dave Stillwell 

What version of Jira are you using?

What is the custom field type of the field you are trying to select? I suspect it might be an Asset Object type field.

If so, see if the discussion in this post helps you solve your requirement:

https://community.atlassian.com/t5/Marketplace-Apps-Integrations/Automation-Trigger-on-Asset-field-value-change/qaq-p/2542625

 

Dave Stillwell October 25, 2024

I changed the field name to the cf number (e.g. cf[12345]) and I was able to publish the rule and based on link you provided I seemed to have been able to fluke into the solution.  I haven't gotten any feedback from my users if it is working as expected, so only time will tell (can't test in test environment since it is a bit behind the production environment)

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events