|
...
|
...
|
@@ -135,11 +135,11 @@ class MonthProjectCount extends Command |
|
|
|
*/
|
|
|
|
public function pv_ip(&$arr,$start,$end,$project_id){
|
|
|
|
$arr['pv'] = (new VisitItem())->where(['project_id'=>$project_id])
|
|
|
|
->where('date','>=',$start.' 00:00:00')
|
|
|
|
->where('date','<=',$end.' 23:59:59')->count();
|
|
|
|
->where('updated_date','>=',$start.' 00:00:00')
|
|
|
|
->where('updated_date','<=',$end.' 23:59:59')->count();
|
|
|
|
$arr['ip'] = (new Visit())->where(['project_id'=>$project_id])
|
|
|
|
->where('date','>=',$start.' 00:00:00')
|
|
|
|
->where('date','<=',$end.' 23:59:59')->count();
|
|
|
|
->where('updated_date','>=',$start.' 00:00:00')
|
|
|
|
->where('updated_date','<=',$end.' 23:59:59')->count();
|
|
|
|
if($arr['ip'] != 0){
|
|
|
|
$arr['rate'] = round(($arr['month_total'] / $arr['ip']) * 10,2);
|
|
|
|
}
|
...
|
...
|
|