|
...
|
...
|
@@ -48,6 +48,7 @@ class CountLogic extends BaseLogic |
|
|
|
'company'=>$this->project['company'],
|
|
|
|
'scheme'=>$this->project['deploy_build']['plan'],
|
|
|
|
'service_duration'=>$this->project['deploy_build']['service_duration'],
|
|
|
|
'domain'=>$this->project['deploy_build']['test_domain']
|
|
|
|
];
|
|
|
|
return $this->success($data);
|
|
|
|
}
|
|
...
|
...
|
@@ -59,8 +60,8 @@ class CountLogic extends BaseLogic |
|
|
|
* @time :2023/5/24 13:33
|
|
|
|
*/
|
|
|
|
public function total_count($inquiry_num = ''){
|
|
|
|
$pv = DB::table('gl_customer_visit_item')->where(['domain'=>$this->project['deploy_build']['test_domain']])->count();
|
|
|
|
$ip = DB::table('gl_customer_visit')->where(['domain'=>$this->project['deploy_build']['test_domain']])->count();
|
|
|
|
$pv = DB::table('gl_customer_visit_item')->where(['domain'=>$this->user['domain']])->count();
|
|
|
|
$ip = DB::table('gl_customer_visit')->where(['domain'=>$this->user['domain']])->count();
|
|
|
|
$data = [
|
|
|
|
'total_pv'=>$pv,
|
|
|
|
'total_ip'=>$ip,
|
|
...
|
...
|
@@ -131,7 +132,7 @@ class CountLogic extends BaseLogic |
|
|
|
public function referrer_count(){
|
|
|
|
$data = DB::table('gl_customer_visit')
|
|
|
|
->select('referrer_url', DB::raw('COUNT(*) as count'))
|
|
|
|
->groupBy('referrer_url')->where(['domain'=>'http://lxl.petuu.shop/'])
|
|
|
|
->groupBy('referrer_url')->where(['domain'=>$this->user['domain']])
|
|
|
|
->orderByDesc('count')->limit(8)->get()->toArray();
|
|
|
|
$total = DB::table('gl_customer_visit')->count();
|
|
|
|
if(!empty($data)){
|
|
...
|
...
|
@@ -152,7 +153,7 @@ class CountLogic extends BaseLogic |
|
|
|
public function access_country_count(){
|
|
|
|
$data = DB::table('gl_customer_visit')
|
|
|
|
->select('country',DB::raw('COUNT(*) as ip'),DB::raw('SUM(depth) as pv'))
|
|
|
|
->groupBy('country')->where(['domain'=>'http://lxl.petuu.shop/'])
|
|
|
|
->groupBy('country')->where(['domain'=>$this->user['domain']])
|
|
|
|
->orderBy('ip','desc')->limit(10)->get()->toArray();
|
|
|
|
if(!empty($data)){
|
|
|
|
$data = object_to_array($data);
|
...
|
...
|
|