作者 lyh

gx

@@ -20,7 +20,6 @@ class Product extends Base @@ -20,7 +20,6 @@ class Product extends Base
20 const STATUS_ON = 1; 20 const STATUS_ON = 1;
21 public static function getNumByProjectId($project_id){ 21 public static function getNumByProjectId($project_id){
22 ProjectServer::useProject($project_id); 22 ProjectServer::useProject($project_id);
23 - DB::connection('custom_mysql');  
24 - return self::where('project_id', $project_id)->where('status', self::STATUS_ON)->count(); 23 + return DB::connection('custom_mysql')->where('project_id', $project_id)->where('status', self::STATUS_ON)->count();
25 } 24 }
26 } 25 }