The onRowMoving event handler fires in real time during row moving, whenever the current target position changes.
DayPilot.Scheduler.onRowMoving(args)args.source (DayPilot.Row) - dragged row
args.target (DayPilot.Row) - current target row
args.position ("before" | "after" | "child" | "forbidden") - current drop position relative to the target row
Possible values of args.position:
"before" - the row would be dropped before the target row
"after" - the row would be dropped after the target row
"child" - the row would be dropped as a child of the target row
"forbidden" - the current target does not allow dropping the row
JavaScript
const dp = new DayPilot.Scheduler("dp", {
onRowMoving: (args) => {
console.log("Moving row", args.source, args.position, args.target);
},
// ...
});
dp.init();Angular
<daypilot-scheduler [config]="config"></daypilot-scheduler>config: DayPilot.SchedulerConfig = {
onRowMoving: (args) => {
console.log("Moving row", args.source, args.position, args.target);
},
// ...
};React
<DayPilotScheduler
onRowMoving={onRowMoving}
{/* ... */}
/>const onRowMoving = (args) => {
console.log("Moving row", args.source, args.position, args.target);
};Vue
<DayPilotScheduler
@rowMoving="onRowMoving"
<!-- ... -->
/>const onRowMoving = (args) => {
console.log("Moving row", args.source, args.position, args.target);
};Row Moving [doc.daypilot.org]