I am trying to create an automation for how long an issue was in progress. I have two dates now stored as a variable. How I can now show the difference without saving those dates. Alternatively, how I can store those values in the issue without making it visible to other users?
I tried:
1. Jira smart values - date and time / https://support.atlassian.com/cloud-automation/docs/jira-smart-values-date-and-time/
{{[date1].diff([date2]).[unit]}}
2. Jira smart values - math expressions
{{#=}}......{{/}}
Any hint?
From log you can see, I am getting the correct date values.
First thing: why do you want to hide this valuable piece of information? Hiding it seems in opposition to the agile concept of transparency. What problem are you trying to solve by hiding?
Regardless of that answer: mostly hiding the result is possible using visibility or obscurity. For example, you could write the value to a comment with limited visibility (e.g., Admins only) or you could save the value to an Entity Property...which would be more difficult to see.
Next thing: how accurate do you need this value to be?
Next...Depending upon the field types, you can use diff() as you found in the documentation. You may need to convert with toDate if your dates are stored as text values.
Finally, the measure you are describing is typically called Age of WIP. Please look at the post below for an example automation rule to calculate that value. You can alter this rule to handle business days only, and to handle exceptions, as needed, or based on status transitions for finer granularity.
Kind regards,
Bill
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.