X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=plugins%2Fadmin%2Fsystems%2Fclass_terminalStartup.inc;h=dfae3014777783a594ef3e81bd8ba5dee3f04ce4;hb=7a6a428eb1c6534e448094d51bc6a542fe832bb9;hp=4b30c443e80531d05dfefd003acdaa04ddeb87e7;hpb=ceddb78c594529972acc6bd40c637cc2efdd172b;p=gosa.git diff --git a/plugins/admin/systems/class_terminalStartup.inc b/plugins/admin/systems/class_terminalStartup.inc index 4b30c443e..dfae30147 100644 --- a/plugins/admin/systems/class_terminalStartup.inc +++ b/plugins/admin/systems/class_terminalStartup.inc @@ -24,7 +24,7 @@ class termstartup extends plugin /* attribute list for save action */ - var $attributes= array("gotoLdapServer", "gotoBootKernel", "gotoKernelParameters"); + var $attributes= array("gotoLdapServer", "gotoBootKernel", "gotoKernelParameters","gotoModules"); var $objectclasses= array("GOhard"); /* Helper */ @@ -40,6 +40,7 @@ class termstartup extends plugin /* Get arrays */ foreach (array("gotoModules") as $val){ + $this->$val = array(); if (isset($this->attrs["$val"]["count"])){ for ($i= 0; $i<$this->attrs["count"]; $i++){ if (isset($this->attrs["$val"][$i])){ @@ -143,6 +144,10 @@ class termstartup extends plugin } } } + + if($this->is_account){ + @log::log("view","terminal/".get_class($this),$this->dn); + } } function execute() @@ -288,6 +293,7 @@ class termstartup extends plugin { if($this->acl_is_removeable()){ $this->handle_post_events("remove"); + @log::log("remove","terminal/".get_class($this),$this->dn,array_keys($this->attrs)); } } @@ -369,7 +375,9 @@ class termstartup extends plugin $this->attrs["$val"]= array_unique($this->$val); } - if(!isset($this->attrs["$val"])) $this->attrs["$val"]=array(); + if(!isset($this->attrs["$val"])){ + $this->attrs["$val"]=array(); + } } /* Strip out 'default' values */ @@ -391,9 +399,12 @@ class termstartup extends plugin /* Write back to ldap */ $ldap= $this->config->get_ldap_link(); $ldap->cd($this->dn); + $this->cleanup(); $ldap->modify ($this->attrs); + @log::log("modify","terminal/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error()); + show_ldap_error($ldap->get_error(), sprintf(_("Saving of system terminal/startup with dn '%s' failed."),$this->dn)); $this->handle_post_events("modify"); }