Weekend days

Sep 9, 2013 at 10:21 AM
Hi.

What a great piece of code! Compliments to the chef!

How can the ProjectManager ignore weekend days or holidays in its chart? Now the exact duration is always used to link the tasks.

Thanks for the info.
Coordinator
Sep 9, 2013 at 10:43 AM
Edited Sep 9, 2013 at 10:44 AM
Hello!

At the moment, there is no function to specify work days only.

You can brute force it
http://stackoverflow.com/questions/9413984/add-hours-to-datetime-but-exclude-weekends-and-should-be-between-working-hours
Or use a library
http://stackoverflow.com/questions/279296/adding-days-to-a-date-but-excluding-weekends
And then do some maths to get the number of days in the case of excluding weekends.

As for holidays, I guess would have to be a manual entry by the end user, and then you just check whether the holiday falls within your work duration
http://stackoverflow.com/questions/5672862/check-if-datetime-instance-falls-in-between-other-two-datetime-objects

Thanks for your interest!
Oct 30, 2013 at 10:09 AM