Discuss anything related to web development but no technical support questions
Hi there,
I would like to know if it's possible to prevent the endTime of an event changing when I change the startTime using the startTimeField.
I have tried adding a change listener to the startTimeField, but I'm having trouble preventing the change to the endTime when the startTime increases or decreases.
Is there a feature for this? Or does anyone know the correct listener so that the endTime (and endDate, since when the endTime passes 00:00 the endDate also goes up 1 day) stay the same?
Thank you!
Hey lxxrxns,
The default behavior of Scheduler is to maintain the duration of an event, it means that for example, if an event has a duration of four days when you change the start date, it'll count as four days from there.
If you want to maintain the same endTime/endDate, you'll need to change the duration of the event.
Hi marcio,
Due to a different bug in Scheduler ( viewtopic.php?t=21622 ) that is currently not yet fixed, I made my scheduler so that every event has an end time of 23:59:00. This way, events will always overlap and therefore pack correctly.
However, as you can imagine, this results in a problem when changing the start time of an event (because then the end time passes onto the next day, and the end date changes...).
Would it be at all possible to prevent the end date and end time changing automatically when I change the start time? (i.e. disable keeping the duration the same?)