Here I go with another issue I am facing…
Seems like the addMarkedTimespan works quite inconsistently in timeline view as well (after reporting it buggy in the unit view)
Please take a look at this example: https://snippet.dhtmlx.com/l8nq1zlu
Just a simple timeline with 2 hrs block size. I am adding a blocked timespan which I would like to be from 22:00 till midnight. That renders fine and is clearly shown.
- If I drag-create an event and release the end (time) over the blocked timespan, the event is correctly “not created”
- However, if I drag-over the blocked timespan, completely crossing it and release the end on the next day (let’s say at 2am), the event is incorrectly “created”. This should not be the case - the event stretches over the blocked timespan!
To add to my confusion, this actually works correctly if I change the blocked times to some other value. For example changing it to [0 * 60, 2 * 60] works. [22 * 60, 23 * 60] works as well. They both prevent the event to be created. So why doesn’t [22 * 60, 24 * 60] work? Seems like there is something off if it is 24 (=the end of the “dayblock”).
To experiment I tried to set it to 23.99 * 60 but this worked even worse.
Thanks for your feedback.
EDIT: you can also just create an event which is not crossing the blocked time and then drag it over the blocked time so that the start and end time of the event are not over the blocked time. The event stays incorrectly ‘valid’ and in place.