Forums

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

Set Automation Due Date for the following month (1st Business Day of the Month)

darren.johnson September 7, 2021

I am trying to create a due date of the 1st Business day of the month.  But, if it is already past the first business day of the month, it needs to be the first business day of the following month.

When I do {{now.firstBusinessDayOfMonth}} it puts in the first business day of the current month, even when it is past that day (therefore being overdue)

Is there a way to make this work please ?

image.png

1 answer

1 accepted

2 votes
Answer accepted
Martin Bayer [MoroSystems, s.r.o.]
Community Champion
September 7, 2021

Hi @darren.johnson , Welcome on the community.

I just played with it a little and I think you can use If/Else to handle these two situations. Give it a try and let me know if it works, please :)

Selection_377.png

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.
September 7, 2021

Hi @darren.johnson -- Welcome to the Atlassian Community!

Yes, and...to what @Martin Bayer [MoroSystems, s.r.o.] suggests:

What do you want the result to be when {{now}} is currently the first business day of the month: use "today" or use "next month's first business day"?

Kind regards,
Bill

Like # people like this
darren.johnson September 8, 2021

Hiya,
@Martin Bayer [MoroSystems, s.r.o.] @Bill Sheboy 
Little confused here, I am looking for the result to be that when I move the task to completed it re-creates it for next months first business day, so for example I have a task for 1st October that when I move it to completed it auto recreates and changes the due date to 1st November both days are business working days and so on etc...

I have tried above formula and it does not work and has broken adding the epic and moving into planned.

image.png

Like ksavo likes this
darren.johnson September 8, 2021

@Bill Sheboy @Martin Bayer [MoroSystems, s.r.o.] 

Figured it out using {{duedate.plusMonths(1).firstBusinessDayOfMonth}}

Thank you for your help

image.png

Like Kristen Robinson likes this
Martin Bayer [MoroSystems, s.r.o.]
Community Champion
September 8, 2021

Hi @darren.johnson my example was not complete for your use case. I only wanted to show you how to use IF/ELSE and how to use Date smart values. In my opinion you need it because your implementation will cause

  • today's date is 1st October (Saturday)
  • user completes an issue and new issue should be created
  • due date for the new issue should be 3rd October (Monday)
  • your implementation will set 1st november which is wrong if I understand your initial question correctly :)
Like darren.johnson likes this

Suggest an answer

Log in or Sign up to answer