Bläddra i källkod

摄像头统计接口修改

任敬轩 2 år sedan
förälder
incheckning
ebb1c427a0
1 ändrade filer med 2 tillägg och 2 borttagningar
  1. 2 2
      Modules/Camera/Http/Controllers/Api/CameraApiController.php

+ 2 - 2
Modules/Camera/Http/Controllers/Api/CameraApiController.php

@@ -106,8 +106,8 @@ class CameraApiController extends BaseController
                 }
             }
 
-            $total = DB::table('camera_list')->whereIn('mine_id',$mine_use)->where('deleted_at',null)->count();
-            $total_online = DB::table('camera_list')->whereIn('mine_id',$mine_use)->where('camera_status',1)->where('deleted_at',null)->count();
+            $total = DB::table('camera_list')->whereIn('mine_id',$mine_use)->where('is_show',1)->where('deleted_at',null)->count();
+            $total_online = DB::table('camera_list')->whereIn('mine_id',$mine_use)->where('is_show',1)->where('camera_status',1)->where('deleted_at',null)->count();
 
             if($total == 0){
                 $rate = "0%";