check for cal_reference == 0 too when deleting a whole series. Otherwise all exceptions of an event will be deleted when just one exception was initially re-edited for deletion.

This commit is contained in:
Christian Binder 2010-01-22 20:04:30 +00:00
parent 9989afab6c
commit e7ca065e74

View File

@ -716,9 +716,9 @@ class calendar_uiforms extends calendar_ui
case 'delete':
if ($this->bo->delete($event['id'],(int)$content['edit_single']))
{
if (!$content['edit_single'])
if ($content['reference'] == 0 && !$content['edit_single'])
{
// We may delete a whole series
// We delete a whole series
$recur_exceptions = $this->bo->so->get_related($event['uid']);
foreach ($recur_exceptions as $id => $recur_date)
{