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

Dynamic - Move javascript handling

Asked by Jan Marten
14 years ago.

Hello Dan,

I am trying to handle move events by javascript so users can be warned when moving items from or into the past. The example you have given (here) is, well, almost working...

What I have done is adding a move-Javascript that needs to be executed by the dynamic scheduler like this:

EventMoveJavaScript="if (external) {schOverview_EventMove(e, newStart, newEnd, oldColumn, newColumn, true); } else {schOverview_EventMove(e, newStart, newEnd, oldColumn, newColumn, false);}"

Now the problem is that the values do not contain their correct values:

e, newStart and newEnd are correct.
oldColumn contains the value of newColumn (oldColumn value is available in e.row()).
newColumn contains probably the value of external (this is a boolean).

Could you explain this?

Kind regards,

Jan Marten

Comment posted by Dan Letecky
14 years ago.

This is a bug. oldColumn was removed because it's availabe as e.row(). But the custom handler was called incorrectly (using the old signature). It's now fixed (build 5.5.1771). It will be available in DayPilot Pro 5.5 release.

The signature of eventMoveCallBack is changed already so just skip the oldColumn value. The documentation for external drag&drop is now updated.

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