mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-31 01:34:12 +02:00
IcingaService: use booleans, drop custom renderers
This commit is contained in:
parent
e2fad6eb79
commit
53c0f94f27
@ -45,6 +45,17 @@ class IcingaService extends IcingaObject
|
|||||||
'zone' => 'IcingaZone',
|
'zone' => 'IcingaZone',
|
||||||
);
|
);
|
||||||
|
|
||||||
|
protected $booleans = array(
|
||||||
|
'enable_notifications',
|
||||||
|
'enable_active_checks',
|
||||||
|
'enable_passive_checks',
|
||||||
|
'enable_event_handler',
|
||||||
|
'enable_flapping',
|
||||||
|
'enable_perfdata',
|
||||||
|
'volatile',
|
||||||
|
'use_agent',
|
||||||
|
);
|
||||||
|
|
||||||
protected $supportsGroups = true;
|
protected $supportsGroups = true;
|
||||||
|
|
||||||
protected $supportsCustomVars = true;
|
protected $supportsCustomVars = true;
|
||||||
@ -88,44 +99,4 @@ class IcingaService extends IcingaObject
|
|||||||
{
|
{
|
||||||
return $this->getResolvedProperty('check_command_id') !== null;
|
return $this->getResolvedProperty('check_command_id') !== null;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected function renderCheck_command_id()
|
|
||||||
{
|
|
||||||
return $this->renderCommandProperty($this->check_command_id);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected function renderEnable_notifications()
|
|
||||||
{
|
|
||||||
return $this->renderBooleanProperty('enable_notifications');
|
|
||||||
}
|
|
||||||
|
|
||||||
protected function renderEnable_active_checks()
|
|
||||||
{
|
|
||||||
return $this->renderBooleanProperty('enable_active_checks');
|
|
||||||
}
|
|
||||||
|
|
||||||
protected function renderEnable_passive_checks()
|
|
||||||
{
|
|
||||||
return $this->renderBooleanProperty('enable_passive_checks');
|
|
||||||
}
|
|
||||||
|
|
||||||
protected function renderEnable_event_handler()
|
|
||||||
{
|
|
||||||
return $this->renderBooleanProperty('enable_event_handler');
|
|
||||||
}
|
|
||||||
|
|
||||||
protected function renderEnable_flapping()
|
|
||||||
{
|
|
||||||
return $this->renderBooleanProperty('enable_flapping');
|
|
||||||
}
|
|
||||||
|
|
||||||
protected function renderEnable_perfdata()
|
|
||||||
{
|
|
||||||
return $this->renderBooleanProperty('enable_perfdata');
|
|
||||||
}
|
|
||||||
|
|
||||||
protected function renderVolatile()
|
|
||||||
{
|
|
||||||
return $this->renderBooleanProperty('volatile');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user