Introduction

With the STAGIL User Time Accounts or SUTAJ app, it is easy to monitor any team's logged work hours and automate the calculation of their worktime balances.

The process is easy and essentially involves creating a custom field and establishing calculation parameters (via additional custom fields).

The field is the most effective within a certain set-up of the employee records. Below is an example of the use case that illustrates the optimal use of the field.

Use case: worked hours vs. contracted hours

Employee data is managed in Jira within the ‘Human Resources’ project. Each employee has an HR file (issue type = Employee), where they are mentioned as an assignee.

The SUTAJ field is used to reflect the difference between employee’s logged hours vs. required contracted hours within a certain period of time. In the screenshot below, we can see a SUTAJ field ‘Work Hours Balance’.

image-20240213-194215.png
SUTAJ field in issue view

Contract information that is used in the calculation by a SUTAJC field is stored in the same project in a ‘Contract’ issue type, which is (and must be) linked to the employee issue.

image-20240213-194256.png
Linked contract issue with contracted hours defined

The contract issue must contain a set of the following custom fields:

  1. Another SUTAJ field of type ‘Required User Work Log’: a field to store the number of contracted weekly hours.

  2. Date Time picker field for date values that mark the beginning of a processed time period, e.g. ‘Start Date' that marks the contract's start.

  3. Date Time picker field for date values that mark the end of a processed time period, e.g. ‘End Date’, that marks the contract's end.

Once the contract details are set, the field configuration can be updated so the correct values are used during the calculation.

Results

Once the calculation is completed, the 'Work Hours Balance' field will display the difference between the logged hours and the required hours. For instance, suppose Sue was supposed to log 48 hours by February 9th based on his contract. 

If he logged exactly 48 hours, then the value of the SUTAJ field would be '0'. 

If he logged 8 hours more than required, the value of the field would be '8' hours. 

If he logged 8 hours less than required, the field value would show '-8' hours. 

Create a STAGIL User Time Account field

Go to JIRA Administration → Issues → Custom Fields → Add Custom Field and choose STAGIL User Time Account.

Type a Name and optional a Description. Press Create.

Configure a STAGIL User Time Account field

Go to your custom field and press configure on the right side. Press Edit STAGIL User Time Account.

You have two tabs for configuration: Logged and Required (optional).

Logged Tab

Select the User field from whom the logged time should be displayed in this field. You can choose between Assignee and Reporter of the current issue.

Select the Period of the tracked time. You can select the following possibilities: Current DayCurrent WeekLast WeekCurrent MonthLast MonthCurrent YearLast Year, Current Year until now, Current month until now, First day of work until now and First Day of Work until end of last month. If you choose First day of work until now, the Required Tab is not optional anymore.

In the JQL field you can provide JQL to choose issue, from which you get work log.

Choose the Refresh interval to set the recalculation points. You can choose between Real Time or CRON.

For CRON you have the possibility to save the CRON Expression and another CRON JQL for which issues the CRON will be running.

In Billed hours you can select All work logs or Tempo Billed hours if you have licensed TEMPO Add-on.

Required (optional) Tab

Reduce logged work sum

You can leave the checkbox reduce logged work sum by required work unmarked, if you want to sum up all logged work.

Please mark the checkbox if you want to reduce logged work by the default working hours per user.

Select Required User Work Log Customfield, which should be placed on the Contract the issue is linked to.

Select Link to Contract, which connects this issue to the contract where the working time is based on. 

Select Contract Start Date Customfield where the beginning of the Contract is stored.

Select Contract End Date Customfield, where the end of the Contract is stored.

 Over time Pay JQL

You can reduce the work log sum by the added original estimation of issue given by these JQL. For example: issuetype = Overtimpay AND reporter =max.mustermann. 

Examples

Here is an example of calculating the logged work of the current month and the overtime of the current month for the employee Max Mustermann. In the related Work Contract you can see the Required User Work Log Field and the Contract Dates.

Here are the configurations of the custom fields Logged work current month and Overtime current month.

 

© 2023, STAGIL