search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

How to span an event within business hours.

Asked by David Jacques
9 years ago.

Hi there,

I have an event that starts at 8 in the morning and lasts for 40 hours.

Is there a way not to set an end date, but rather make the calander control calculate the end date while keeping the event with in business hours?

For example, if the task starts on monday morning at 8 lasting 40 hours and the business hours are from 8 to 17, then the event will only finish on friday at 17. At the moment, the event will finish on Wednesday at 00:00.

Answer posted by Dan Letecky [DayPilot]
9 years ago.

This should be implemented as an extra layer of logic. You should keep the main event data in the database separate from the visible chunks (shifts) that will be passed to DayPilot and displayed. Each event will have one or more related shifts.

This way you are in full control of the chunking and DayPilot will be able to display it smoothly. You can also apply additional restrictions on the additional chunks (e.g. disallow moving).

This question is more than 3 months old and has been closed. Please create a new question if you have anything to add.