diff --git a/library/Director/Objects/IcingaObject.php b/library/Director/Objects/IcingaObject.php index 34a85f40..46acfa74 100644 --- a/library/Director/Objects/IcingaObject.php +++ b/library/Director/Objects/IcingaObject.php @@ -30,6 +30,8 @@ abstract class IcingaObject extends DbObject implements IcingaConfigRenderer protected $supportsFields = false; + protected $supportsApplyRules = false; + protected $type; /* key/value!! */ @@ -112,9 +114,15 @@ abstract class IcingaObject extends DbObject implements IcingaConfigRenderer return $this->supportsFields; } + public function supportsApplyRules() + { + return $this->supportsApplyRules; + } + public function hasBeenModified() { if ($this->supportsCustomVars() && $this->vars !== null && $this->vars()->hasBeenModified()) { +//var_dump($this->vars()); exit; return true; } diff --git a/library/Director/Objects/IcingaService.php b/library/Director/Objects/IcingaService.php index 852fea5c..ae4220b7 100644 --- a/library/Director/Objects/IcingaService.php +++ b/library/Director/Objects/IcingaService.php @@ -65,6 +65,8 @@ class IcingaService extends IcingaObject protected $supportsImports = true; + protected $supportsApplyRules = true; + protected $keyName = array('host_id', 'object_name'); public function getCheckCommand()