summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 252ca84)
raw | patch | inline | side by side (parent: 252ca84)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 26 Jul 2006 07:55:35 +0000 (07:55 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 26 Jul 2006 07:55:35 +0000 (07:55 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@4306 594d385d-05f5-0310-b6e9-bd551577e9d8
include/class_acl.inc | patch | blob | history |
diff --git a/include/class_acl.inc b/include/class_acl.inc
index fe19f9a7ef7e24253a36cfb8685e47dc39d7e92e..8103ba16e8e4a756dfbf215a447f9113d656eeef 100644 (file)
--- a/include/class_acl.inc
+++ b/include/class_acl.inc
/* Find multi homed classes */
if (count($acls['plCategory']) > 1){
- $this->multiClass[]= $class;
+ $this->multiClass[$class]= $class;
}
/* Walk through supplied list and feed only translated categories */
if (is_array($data['objectClass'])){
foreach($data['objectClass'] as $objectClass){
if (in_array_ics($objectClass, $oc)){
- $this->myAclObjects[$class]= $acls['plDescription'];
+ if (isset($this->multiClass[$class])){
+ $this->myAclObjects[$idx.'/'.$class]= $acls['plDescription'];
+ } else {
+ $this->myAclObjects[$class]= $acls['plDescription'];
+ }
break;
}
}
} else {
if (in_array_ics($data['objectClass'], $oc)){
- $this->myAclObjects[$class]= $acls['plDescription'];
+ if (isset($this->multiClass[$class])){
+ $this->myAclObjects[$idx.'/'.$class]= $acls['plDescription'];
+ } else {
+ $this->myAclObjects[$class]= $acls['plDescription'];
+ }
}
}
}
if ($aclDialog && isset($this->ocMapping[$this->aclObject])){
foreach ($this->ocMapping[$this->aclObject] as $oc){
unset($this->aclContents[$oc]);
+ unset($this->aclContents[$this->aclObject.'/'.$oc]);
if (isset($new_acl[$oc])){
$this->aclContents[$oc]= $new_acl[$oc];
}
+ if (isset($new_acl[$this->aclObject.'/'.$oc])){
+ $this->aclContents[$this->aclObject.'/'.$oc]= $new_acl[$this->aclObject.'/'.$oc];
+ }
}
}
if ($idx == 0){
continue;
}
- $aclObjects[$class]= $plist[$class]['plDescription'];
+ if (isset($this->multiClass[$class])){
+ $aclObjects[$this->aclObject.'/'.$class]= $plist[$class]['plDescription'];
+ } else {
+ $aclObjects[$class]= $plist[$class]['plDescription'];
+ }
}
$smarty->assign('aclSelector', $this->buildAclSelector($aclObjects));
}
$options= $this->mkchkbx($key."_0_c", _("Create objects"), preg_match('/c/', $currentAcl[0])).$spc;
$options.= $this->mkchkbx($key."_0_m", _("Move objects"), preg_match('/m/', $currentAcl[0])).$spc;
$options.= $this->mkchkbx($key."_0_d", _("Remove objects"), preg_match('/d/', $currentAcl[0])).$spc;
- if ($plist[$key]['plSelfModify']){
+ if ($plist[preg_replace('%^.*/%', '', $key)]['plSelfModify']){
$options.= $this->mkchkbx($key."_0_s", _("Modifyable by owner"), preg_match('/s/', $currentAcl[0])).$spc;
}
} else {
$options= $this->mkchkbx($key."_0_m", _("Move object"), preg_match('/m/', $currentAcl[0])).$spc;
$options.= $this->mkchkbx($key."_0_d", _("Remove object"), preg_match('/d/', $currentAcl[0])).$spc;
- if ($plist[$key]['plSelfModify']){
+ if ($plist[preg_replace('%^.*/%', '', $key)]['plSelfModify']){
$options.= $this->mkchkbx($key."_0_s", _("Modifyable by owner"), preg_match('/s/', $currentAcl[0])).$spc;
}
}
/* Walk through the list of attributes */
$cnt= 1;
- $splist= $plist[$key]['plProvidedAcls'];
+ $splist= $plist[preg_replace('%^.*/%', '', $key)]['plProvidedAcls'];
asort($splist);
foreach($splist as $attr => $dsc){