增加月开工率

This commit is contained in:
lcc
2025-01-08 15:59:19 +08:00
parent d86c7ba50a
commit c596574bb2
+6 -6
View File
@@ -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));