My favorites | Sign in
Project Home Issues
New issue   Search
for
  Advanced search   Search tips   Subscriptions
Issue 100: a 'lock' functionality
7 people starred this issue and may be notified of changes. Back to list
Status:  Duplicate
Merged:  issue 293
Owner:  adamrs...@gmail.com
Closed:  Aug 2013


Sign in to add a comment
 
Project Member Reported by adamrs...@gmail.com, Sep 21, 2009
useful while ajax is going and you dont want the user to change the
calendar's state/events
Jan 20, 2010
#1 sneed...@gmail.com
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');
		}
});	
					}
Feb 13, 2011
Project Member #2 adamrs...@gmail.com
 Issue 819  has been merged into this issue.
Aug 13, 2013
Project Member #3 adamrs...@gmail.com
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

Powered by Google Project Hosting