diff options
Diffstat (limited to 'apps/calendar/js/calendar.js')
-rw-r--r-- | apps/calendar/js/calendar.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/apps/calendar/js/calendar.js b/apps/calendar/js/calendar.js index 1a8bc499574..61a1945c343 100644 --- a/apps/calendar/js/calendar.js +++ b/apps/calendar/js/calendar.js @@ -300,6 +300,19 @@ Calendar={ $('#dialog_holder').load(oc_webroot + '/apps/calendar/ajax/editeventform.php?id=' + id, Calendar.UI.startEventDialog); } }, + submitDeleteEventForm:function(url){ + var post = $( "#event_form" ).serialize(); + $("#errorbox").html(""); + $.post(url, post, function(data){ + if(data.status == 'success'){ + $('#event').dialog('destroy').remove(); + Calendar.UI.loadEvents(); + } else { + $("#errorbox").html("Deletion failed"); + } + + }, "json"); + }, validateEventForm:function(url){ var post = $( "#event_form" ).serialize(); $("#errorbox").html(""); |