How to automate roster based assignment using project automation

Still need help?

The Atlassian Community is here for you.

Platform Notice: Cloud Only - This article only applies to Atlassian products on the cloud platform.

Purpose

The purpose of this automation is to provide a way to automate the issue assignment using a roster.

Solution

• This automation works on the following assumptions.
• Each workday is eight hours long divided into 2 halves of four hours each.
• The first half runs from 9 AM to 1 PM and the second half starts from 1 PM and ends at 5 PM.
• Each half can have a different set of assignees.

IF block showing the logic for determining the first half of any given day

IF block - Condition 1 (Determining the day of the week)

``{{issue.created.convertToTimeZone("Australia/Sydney").dayOfWeekName}}``

IF block - Condition 2 (Determining start of the first half)

``{{#=}}{{issue.created.convertToTimeZone("Australia/Sydney").hour}} >= 9{{/}}``

IF block - Condition 3 (Determining end of the first half)

``{{#=}}((({{issue.created.convertToTimeZone("Australia/Sydney").hour}} - 9) * 60) + {{now.convertToTimeZone("Australia/Sydney").minute}}) <= 240{{/}}``

Similarly, the formula for the other half can be driven

``{{#=}}{{issue.created.convertToTimeZone("Australia/Sydney").hour}} >= 13{{/}}``
``{{#=}}((({{issue.created.convertToTimeZone("Australia/Sydney").hour}} - 13) * 60) + {{issue.created.convertToTimeZone("Australia/Sydney").minute}}) <= 240{{/}}``

This entire IF-ELSE block can be repeated for the whole week either without modification or the length of each half can be changed by changing the number in the compare conditions. Currently each half is assumed four hours long hence it is compared to 240 which is the total number of minutes in four hours.

Description The purpose of this automation is to provide a way to automate the issue assignment using a roster. Jira, Jira Service Management