Code

Some acl changes
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 4 Aug 2006 09:27:23 +0000 (09:27 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 4 Aug 2006 09:27:23 +0000 (09:27 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@4392 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/personal/mail/class_mailAccount.inc

index 6b9ae99faaebe47cb446f13a71fab21184474d62..1d9c3131ad84050853f2ece06e7d4d4c43c8d104 100644 (file)
@@ -484,10 +484,11 @@ class mailAccount extends plugin
     /* Display mail account tab */
 
     $smarty->assign("mailServers", $mailserver);
+    $SkipWrite = (!isset($this->parent) || !$this->parent) && !isset($_SESSION['edit']);
 
     $tmp  = $this->plInfo();
     foreach($tmp['plProvidedAcls'] as $name => $transl){
-      $smarty->assign("$name"."ACL", $this->getacl($name));
+      $smarty->assign("$name"."ACL", $this->getacl($name,$SkipWrite));
     }
 
     foreach(array("gosaMailServer", "gosaMailQuota", "perms", "mail",
@@ -507,7 +508,7 @@ class mailAccount extends plugin
     /* Disable mail field if needed */
     $method= new $this->method($this->config);
     if ($method->uattrib == "mail" && $this->initially_was_account){
-      $smarty->assign("mailACL", "disabled");
+      $smarty->assign("mailACL", preg_replace("/w/","",$this->getacl("mail",$SkipWrite)));
     }