mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-23 13:54:27 +02:00
IcingaObject: add awareness for apply object type
This commit is contained in:
parent
bda927b446
commit
fb6518a887
@ -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;
|
||||
}
|
||||
|
||||
|
@ -65,6 +65,8 @@ class IcingaService extends IcingaObject
|
||||
|
||||
protected $supportsImports = true;
|
||||
|
||||
protected $supportsApplyRules = true;
|
||||
|
||||
protected $keyName = array('host_id', 'object_name');
|
||||
|
||||
public function getCheckCommand()
|
||||
|
Loading…
x
Reference in New Issue
Block a user