summaryrefslogtreecommitdiffstats
path: root/apps/calendar/js/calendar.js
diff options
context:
space:
mode:
Diffstat (limited to 'apps/calendar/js/calendar.js')
-rw-r--r--apps/calendar/js/calendar.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/apps/calendar/js/calendar.js b/apps/calendar/js/calendar.js
index e943bee7057..af5ecd82816 100644
--- a/apps/calendar/js/calendar.js
+++ b/apps/calendar/js/calendar.js
@@ -108,23 +108,27 @@ Calendar={
},
moveEvent:function(event, dayDelta, minuteDelta, allDay, revertFunc){
$('.tipsy').remove();
- $.post(OC.filePath('calendar', 'ajax', 'moveevent.php'), { id: event.id, dayDelta: dayDelta, minuteDelta: minuteDelta, allDay: allDay?1:0},
+ $.post(OC.filePath('calendar', 'ajax', 'moveevent.php'), { id: event.id, dayDelta: dayDelta, minuteDelta: minuteDelta, allDay: allDay?1:0, lastmodified: event.lastmodified},
function(data) {
if (data.status == 'success'){
+ event.lastmodified = data.lastmodified;
console.log("Event moved successfully");
}else{
revertFunc();
+ $('#calendar_holder').fullCalendar('refetchEvents');
}
});
},
resizeEvent:function(event, dayDelta, minuteDelta, revertFunc){
$('.tipsy').remove();
- $.post(OC.filePath('calendar', 'ajax', 'resizeevent.php'), { id: event.id, dayDelta: dayDelta, minuteDelta: minuteDelta},
+ $.post(OC.filePath('calendar', 'ajax', 'resizeevent.php'), { id: event.id, dayDelta: dayDelta, minuteDelta: minuteDelta, lastmodified: event.lastmodified},
function(data) {
if (data.status == 'success'){
+ event.lastmodified = data.lastmodified;
console.log("Event resized successfully");
}else{
revertFunc();
+ $('#calendar_holder').fullCalendar('refetchEvents');
}
});
},