From: hickert Date: Tue, 3 Jul 2007 11:15:58 +0000 (+0000) Subject: udapted mime port X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=2eeb6c3d720f1493a43ca4c544f71ad4ddd3678b;p=gosa.git udapted mime port git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@6752 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/admin/mimetypes/class_divListMimeTypes.inc b/plugins/admin/mimetypes/class_divListMimeTypes.inc index dc4b36ec1..6adc6a9e6 100755 --- a/plugins/admin/mimetypes/class_divListMimeTypes.inc +++ b/plugins/admin/mimetypes/class_divListMimeTypes.inc @@ -52,7 +52,6 @@ class divListMimeTypes extends MultiSelectWindow onClick='toggle_all_(\"^item_selected_[0-9]*$\",\"select_all\");' >"; /* set Page header */ - $this->AddHeader(array("string"=> $chk, "attach"=>"style='width:20px;'")); $this->AddHeader(array("string" => " ", "attach" => "style='text-align:center;width:20px;'")); $this->AddHeader(array("string" => _("Mime type name")." / "._("Department"), "attach" => "style=''")); $this->AddHeader(array("string" => _("Actions"), "attach" => "style='width:".$action_col_size."px;border-right:0px;text-align:right;'")); @@ -158,13 +157,10 @@ class divListMimeTypes extends MultiSelectWindow $desc = " - [ ".$val['description'][0]." ]"; } - /* Create each field */ - $field0 = array("string" => "" , - "attach" => "style='width:20px;'"); $field1 = array("string" => sprintf($mimeimg,$val['dn']), "attach" => "style='text-align:center;width:20px;'"); $field2 = array("string" => sprintf($editlink,$key,($val['cn']['0'].$desc)), "attach" => "style='' ".$title); $field3 = array("string" => preg_replace("/%KEY%/", $key, $actions), "attach" => "style='width:".$action_col_size."px;border-right:0px;text-align:right;'"); - $this->AddElement(array($field0,$field1,$field2,$field3)); + $this->AddElement(array($field1,$field2,$field3)); } } diff --git a/plugins/admin/mimetypes/class_mimetypeGeneric.inc b/plugins/admin/mimetypes/class_mimetypeGeneric.inc index 6efbb480b..7a803015a 100644 --- a/plugins/admin/mimetypes/class_mimetypeGeneric.inc +++ b/plugins/admin/mimetypes/class_mimetypeGeneric.inc @@ -65,9 +65,7 @@ class mimetype extends plugin $this->orig_dn = $dn; $this->ui = get_userinfo(); - $acl= get_permissions ($dn, $this->ui->subtreeACL); - $this->acl= get_module_permission($acl, "mimetypes", $dn); - + /* get gotoMimeLeftClickActions I/E/Q */ if(isset($this->gotoMimeLeftClickAction)){ $str = $this->gotoMimeLeftClickAction; diff --git a/plugins/admin/mimetypes/class_mimetypeManagement.inc b/plugins/admin/mimetypes/class_mimetypeManagement.inc index 0dd9bff76..f4bf712fc 100755 --- a/plugins/admin/mimetypes/class_mimetypeManagement.inc +++ b/plugins/admin/mimetypes/class_mimetypeManagement.inc @@ -173,6 +173,10 @@ class mimetypeManagement extends plugin /* Create new usertab object */ $this->mimetabs= new mimetabs($this->config, $this->config->data['TABS']['MIMETABS'], $this->dn); + + /* Set up the users ACL's for this 'dn' */ + $acl= get_permissions ($this->DivListMimeTypes->selectedBase, $this->ui->subtreeACL); + $this->mimetabs->set_acl($acl); } @@ -248,6 +252,11 @@ class mimetypeManagement extends plugin /* Register mimetabs to trigger edit dialog */ $this->mimetabs= new mimetabs($this->config,$this->config->data['TABS']['MIMETABS'], $this->dn); + + /* Set up the users ACL's for this 'dn' */ + $acl= get_permissions ($this->DivListMimeTypes->selectedBase, $this->ui->subtreeACL); + $this->mimetabs->set_acl($acl); + $_SESSION['objectinfo']= $this->dn; } @@ -448,7 +457,7 @@ class mimetypeManagement extends plugin } /* Get results and create index */ - $res= get_list($Filter, "mimetypes", $use_base, array("cn","description","dn","objectClass"), $Flags); + $res= get_list($Filter, $this->ui->subtreeACL, $use_base, array("cn","description","dn","objectClass"), $Flags); foreach ($res as $val){ $tmp[strtolower($val['cn'][0]).$val['cn'][0].$val['dn']]=$val; }