diff --git a/app/crm/controller/CustomerController.php b/app/crm/controller/CustomerController.php index b6f7141..998c721 100644 --- a/app/crm/controller/CustomerController.php +++ b/app/crm/controller/CustomerController.php @@ -365,7 +365,7 @@ class CustomerController extends BaseController $created_at = strtotime($created_at); $day = ceil((time() - $created_at + 1) / 60 / 60 / 24); $where[] = ['user_id', '=', $userId]; - $where[] = ['corp_abbr', '=', $request->basic_data['corp_abbr']]; + //$where[] = ['corp_abbr', '=', $request->basic_data['corp_abbr']]; $start = strtotime($created . '-01'); $year = date('Y', $start); $month = date('n', $start); //获取月份 @@ -373,10 +373,7 @@ class CustomerController extends BaseController $where[] = ['created_at', '>=', $start]; $where[] = ['created_at', '<', $end]; $customer = Customer::where($where)->count(); - $builder = Customer::where($where)->count(); - $sql = str_replace(['?'], ['\'%s\''], $builder->toSql()); - $fullSql = vsprintf($sql, $builder->getBindings()); - var_dump($fullSql); + //初步接触 $whereGrade = $where; $whereGrade[] = ['grade', '<=', 2];