...
|
...
|
@@ -296,14 +296,8 @@ class MailListV2 extends Base { |
|
|
$where['is_hots'] = 0;
|
|
|
$lajiCount = db()->cache($this->cache)->count($sql . dbWhere($where));
|
|
|
}
|
|
|
// 星标
|
|
|
if(in_array('flagged',$show_count_filed)) {
|
|
|
$where['flagged'] = 1;
|
|
|
unset($where['folder_id']);
|
|
|
$flaggedCount = db()->cache($this->cache)->count($sql . dbWhere($where));
|
|
|
}
|
|
|
// 收件箱
|
|
|
if(in_array('inbox',$show_count_filed)) {
|
|
|
|
|
|
// 收件箱
|
|
|
$where['folder_id'] = $this->getFolderId('收件箱');
|
|
|
$where['is_hots'] = 0;
|
|
|
|
...
|
...
|
@@ -333,7 +327,7 @@ class MailListV2 extends Base { |
|
|
|
|
|
|
|
|
$shouCount = db()->cache($this->cache)->count($sql . dbWhere($where));
|
|
|
}
|
|
|
|
|
|
// 未读
|
|
|
if(in_array('unseen',$show_count_filed)) {
|
|
|
$where['seen'] = 0;
|
...
|
...
|
@@ -341,6 +335,12 @@ class MailListV2 extends Base { |
|
|
$seenCount = db()->cache($this->cache)->count($sql . dbWhere($where));
|
|
|
unset($where['seen']);
|
|
|
}
|
|
|
// 星标
|
|
|
if(in_array('flagged',$show_count_filed)) {
|
|
|
$where['flagged'] = 1;
|
|
|
unset($where['folder_id']);
|
|
|
$flaggedCount = db()->cache($this->cache)->count($sql . dbWhere($where));
|
|
|
}
|
|
|
|
|
|
$data = [];
|
|
|
if(isset($shouCount)) $data['inbox'] = $shouCount;
|
...
|
...
|
|