DirectorObjectForm: allow to set object externally

This commit is contained in:
Thomas Gelf 2015-08-02 15:07:41 +02:00
parent 44013eec42
commit 02daf8b97a
1 changed files with 10 additions and 0 deletions

View File

@ -372,6 +372,16 @@ abstract class DirectorObjectForm extends QuickForm
return $this->object;
}
public function setObject(IcingaObject $object)
{
$this->object = $object;
if ($this->db === null) {
$this->setDb($db);
}
return $this;
}
protected function getObjectClassname()
{
if ($this->className === null) {