X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=include%2Fclass_MultiSelectWindow.inc;h=bbba65eeeaf44d469bd63722a0e49c08779e8171;hb=7afa23783bbaf8d983427a43b13c19a398f01206;hp=caf994ba6b247bd7d71a97d365f35657e1fc1d5c;hpb=4f01ab8e3c7bd64c135fcc4415fdf43cd0629265;p=gosa.git diff --git a/include/class_MultiSelectWindow.inc b/include/class_MultiSelectWindow.inc index caf994ba6..bbba65eee 100644 --- a/include/class_MultiSelectWindow.inc +++ b/include/class_MultiSelectWindow.inc @@ -34,6 +34,7 @@ class MultiSelectWindow{ var $HideFilterPart = false; var $SaveAdditionalVars = array(); // Additional Post vars to store + var $module= ""; function ClearElementsList() { @@ -72,9 +73,10 @@ class MultiSelectWindow{ } /* Contrucktion */ - function MultiSelectWindow($config,$filterName) + function MultiSelectWindow($config, $filterName, $module) { $this->config = $config; + $this->module = $module; $this->SaveButtonString = _("Save"); $this->CloseButtonString = _("Close"); $this->filterName = $filterName; @@ -273,7 +275,7 @@ class MultiSelectWindow{ if($box['default'] == true){ $boxes .=" ".$box['string']."
"; }else{ - $boxes .=" ".$box['string']."
"; + $boxes .=" ".$box['string']."
"; } } $smarty->assign("CheckBoxes", $boxes); @@ -360,6 +362,11 @@ class MultiSelectWindow{ Store data also into a session var, to keep the checkboxes check after reload */ function save_object() { + /* Get up to date config */ + if(isset($this->parent->config)){ + $this->config = $this->parent->config; + } + /* Update current base */ if($this->DepartmentsAdded){ $s_action =""; @@ -497,10 +504,10 @@ class MultiSelectWindow{ title='"._("Restore snapshopts of already deleted objects")."' alt='"._("Restore")."' name='RestoreDeletedSnapShot'> "; }else{ - $str = " "; + $str = " "; } - $str .= " "; +# $str .= " "; } return($str); } @@ -515,7 +522,7 @@ class MultiSelectWindow{ $str.= " "; } else { - $str = " "; + $str = " "; } $str.= "departments = array(); /* Get all departments within this subtree */ - $deps= get_list("(&(|(ou=*)(description=*))(objectClass=gosaDepartment))", $this->ui->subtreeACL, - $base, array("ou", "description"), GL_SIZELIMIT | GL_CONVERT); + $deps= get_list("(&(|(ou=*)(description=*))(objectClass=gosaDepartment))", $this->module, $base, + array("ou", "description"), GL_SIZELIMIT | GL_CONVERT); /* Edit delete link for system types */ @@ -567,6 +574,7 @@ class MultiSelectWindow{ /* Add deps to this dialog object list */ foreach($this->departments as $key=> $val){ + /* Add missing entries ... */ if(!isset($this->config->departments[trim($key)])){ $this->config->departments[trim($key)]="";