Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Check if {{now}} is a business day - Smart values

Gustavo Maia
Contributor
August 30, 2021

Hi,

I'm trying to create an automation rule that sends an email when an SLA will breach in 10 minutes.

The point I am facing troubles is that I want the email to be sent only if {{now}} is a business day.

How can I achieve that?

1 answer

1 accepted

4 votes
Answer accepted
Bill Sheboy
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.
August 30, 2021

Hi @Gustavo Maia 

You could try to increment {{now}} by one business day, and then decrement and see if it matches the date with an advanced condition before proceeding.  Something like:

  • First value: {{now.jiraDate}}
  • equals...
  • Second value: {{now.toBusinessDay.toBusinessDayBackwards.jiraDate}}

Best regards,
Bill

Gustavo Maia
Contributor
August 30, 2021

Hi @Bill Sheboy

Thank you for the quick answer.
It worked well

 

Best regards,
Gustavo Maia

Like • Bill Sheboy likes this
Thies Uhlenbruch
Contributor
February 2, 2023

Hi @Bill Sheboy 

works this also with a variable like:

{{variable.jiraDate}}

{{variable.toBusinessDay.toBusinessDayBackwards.jiraDate}}

It doesn't work for me

 

Kind regards,

Thies

Bill Sheboy
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.
February 4, 2023

Hi @Thies Uhlenbruch 

Created variables are text type, and so must be converted with .toDate before using the date/time functions with them.

Kind regards,
Bill

Suggest an answer

Log in or Sign up to answer