onEventCollision

fires when the user tries to create a new event (or modify some existing one) inside of some already occupied time slot

boolean onEventCollision(object ev,array evs){ ... };

Parameters

evobjectthe event object
evsarraya collection of events' objects which already occupy the same time-slot

Returns

booleandefines 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

Returning true from the handler function blocks the event from being added/edited. Returning false - allows the collision, i.e. adding/editing events.

Back to top