How to use Scripted Fields in ScriptRunner for Jira Cloud, to update the field with time?

Jayanth December 5, 2024

The goal is to create a Scripted Field that automatically calculates and displays the total time an issue spends in the In Progress status. The field should start tracking time when the issue transitions into the In Progress status and stop tracking as soon as the issue transitions out of this status, such as when it moves to Done or any other status.

When the issue transitions to In Progress, a timer should start, effectively capturing the time the issue remains in that status. This time should be dynamically updated while the issue stays in In Progress, ensuring an accurate reflection of the elapsed time. Once the issue transitions out of In Progress, the timer should stop, and the field should retain the calculated time without any further updates. This ensures the recorded time accurately reflects the total duration spent in In Progress for that particular lifecycle.

The Scripted Field will act as a read-only field, displaying the total time in a human-readable format (e.g., hours, minutes, seconds).

Note: I am using Jira Cloud.

0 answers

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events