summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7dc88f6)
raw | patch | inline | side by side (parent: 7dc88f6)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 29 Nov 2006 07:00:15 +0000 (07:00 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 29 Nov 2006 07:00:15 +0000 (07:00 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@5239 594d385d-05f5-0310-b6e9-bd551577e9d8
plugins/admin/systems/class_divListSystem.inc | patch | blob | history | |
plugins/admin/systems/class_systemManagement.inc | patch | blob | history |
diff --git a/plugins/admin/systems/class_divListSystem.inc b/plugins/admin/systems/class_divListSystem.inc
index 9ca7308e34863955aed51446c334754ebfe97cc1..435f8291fda0ba698df4d61f6e656467de5e2fd0 100644 (file)
// Test Every Entry and generate divlist Array
foreach($terminals as $key => $val){
+ /* Get system type, it is used to fetch the acls for the current object.
+ "winstation" acls are stored as 2winworkstation", so we have to map this here */
$type = $this->parent->get_system_type($val['objectClass']);
- $acl_all = $ui->has_complete_category_acls($val['dn'],$type) ;
+ if($type == "winstation") {
+ $acl_type = "winworkstation";
+ }else{
+ $acl_type = $type;
+ }
+ $acl_all = $ui->has_complete_category_acls($val['dn'],$acl_type) ;
$action= "<input class='center' type='image' src='images/edit.png'
alt='"._("edit")."' name='user_edit_%KEY%' title='"._("Edit system")."'>";
diff --git a/plugins/admin/systems/class_systemManagement.inc b/plugins/admin/systems/class_systemManagement.inc
index de5f19e02be081ef24ca03962ae2bd1317e1ed4d..9918377e2b1ab44c10ed380f28a120d7ab404516 100644 (file)
if($this->DivListSystem->SubSearch){
if($oc['CLASS'] != ""){
$filter = "(|(&".$userregex."(objectClass=".$oc['CLASS'].")(cn=".$this->DivListSystem->Regex.")))";
- $res = array_merge($res,get_list($filter, array("terminal", "workstation", "server", "phone" ,"printer"), $base,
- array("cn", "description", "macAddress", "objectClass", "sambaDomainName", "FAIstate"), GL_NONE | GL_SUBSEARCH | GL_SIZELIMIT));
+ $new_res = get_list($filter, array("terminal", "workstation", "server", "phone" ,"printer"), $base,
+ array("cn", "description", "macAddress", "objectClass", "sambaDomainName", "FAIstate"), GL_NONE | GL_SUBSEARCH | GL_SIZELIMIT);
+
+ /* Remove all objects that are not in the expected sub department */
+ foreach($new_res as $key => $obj){
+ if(preg_match("/^[^,]+,".normalizePreg($oc['TREE'])."/",$obj['dn'])){
+ $res[$obj['dn']] = $obj;
+ }
+ }
}
}else{
/* User filter? */