0
votes

I am using FullCalendar v1.6.1. In my code when event resize I am checking certain conditions and if not valid make it as original by calling revertFunc(). But currently I am getting error

Uncaught TypeError: revertFunc is not a function

But revert function is working on eventDrop and drop events. My code is as follows

eventResize: function (event, delta, revertFunc) {
   if(!valid){
       revertFunc(); // Get the error
   }
},
eventDrop: function (event, dayDelta, minuteDelta, allDay, revertFunc) {
   if(!valid){
       revertFunc(); // Working fine
   }
}
1
i never seen like if(not valid). I am sure it should be like if(!valid)vijayP
It is just text to understand.Gayan Fernando

1 Answers

0
votes

In docs of fullcalendar on this LINK (your version), there is revert function fourth parameter. You need to extend eventResize function on four (or more) parameters and set revertFunc on 4th place, like this (from docs):

function( event, dayDelta, minuteDelta, revertFunc, jsEvent, ui, view ) { }