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

Compare with Current View Page History

Version 3 Next »

Use case

This use case calculates the total billable hours in Tempo logged in the current issue.

Configuration

Create a new Remote action and name it individually. Select method: POST and Default connection: Current instance

REST path
/rest/tempo-timesheets/4/worklogs/search
Action body
"{
  'taskKey': [
    '"+%{issue.key}+"'
  ]
}"

You can optinal use the parameters from  ("YYYY-MM-DD") and to ("YYYY-MM-DD") to request only work logs in a specific time frame.

Create a new Calculated Number Field (by JWT) custom field and name it properly.

Providing a description will help you to identify what the custom field does but this step is optional

Parser expression

Add the following expression:

Math expression for Calculated Number field:
toNumber(sum(toNumberList(executeRemoteAction("<NAME OF YOUR CREATED ACTION", "body[*].billableSeconds"),","))) / 3600
more info...

To achieve this, the following functions are used:



If you still have questions, feel free to refer to our support team.