onEventCollision
Description
Fires when the user tries to create a new event (or modify some existing one) inside of some already occupied time slot
onEventCollision: (ev: object, evs: array) => boolean;
Parameters
ev- (required) object - the event objectevs- (required) array - a collection of events' objects which already occupy the same time-slot
Returns
result- (boolean) - defines whether the default action of the event will be triggered (true) or canceled (false)
Example
scheduler.attachEvent("onEventCollision", function (ev, evs){
//any custom logic here
return true;
});
Details
note
The event requires the collision plugin to be activated.
Returning true from the handler function blocks the event from being added/edited. Returning false - allows the collision, i.e. adding/editing events.
Need help?
Got a question about the documentation? Reach out to our technical support team for help and guidance. For custom component solutions, visit the Services page.