summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 6a929d3)
raw | patch | inline | side by side (parent: 6a929d3)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 18 Nov 2010 14:08:45 +0000 (14:08 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 18 Nov 2010 14:08:45 +0000 (14:08 +0000) |
-This increases the speed in which a user can be openend.
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20271 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20271 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/groupware/personal/groupware/class_Groupware.inc | patch | blob | history | |
gosa-plugins/groupware/personal/groupware/class_GroupwareDao.inc | patch | blob | history |
diff --git a/gosa-plugins/groupware/personal/groupware/class_Groupware.inc b/gosa-plugins/groupware/personal/groupware/class_Groupware.inc
index f61a6b4b5898a8cf6546b2ce2aed50a9b42d0466..0db7a70f0d2c6522e6a0213f13dfb670155bb261 100644 (file)
var $mailAddress = "";
var $mailLocation = "";
- var $mailFolder = array();
+ var $mailFolder = NULL;
var $quotaUsage = 0;
var $quotaSize = 0;
var $alternateAddresses = array();
$this->FolderWidget = NULL;
}
}
+
+ // Act on requests to edit mailFolder entries.
if(isset($_POST['configureFolder'])){
+
+ // Load mail folder entries on demand, this will increase the account
+ // instantiation a lot.
+ if($this->mailFolder === NULL){
+ $this->mailFolder = $this->GroupwareDao->getListOfMailFolders();
+ }
+
$folders = $this->mailFolder;
if(!isset($folders[$this->folderPrefix])){
$folders[$this->folderPrefix] = array('name' => $this->uid,'status' => 'added','acls' => array());
}
// Save account folders
- if($this->isFeatureEnabled("mailFolder") && $this->hasFeaturebeenChanged("mailFolder")){
+ if($this->mailFolder !== NULL && $this->isFeatureEnabled("mailFolder") && $this->hasFeaturebeenChanged("mailFolder")){
$res = $this->saveFoldersAndAcls($this->uid, $this->mailFolder);
if($res === NULL){
$message = _("Saving mail folder failed!");
diff --git a/gosa-plugins/groupware/personal/groupware/class_GroupwareDao.inc b/gosa-plugins/groupware/personal/groupware/class_GroupwareDao.inc
index 3ce6f8a39407cdad2baab79be1db4cc98c1fe891..635843d499604bd0fb8db2cea8d0998435a31dfb 100644 (file)
$resultArr["mailLimitSendValue"] = $comp["mailLimits"]["send"];
$resultArr["vacationMessage"] = $comp["vacation"]["message"];
-
- //Folder Stuff
+
+ return $resultArr;
+ }
+
+
+ /* \brief Returns a list of mail folders for the current folderPrefix.
+ * Acl entries will be returned the GOsa-usable way.
+ * @return Array A list of mail folder entries.
+ */
+ function getListOfMailFolders()
+ {
$prefix = $this->groupwarePluginRef->folderPrefix;
$compFolders = $this->get("folderListWithMembers", array($prefix));
- //ausgelagerte Funktion..
- $resultArr["mailFolder"] = $this->translateGwAclsToGosaAcls($compFolders);
-
- return $resultArr;
-
+ return($this->translateGwAclsToGosaAcls($compFolders));
}
+
private function getComprehensiverUserSeparate($uid){
if($this->groupwarePluginRef->isFeatureEnabled("primaryMail")){