diff --git a/plugins/calendar/calendar_ui.js b/plugins/calendar/calendar_ui.js index aa8b3e99..72c89bce 100644 --- a/plugins/calendar/calendar_ui.js +++ b/plugins/calendar/calendar_ui.js @@ -1533,7 +1533,7 @@ function rcube_calendar_ui(settings) var update_event_confirm = function(action, event, data) { if (!data) data = event; - var decline = false, notify = false, html = ''; + var decline = false, notify = false, html = '', cal = me.calendars[event.calendar]; // event has attendees, ask whether to notify them if (has_attendees(event)) { @@ -1618,7 +1618,7 @@ function rcube_calendar_ui(settings) return false; } // show regular confirm box when deleting - else if (action == 'remove') { + else if (action == 'remove' && !cal.undelete) { if (!confirm(rcmail.gettext('deleteventconfirm', 'calendar'))) return false; } diff --git a/plugins/calendar/lib/calendar_ui.php b/plugins/calendar/lib/calendar_ui.php index f802091f..62cf0b4d 100644 --- a/plugins/calendar/lib/calendar_ui.php +++ b/plugins/calendar/lib/calendar_ui.php @@ -161,6 +161,7 @@ class calendar_ui $prop['attendees'] = $this->cal->driver->attendees; $prop['freebusy'] = $this->cal->driver->freebusy; $prop['attachments'] = $this->cal->driver->attachments; + $prop['undelete'] = $this->cal->driver->undelete; $jsenv[$id] = $prop; $html_id = html_identifier($id);