I'm trying to set an automation to warn when a user enters an incorrect time spent by mistake (e.g. 800 weeks). 'timespent' seems to only look at the overall time logged on a task, not each instance of a user logging time. Is there a way to capture this?
Hello @Marine Redon
Welcome to the community.
Can you show us the rule you have constructed so far?
If you use the Work Logged trigger then you can use this smart value to get the time logged in that individual worklog:
{{worklog.timeSpent}}
You won't be able to use that in a JQL statement, though. There are no native functions that allow you to search for issues based on the time logged in individual worklog entries.
Here is my automation so far:
Would changing 'timespent' to '{{worklog.timeSpent}}' allow me to do what I want?
I'm trying to differentiate it because we might have tasks that go on for weeks, but no user should log more than a few days at a time.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
As I said, you can't use this smart value in a JQL because JQL doesn't support searching for issues based on times in individual worklogs.
Instead you would have to use an Advanced Compare condition.
Unfortunately the Timespent value is a string, so the comparison is done based on string comparison rather than numeric value comparison. If you're comparing that value to "5w" then an entry of "6d" would be evaluated as greater than "5w"
I have not yet found information on specific steps to convert a Timespent value to a numeric value.
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.