The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

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

Automation Time Tracking

Richard Branch
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 23, 2023

I am new to Jira so I am still learning.

I have taken over a project where users log completed tasks through a portal. They log the times they start and stop each task. I have a piece of automation that calculates the time taken and this is displayed in the description in hours and minutes.

Is there a way to automate this so it is added to time tracking?

 

2023-11-23_13-45-13.png

1 answer

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

1 vote
Ste Wright
Community Champion
November 23, 2023

Hi @Richard Branch 

This is possible! This should work (I've not included the Trigger/Conditions as I assume you have those from the other rule):

  • Action: Create Variable
    • Name = dateDiff
    • Smart Value = {{issue.customfield_123.diff(issue.customfield_10456).minutes}}
  • Action: Log Work
    • Time Spent = dateDiff
    • Date Started = {{issue.Work Start}}

---

A few notes on this rule:

  • For the Variable, I've used the Custom Field IDs - 123 represents Work Start, 456 represents Work End
  • I've set the Variable to minutes, as this is the default time unit in my instance - and it makes the Log Work action simpler. If your default time unit is different, I suggest setting it to whatever it is (eg. hours, seconds, etc)

---

Let us know if this works for you!

Ste

DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events