GetController.class.php
885 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<?php
/**
* 【下载中心-后台】获取未读数据
* @author: heyuelong
* @email: 271608475@qq.com
* @date : 2018年4月18日11:12:18
* @version $Id$
*/
namespace Apicp\Controller\Down;
use Common\Common\ExportDownload;
use Common\Common\Helper;
use Common\Service\DownloadService;
class GetController extends \Apicp\Controller\AbstractController
{
public function Index_post()
{
// 实例化DownLoadService
$service = new DownloadService();
// 组装查询条件
$conds = [
'ea_id' => $this->_login->user['eaId'],
'read' => Helper::UN_READ,
'file_status'=>ExportDownload::FILE_STATUS_TRUE
];
// 获取记录总数
$total = $service->count_by_conds($conds);
$this->_result = [
'total' => intval($total),
];
return true;
}
}