IcingaObject: scheduled downtime awareness
This is not optimal, but that's how it works right now
This commit is contained in:
parent
54b62c7179
commit
9a21ace300
|
@ -2558,6 +2558,8 @@ abstract class IcingaObject extends DbObject implements IcingaConfigRenderer
|
||||||
$type = 'templateChoiceHost';
|
$type = 'templateChoiceHost';
|
||||||
} elseif ($type === 'service_template_choice') {
|
} elseif ($type === 'service_template_choice') {
|
||||||
$type = 'TemplateChoiceService';
|
$type = 'TemplateChoiceService';
|
||||||
|
} elseif ($type === 'scheduled_downtime') {
|
||||||
|
$type = 'ScheduledDowntime';
|
||||||
}
|
}
|
||||||
|
|
||||||
return 'Icinga\\Module\\Director\\Objects\\' . $prefix . ucfirst($type);
|
return 'Icinga\\Module\\Director\\Objects\\' . $prefix . ucfirst($type);
|
||||||
|
@ -3013,7 +3015,7 @@ abstract class IcingaObject extends DbObject implements IcingaConfigRenderer
|
||||||
{
|
{
|
||||||
$params = array();
|
$params = array();
|
||||||
|
|
||||||
if ($this->isApplyRule()) {
|
if ($this->isApplyRule() && ! $this instanceof IcingaScheduledDowntime) {
|
||||||
$params['id'] = $this->get('id');
|
$params['id'] = $this->get('id');
|
||||||
} else {
|
} else {
|
||||||
$params = array('name' => $this->getObjectName());
|
$params = array('name' => $this->getObjectName());
|
||||||
|
|
Loading…
Reference in New Issue