Keep recurrence exceptions when updating an event

This commit is contained in:
Thomas Bruederli 2011-06-01 18:44:24 +02:00
parent 4c21f13eaf
commit 7e42d3207d
2 changed files with 5 additions and 1 deletions

View file

@ -681,7 +681,7 @@ window.rcmail && rcmail.addEventListener('init', function(evt) {
if (event.location) {
element.find('div.fc-event-title').after('<div class="fc-event-location">@&nbsp;' + Q(event.location) + '</div>');
}
if (event.recurrence_id)
if (event.recurrence)
element.find('div.fc-event-time').append('<i class="fc-icon-recurring"></i>');
if (event.alarms)
element.find('div.fc-event-time').append('<i class="fc-icon-alarms"></i>');

View file

@ -191,6 +191,10 @@ class database_driver extends calendar_driver
if ($old['recurrence'] || $old['recurrence_id']) {
$master = $old['recurrence_id'] ? $this->get_event($old['recurrence_id']) : $old;
// keep saved exceptions (not submitted by the client)
if ($old['recurrence']['EXDATE'])
$event['recurrence']['EXDATE'] = $old['recurrence']['EXDATE'];
switch ($event['savemode']) {
case 'new':
$event['uid'] = $this->cal->generate_uid();