Code

Udpated ACL listing-
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 23 Dec 2009 14:18:11 +0000 (14:18 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 23 Dec 2009 14:18:11 +0000 (14:18 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14940 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-core/plugins/admin/acl/acl-filter.xml
gosa-core/plugins/admin/acl/acl-list.xml
gosa-core/plugins/admin/acl/class_aclManagement.inc
gosa-core/plugins/admin/acl/class_filterACL.inc

index 0a9bd5f08901824182a8f0103e44b316cd7d847e..adf81e48ea20460681648d7168cb87bd3e127d17 100644 (file)
@@ -34,7 +34,6 @@
       <filter>(&amp;(|(objectClass=gosaAcl)(objectClass=gosaRole))(|(ou=*$NAME*)(description=*$NAME*)(cn=*$NAME*)))</filter>
       <attribute>ou</attribute>
       <attribute>cn</attribute>
-      <attribute>description</attribute>
       <frequency>0.5</frequency>
       <characters>3</characters>
     </autocomplete>
index 5db47fb3679ec6a625f6b26503397b6476d7ff6a..ec6ed4a998675ced35c6e15e9aa6f20635d5ffb9 100644 (file)
@@ -30,7 +30,7 @@
   </definition>
 
   <table>
-    <layout>|16px||150px|170px;r|</layout>
+    <layout>|16px|200px||170px;r|</layout>
 
     <department>
       <value>%{filter:objectType(dn,objectClass)}</value>
@@ -49,7 +49,7 @@
       <label>Name</label>
       <sortAttribute>dn</sortAttribute>
       <sortType>string</sortType>
-      <value>%{filter:filterLabel(row,dn,"%s",ou,cn,pid,base)}</value>
+      <value>%{filter:filterLabel(row,dn,ou,cn,pid,base)}</value>
       <export>true</export>
     </column>
 
index 6329dc01b022131913922a05af602568116c69b9..ece0a84f8b99ea7a264574241d3bfad8fed5babe 100644 (file)
@@ -38,7 +38,7 @@ class aclManagement extends management
     $this->config = $config;
     $this->ui = $ui;
    
-    $this->storagePoints = array(); // ACLs are attached to department containers
+    $this->storagePoints = array(get_ou("aclRoleRDN")); // ACLs are attached to department containers
  
     // Build filter
 #    if (session::global_is_set(get_class($this)."_filter")){
@@ -67,16 +67,16 @@ class aclManagement extends management
   }
 
   // A filter which allows to open a department by clicking on the departments name.
-  static function filterLabel($row,$dn,$params,$ou= array(),$cn=array(),$pid=0,$base="")
+  static function filterLabel($row,$dn,$ou= array(),$pid=0,$base="")
   {
-    if(!isset($ou[0])){
-      $ou = $cn[0];
-    }else{
-      $ou = $ou[0];
-    }
+    $ou = $ou[0];
     if($dn == $base){
-      $ou =".";
+      $ou =" . ";
+    }
+    if(!preg_match("/^cn=/",$dn)){
+      $ou.="  &nbsp; ["._("ACL Assignment")."]";
     }
+
     $dn= LDAP::fix(func_get_arg(1));
     return("<a href='?plug=".$_GET['plug']."&amp;PID=$pid&amp;act=listing_open_$row' title='$dn'>$ou</a>");
   }
index a12e22796622d9d60743bc44df75477af403d46d..a9d7cb9b2fe7fefccca357ebafddfca0b09e0c96 100644 (file)
@@ -7,7 +7,8 @@ class filterACL {
     $config= session::global_get('config');
     $ldap= $config->get_ldap_link(TRUE);
     $flag= ($scope == "sub")?GL_SUBSEARCH:0;
-    $result= filterACL::get_list($base, $filter, $attributes, $category, $objectStorage, $flag | GL_SIZELIMIT, "cat");
+    $result= filterACL::get_list($base, $filter, $attributes, $category, array(), $flag | GL_SIZELIMIT, "cat");
+    $result= array_merge($result,filterACL::get_list($base, $filter, $attributes, $category, array(), $flag | GL_SIZELIMIT, ""));
     $result= array_merge($result,filterACL::get_list($base, $filter, $attributes, $category, $objectStorage, $flag | GL_SIZELIMIT, ""));
     return(filterACL::unifyResult($result));
   }