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

How to keep original dates when moving events

Asked by JDEC
5 years ago.

Hi,

I am building a agenda for the company employees and would like to avoid colliding events (they should not have 2 appointments at the same time of the day).

While I manage to identify the conflicting meetings and avoid them when creating a new event, I would to be able to restore the event to its original position when moving or resizing an event which would then conflict then with another appointment on the agenda.

Any help please ?

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

You can call args.preventDefault() in onEventMove (not onEventMoved) to cancel the moving action:
https://api.daypilot.org/daypilot-scheduler-oneventmove/

It's also possible to use the built-in overlap prevention feature:
https://doc.daypilot.org/scheduler/event-overlaps/

Comment posted by FM
5 years ago.

The built-in feature is brilliant !!

Thanks for the support.

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