From: hickert Date: Thu, 14 Oct 2010 08:49:13 +0000 (+0000) Subject: Updated folder handling for user-groupware accounts. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=121bf49063ebf07cdac97de201c4236dd3e82260;p=gosa.git Updated folder handling for user-groupware accounts. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20042 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/groupware/personal/groupware/FolderWidget/class_FolderWidget.inc b/gosa-plugins/groupware/personal/groupware/FolderWidget/class_FolderWidget.inc index fc409dd86..5b4d965ea 100644 --- a/gosa-plugins/groupware/personal/groupware/FolderWidget/class_FolderWidget.inc +++ b/gosa-plugins/groupware/personal/groupware/FolderWidget/class_FolderWidget.inc @@ -118,7 +118,7 @@ class FolderWidget extends plugin $this->buildRecursiveList($arr, $this->pathSeparator); // Ensure that we've at least the base folder set - if(!isset($this->folderList[$this->accountPrefix])){ + if(!isset($this->folderList['linear'][$this->accountPrefix])){ $this->addPath($this->accountPrefix, preg_replace("/^.*\//","", $this->accountPrefix)); trigger_error(sprintf("You reuquire at least a folder named '%s'! This time it was added automatically.", diff --git a/gosa-plugins/groupware/personal/groupware/class_Groupware.inc b/gosa-plugins/groupware/personal/groupware/class_Groupware.inc index d40449a9b..56422ba67 100644 --- a/gosa-plugins/groupware/personal/groupware/class_Groupware.inc +++ b/gosa-plugins/groupware/personal/groupware/class_Groupware.inc @@ -303,7 +303,12 @@ class Groupware extends plugin } } if(isset($_POST['configureFolder'])){ - $this->FolderWidget = new FolderWidget($this->config,$this->mailFolder, $this->folderPrefix); + $folders = $this->mailFolder; + if(!isset($folders[$this->folderPrefix])){ + $folders[$this->folderPrefix] = array('name' => $this->uid,'status' => 'added','acls' => array()); + } + + $this->FolderWidget = new FolderWidget($this->config,$folders, $this->folderPrefix); $this->FolderWidget->setPermissions(GroupwareDefinitions::getPermissions()); $this->FolderWidget->acl_base = $this->acl_base; $this->FolderWidget->acl_category = $this->acl_category;