| Issue 100: | a 'lock' functionality | |
| 7 people starred this issue and may be notified of changes. | Back to list |
Sign in to add a comment
|
useful while ajax is going and you dont want the user to change the calendar's state/events
Feb 13, 2011
Issue 819 has been merged into this issue.
Aug 13, 2013
While FullCalendar's built-in "event source" ajax calls are fetching, it is impossible to drag/resize anyway, but I see what you need this feature for... custom AJAX for other things. Rather than making a new "method", I think this would best be handled in a "setter" for the "editable" setting. Issue 293 deals with that, so I will merge this issue into that one.
Status:
Duplicate
Labels: -Type-Enhancement -Priority-Medium Type-Feature Mergedinto: 293 |
||||||||||
| ► Sign in to add a comment | |||||||||||
for anyone wanting this functionality in the meantime I was able to do it with the eventResize and eventDrop function: eventResize: function(event, dayDelta, minuteDelta, revertFunc, jsEvent, ui, view ) { event.editable = false; var eventObj = event; var transmitData = {'action':'updateCalendarActivity','activityID':event.id,'data' : $j.toJSON({'StartDateTime':event.start.getTime(),'EndDateTime':event.end.getTime(),'AllDay':event.allDay?'yes':'no'})}; $j.postJSON("url",transmitData,function(response){ if(response){ if(response.Status == 'Success'){ eventObj.editable = true; $j('#calendar').fullCalendar('renderEvent',eventObj); }else{ alert('System Error'); $j('#calendar').fullCalendar('refetchEvents'); } }else{ alert('System Error'); $j('#calendar').fullCalendar('refetchEvents'); } }); }, eventDrop: function(event, dayDelta, minuteDelta, allDay, revertFunc, jsEvent, ui, view ) { event.editable = false; var eventObj = event; var transmitData = {'action':'updateCalendarActivity','activityID':event.id,'data' : $j.toJSON({'StartDateTime':event.start.getTime(),'EndDateTime':event.end.getTime(),'AllDay':allDay?'yes':'no'})}; $j.postJSON("url",transmitData,function(response){ if(response){ if(response.Status == 'Success'){ eventObj.editable = true; $j('#calendar').fullCalendar('renderEvent',eventObj); }else{ $j('#calendar').fullCalendar('refetchEvents'); alert('System Error'); } }else{ $j('#calendar').fullCalendar('refetchEvents'); alert('System Error'); } }); }