It is possible to use drag and drop to move rows (representing resources) between two JavaScript Scheduler instances.
This feature is always active. To prevent dropping a row to another Scheduler instance, you can use the onRowMoving
event handler.
By default, the dragged row is removed from the source Scheduler. To keep it, call args.keeepSource()
in the target Scheduler onRowMove
event handler.
Available since version 2024.4.6270.
Example
Detecting a row from another Scheduler
You can detect the source Scheduler by checking the args.source.calendar
property in onRowMoving
, onRowMove
, and onRowMoved
event handlers. This property stores a DayPilot.Scheduler
object representing the source Scheduler.
Scheduler config:
{
onRowMove: args => {
if (args.external) {
console.log("External row drag and drop detected. Source Scheduler: " + args.source.calendar.id);
}
},
}