X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=gosa-plugins%2Ffai%2Fadmin%2Ffai%2Fclass_faiVariable.inc;h=0847d8842c3584d039447498b6a37c63d011f938;hb=ff3ef83f8dcb54659807a39f8513486b5c0badb0;hp=f8f1b3be44483430aeca053dce72cf9e50cab267;hpb=8e7a67036810003fc2bdf835f9bdb98b4eea3bbe;p=gosa.git diff --git a/gosa-plugins/fai/admin/fai/class_faiVariable.inc b/gosa-plugins/fai/admin/fai/class_faiVariable.inc index f8f1b3be4..0847d8842 100644 --- a/gosa-plugins/fai/admin/fai/class_faiVariable.inc +++ b/gosa-plugins/fai/admin/fai/class_faiVariable.inc @@ -65,7 +65,7 @@ class faiVariable extends plugin { if($dn == "new" || $dn == ""){ if($this->dn == "new"){ - $dn = session::get('CurrentMainBase'); + $dn= $this->parent->parent->acl_base; }else{ $dn = $this->dn; } @@ -99,7 +99,7 @@ class faiVariable extends plugin } if($this->dn != "new"){ - session::set('objectinfo',$this->dn); + set_object_info($this->dn); } @@ -113,7 +113,7 @@ class faiVariable extends plugin $this->dialog->set_acl_base($c_dn); $this->dialog->FAIstate = $this->FAIstate; $this->dialog->parent = &$this; - session::set('objectinfo',$this->SubObjects[$var]['dn']); + set_object_info($this->SubObjects[$var]['dn']); $this->is_dialog=true; } @@ -257,12 +257,12 @@ class faiVariable extends plugin $ldap = $this->config->get_ldap_link(); $ldap->cd ($this->dn); $release = $this->parent->parent->fai_release; - $use_dn = preg_replace("/".preg_quote(FAI::get_release_dn($this->dn))."/i", $release, $this->dn); + $use_dn = preg_replace("/".preg_quote(FAI::get_release_dn($this->dn), '/')."/i", $release, $this->dn); new log("remove","fai/".get_class($this),$use_dn,$this->attributes); FAI::prepare_to_save_FAI_object($use_dn,array(),true); foreach($this->SubObjects as $name => $obj){ - $use_dn = preg_replace("/".preg_quote(FAI::get_release_dn($this->dn))."/i", $release, $obj['dn']); + $use_dn = preg_replace("/".preg_quote(FAI::get_release_dn($this->dn), '/')."/i", $release, $obj['dn']); FAI::prepare_to_save_FAI_object($use_dn,array(),true); } $this->handle_post_events("remove"); @@ -329,7 +329,7 @@ class faiVariable extends plugin $tmp = array(); foreach($this->subAttributes as $attrs){ - if($obj[$attrs] == ""){ + if(!isset($obj[$attrs]) || $obj[$attrs] == ""){ $obj[$attrs] = array(); } $tmp[$attrs] = $obj[$attrs];