mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-27 09:09:04 +01:00
Mail tree phase2 W.I.P.: Set the initial counters for opened folders
This commit is contained in:
parent
18b9ff23f5
commit
1d264a8b64
@ -239,7 +239,7 @@ class mail_tree
|
||||
}
|
||||
|
||||
//List of folders
|
||||
$foldersList = $this->ui->mail_bo->getFolderArrays(null, true, $_allInOneGo?0:2,$_subscribedOnly);
|
||||
$foldersList = $this->ui->mail_bo->getFolderArrays(null, true, $_allInOneGo?0:2,$_subscribedOnly, true);
|
||||
foreach ($foldersList as &$folder)
|
||||
{
|
||||
$path = $parent = $parts = explode($folder['delimiter'], $folder['MAILBOX']);
|
||||
@ -413,6 +413,17 @@ class mail_tree
|
||||
$data[tree::IMAGE_FOLDER_OPEN] = self::$leafImages['folderOpen'];
|
||||
$data[tree::IMAGE_FOLDER_CLOSED] = self::$leafImages['folderClose'];
|
||||
}
|
||||
|
||||
// Contains unseen mails for the folder
|
||||
$unseen = $data['folderarray']['counter']['UNSEEN'];
|
||||
|
||||
// if there's unseen mails then change the label and style
|
||||
// accordingly to indicate useen mails
|
||||
if ($unseen > 0)
|
||||
{
|
||||
$data[tree::LABEL] = $data[tree::LABEL].'('.$unseen.')';
|
||||
$data['style'] = 'font-weight: bold';
|
||||
}
|
||||
}
|
||||
//Remove extra data from tree structure
|
||||
unset($data['folderarray']);
|
||||
|
Loading…
Reference in New Issue
Block a user