From c596574bb2aed1c5f94ec5a0cdae2e1345639031 Mon Sep 17 00:00:00 2001 From: lcc <805383944@qq.com> Date: Wed, 8 Jan 2025 15:59:19 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=9C=88=E5=BC=80=E5=B7=A5?= =?UTF-8?q?=E7=8E=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/controllers/plan/Report.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/api/controllers/plan/Report.php b/api/controllers/plan/Report.php index e3d56fc2..f4441465 100644 --- a/api/controllers/plan/Report.php +++ b/api/controllers/plan/Report.php @@ -97,16 +97,16 @@ class Report extends HD_Controller //今日线索逾期数 $cust_delay = $this->receiver_score_log_model->count(array('day' => $day, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 3, 'target_id >' => 0)); //本月开工 - $works_month = $this->receiver_score_log_model->count(array('MONTH(day)' => $month, 'biz_id' => $v['id'], 'type' => 0, 'sub_type' => 0, 'score >' => 0), 'biz_id,uid'); + $works_month = $this->receiver_score_log_model->count(array("DATE_FORMAT(`day`, '%Y-%m')" => $month, 'biz_id' => $v['id'], 'type' => 0, 'sub_type' => 0, 'score >' => 0), 'biz_id,uid'); //本月线索逾期数 - $cust_delay_month = $this->receiver_score_log_model->count(array('MONTH(day)' => $month, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 3, 'target_id >' => 0)); + $cust_delay_month = $this->receiver_score_log_model->count(array("DATE_FORMAT(`day`, '%Y-%m')" => $month, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 3, 'target_id >' => 0)); //今日订单未达T+1 $order_wrong = $this->receiver_score_log_model->count(array('day' => $day, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 2, 'target_id >' => 0), 'target_id'); //本月订单未达T+1 - $order_wrong_month = $this->receiver_score_log_model->count(array('MONTH(day)' => $month, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 2, 'target_id >' => 0), 'target_id'); + $order_wrong_month = $this->receiver_score_log_model->count(array("DATE_FORMAT(`day`, '%Y-%m')" => $month, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 2, 'target_id >' => 0), 'target_id'); //今日开票早与订单时间数 $order_early = $this->receiver_score_log_model->count(array('day' => $day, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 1, 'target_id >' => 0), 'target_id'); @@ -115,16 +115,16 @@ class Report extends HD_Controller $cust_push = $this->receiver_score_log_model->count(array('day' => $day, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 4, 'target_id >' => 0), 'target_id'); //本月未及时分配数 - $cust_push_month = $this->receiver_score_log_model->count(array('MONTH(day)' => $month, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 4, 'target_id >' => 0), 'target_id'); + $cust_push_month = $this->receiver_score_log_model->count(array("DATE_FORMAT(`day`, '%Y-%m')" => $month, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 4, 'target_id >' => 0), 'target_id'); //今日战败申请未处理数 $cust_defeat = $this->receiver_score_log_model->count(array('day' => $day, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 5, 'target_id >' => 0), 'target_id'); //本月战败申请未处理数 - $cust_defeat_moth = $this->receiver_score_log_model->count(array('MONTH(day)' => $month, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 5, 'target_id >' => 0), 'target_id'); + $cust_defeat_moth = $this->receiver_score_log_model->count(array("DATE_FORMAT(`day`, '%Y-%m')" => $month, 'biz_id' => $v['id'], 'type' => 3, 'sub_type' => 5, 'target_id >' => 0), 'target_id'); //本月交付总数 - $order_over = $this->receiver_orders_model->count(array('MONTH(over_time)' => $month, 'biz_id' => $v['id'], 'status >' => 0)); + $order_over = $this->receiver_orders_model->count(array("DATE_FORMAT(`over_time`, '%Y-%m')" => $month, 'biz_id' => $v['id'], 'status >' => 0)); //今日运营分 $score = $this->receiver_score_day_model->get(array('day' => $day, 'biz_id' => $v['id'], 'type' => 1));