作者 lyh

gx

... ... @@ -164,8 +164,8 @@ class CountLogic extends BaseLogic
$data = $customerVisitModel->select('country',DB::raw('COUNT(*) as ip'),DB::raw('SUM(depth) as pv'))
->groupBy('country')
->orderBy('ip','desc')->limit(11)->get()->toArray();
if(!empty($data)){
$result =array();
if(!empty($data)){
foreach ($data as $k => $v){
if(($this->project['is_record_china_visit'] != 1) && ($v['country'] == '中国')){
continue;
... ... @@ -175,7 +175,7 @@ class CountLogic extends BaseLogic
}
}
}
return $this->success($data);
return $this->success($result);
}
/**
... ...