You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »

The function returns the NUMBER of milliseconds the current issue has remained in a status with name status_name.

If an issue has been in that status more than once, then duration will be summed up and the total time spent in the status will be returned.

Syntax
timeInStatus(string status_name) #Output: Number
Examples
Expression parserDescription
timeInStatus("Open")

The function returns the NUMBER of milliseconds the current issue has stayed in status "Open"

In order to display this value in a more readable way, the milliseconds should be transformed into a more readable unit, like in the following example:

timeInStatus("Open") / {DAY} - for number of days, or timeInStatus("Open") / {HOUR} - for number of hours.

Additional information

Parameters used in this function

ParameterInput (data type)Description
<parameter>

DATA TYPE

Parameter description.
Output

The function returns a NUMBER


The function returns the NUMBER of milliseconds the current issue has remained in a status with a name "status_name" within a schedule_name for a given time_zone

If an issue has been in that status more than once, then duration will be summed up and the total time spent in the status will be returned.

Syntax
timeInStatus(string status_name, string schedule_name, timeZone time_zone #Output: Number
Examples
Parser expressionDescription
timeInStatus("Open", "my_schedule", LOCAL)

the function returns the NUMBER of milliseconds the current issue has stayed in status "Open" within the schedule called "my_schedule" matching the server's default timeZone.

Additional information

Parameters used in this function

ParameterInput (data type)Description
<parameter>

DATA TYPE

Parameter description.
<parameter>

DATA TYPE

Parameter description.
timeZone

TIMEZONE

The time zone used for the calculation. 

Work days might depend on the time zone - it might be Sunday on the west coast of the US while at the same time it's already Monday in Australia. 

Output

The function returns a NUMBER


the function returns a NUMBER representing the sum of milliseconds issues in an issue list issues have remained in a status with the name "status_name". If an issue from that list has been in that status more than once, then duration will be summed up and the total time spent in the status will be returned.

Syntax
timeInStatus(string status_name, issue list issues) #Output: Number
Examples
Parser expressionDescription
timeInStatus("Open", subtasks()

The function returns the NUMBER of milliseconds the current issue's sub-tasks have stayed in status "Open"

Additional information

Parameters used in this function

ParameterInput (data type)Description
<parameter>

DATA TYPE

Parameter description.
<parameter>

DATA TYPE

Parameter description.
Output

The function returns a NUMBER


The function returns a NUMBER representing the sum of milliseconds issues in an issue list issues have remained in a status with the name "status_name" within a schedule named "schedule_name" for a given time_zone. If an issue from that list has been in that status more than once, then duration will be summed up and the total time spent in the status will be returned.

Syntax
timeInStatus(string status_name, issue list issues, string schedule_name, timeZone time_zone) #Output: Number
Examples
Parser expressionDescription
timeInStatus("Open", subtasks(), "my_schedule", LOCAL)

The function returns the NUMBER of milliseconds the current issue's sub-tasks have stayed in status "Open" within the schedule called "my_schedule" matching the server's default timeZone.

Additional information

Parameters used in this function

ParameterInput (data type)Description
<parameter>

DATA TYPE

Parameter description.
<parameter>

DATA TYPE

Parameter description.
<parameter>

DATA TYPE

Parameter description.
timeZone

TIMEZONE

The time zone used for the calculation. 

Work days might depend on the time zone - it might be Sunday on the west coast of the US while at the same time it's already Monday in Australia. 

Output

The function returns a NUMBER