Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

JQL for calculate working hours

Denis Shestov
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 5, 2018

Hello All! 

Help me pls. I want to get the following functionality:

we have working days and hours (as in most organizations).

Some issues are idle waiting for their performer.

How do i build a JQL for next example:

start work day: 9:30am
end work day: 6:00pm

we need notification email with condition: do not take into account the time of work outside the working day.
example:
Start issue: 5:30pm (1 march)
i want to recieve a notification by mail in case the task(issue) was not have assignee within 5 WORK hours.
thus: the letter should come to me after: 3pm (next day, 2 march)
how i can calculate the amount of time withou taking into account non-working time?
time in the period 6:01 to 9:29 should not be taken into account

 

2 answers

1 accepted

3 votes
Answer accepted
Aron Gombas _Midori_
Community Champion
March 6, 2018

What you describe is basically a Service Level Agreement (SLA). Those can be implemented in Jira either using Jira Service Desk or the Time to SLA app.

If you have SLA's in place, you can set up a saved filter that checks the SLA status and subscribe that filter to get your notification.

Denis Shestov
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 6, 2018

Hi Aron! 

Thank you fo reply! 

mail notification i can recieve from Automation Jira addon.

But i need JQL query for filter result search. 

Without Time to SLA app is this possible ?

Gezim Shehu [Communardo]
Community Champion
March 6, 2018

I've heard about scripted fields implementations for SLA.

 

This might be an example, but I'm sure you can find others

https://mraddon.blog/2016/06/09/calculate-the-sla-with-scripted-field-in-scriptrunner-for-jira/

Like Deleted user likes this
Denis Shestov
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 6, 2018

Hi Gezim! 

Tnak you too for reply! 

we don't have addon ScriptRunner = ( 

Gezim Shehu [Communardo]
Community Champion
March 6, 2018

You need some type of calculated field where you can write logic.

Sorry, I can't think of any other "good" ways of achieving this.

Denis Shestov
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 6, 2018

I thank you for your help! it will help me!

Gezim Shehu [Communardo]
Community Champion
March 6, 2018

Anytime

1 vote
Danyal Iqbal
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 6, 2018

This is not possible by default jql. You could either write a jql function in a custom plugin or use one of the add-ons on the marketplace which provide scripted fields e.g katl-commons or Power custom fields. Add the logic to your scripted field and use jql to query the field.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events