-
Suggestion
-
Resolution: Unresolved
-
None
-
2
-
Summary
Automation functions don't work on the Assets attributes.
The math functions don't work on the Assets object and field Integer attributes:
Steps to Reproduce
- Add an Integer attribute to one of the object types and set a value for an object
- Create an automation rule that multiplies the amount by 10
Expected Results
Able to use the math function multiply:
{{issue.AssetsCustomFieldName.AttributeName.multiply(10)}} OR {{object.AttributeName.AttributeName.multiply(10)}}
Actual Results
The math functions don't work on the Assets Integer attributes. The below smart value is empty:
{{issue.AssetsCustomFieldName.AttributeName.multiply(10)}} {{issue.AssetsCustomFieldName.AttributeName.asNumber}}
While the below smart value returns the date:
{{issue.AssetsCustomFieldName.AttributeName}}
Workaround
The following knowledge base article details workarounds for this bug as well as other automation functions impacted in a similar way: Workaround for using smart value functions with Assets data in Automations
An example use of the workaround mentioned in the article:
- Create a variable "amount" to store the amount value:
{{issue.AssetsCustomFieldName.AttributeName}}
- Then use the below functions on the variable name:
{{amount.asNumber.multiply(10)}}
- is related to
-
JSDCLOUD-10177 Automation smart value date time functions do not work on the Assets date time attributes
-
- Closed
-
I have a similar issue, just a different function.
The smart value is defined as "object."End of Life".plusMonths(object."Renewal Cycle in Months")".
The "End of Life" attribute is of type Default:Date and is set to 30. Sep 2023.
The "Renewal Cycle in Months" attribute is of type Default:Integer and is set to 1.
The result is printed as an empty string. If I exchange the 'object."Renewal Cycle in Months"' reference for a static 1, it evaluates as expected to 30. Oct 2023.
I expect the above smart value to also evaluate to 30. Oct 2023 with the given object state.
Luckily the workaround did work for me.