Disable free-busy trigerring by default

This commit is contained in:
Thomas Bruederli 2012-09-19 11:17:15 +02:00
parent 23ec4b8517
commit c24303fe5d
2 changed files with 10 additions and 4 deletions

View file

@ -104,4 +104,7 @@ $rcmail_config['calendar_categories'] = array(
'Holiday' => 'ff6600',
);
// enable asynchronous free-busy triggering after data changed
$rcmail_config['calendar_freebusy_trigger'] = false;
?>

View file

@ -40,6 +40,7 @@ class kolab_driver extends calendar_driver
private $cal;
private $calendars;
private $has_writeable = false;
private $freebusy_trigger = false;
/**
* Default constructor
@ -52,6 +53,8 @@ class kolab_driver extends calendar_driver
$this->cal->register_action('push-freebusy', array($this, 'push_freebusy'));
$this->cal->register_action('calendar-acl', array($this, 'calendar_acl'));
$this->freebusy_trigger = $this->rc->config->get('calendar_freebusy_trigger', false);
}
@ -290,7 +293,7 @@ class kolab_driver extends calendar_driver
$success = $storage->insert_event($event);
if ($success)
if ($success && $this->freebusy_trigger)
$this->rc->output->command('plugin.ping_url', array('action' => 'calendar/push-freebusy', 'source' => $storage->id));
return $success;
@ -403,7 +406,7 @@ class kolab_driver extends calendar_driver
}
}
if ($success)
if ($success && $this->freebusy_trigger)
$this->rc->output->command('plugin.ping_url', array('action' => 'calendar/push-freebusy', 'source' => $storage->id));
return $success;
@ -424,7 +427,7 @@ class kolab_driver extends calendar_driver
else
$success = $storage->restore_event($event);
if ($success)
if ($success && $this->freebusy_trigger)
$this->rc->output->command('plugin.ping_url', array('action' => 'calendar/push-freebusy', 'source' => $storage->id));
return $success;
@ -605,7 +608,7 @@ class kolab_driver extends calendar_driver
break;
}
if ($success)
if ($success && $this->freebusy_trigger)
$this->rc->output->command('plugin.ping_url', array('action' => 'calendar/push-freebusy', 'source' => $storage->id));
return $success;