正在显示
1 个修改的文件
包含
1 行增加
和
1 行删除
| @@ -46,7 +46,6 @@ class MonthCountLogic extends BaseLogic | @@ -46,7 +46,6 @@ class MonthCountLogic extends BaseLogic | ||
| 46 | $startTime = Carbon::now()->startOfMonth()->toDateString(); | 46 | $startTime = Carbon::now()->startOfMonth()->toDateString(); |
| 47 | $endTime = date('Y-m-d',time()); | 47 | $endTime = date('Y-m-d',time()); |
| 48 | $arr = []; | 48 | $arr = []; |
| 49 | - | ||
| 50 | ProjectServer::useProject($this->user['project_id']); | 49 | ProjectServer::useProject($this->user['project_id']); |
| 51 | $arr = $this->inquiryCount($arr,$startTime,$endTime,$this->user['domain']); | 50 | $arr = $this->inquiryCount($arr,$startTime,$endTime,$this->user['domain']); |
| 52 | $arr = $this->flowCount($arr,$startTime,$endTime,$this->user['project_id']); | 51 | $arr = $this->flowCount($arr,$startTime,$endTime,$this->user['project_id']); |
| @@ -114,6 +113,7 @@ class MonthCountLogic extends BaseLogic | @@ -114,6 +113,7 @@ class MonthCountLogic extends BaseLogic | ||
| 114 | ->where(['project_id'=>$project_id]) | 113 | ->where(['project_id'=>$project_id]) |
| 115 | ->whereBetween('date', [$startTime,$endTime]) | 114 | ->whereBetween('date', [$startTime,$endTime]) |
| 116 | ->select(DB::raw('SUM(pv_num) as pv_num'), DB::raw('SUM(ip_num) as ip_num')) | 115 | ->select(DB::raw('SUM(pv_num) as pv_num'), DB::raw('SUM(ip_num) as ip_num')) |
| 116 | + ->orderBy('id','desc') | ||
| 117 | ->first(); | 117 | ->first(); |
| 118 | $arr['pv'] = $pv_ip->pv_num; | 118 | $arr['pv'] = $pv_ip->pv_num; |
| 119 | $arr['ip'] = $pv_ip->ip_num; | 119 | $arr['ip'] = $pv_ip->ip_num; |
-
请 注册 或 登录 后发表评论