Jonlin 6 роки тому
батько
коміт
6771e09dd3

+ 6 - 0
application/admin/controller/Report.php

@@ -421,6 +421,12 @@ class Report extends Base
                     $num = $result[$key]['send_words'] / $result[$key]['receive_words'] * 100;
                     $result[$key]['answer_problem'] = round($num, 2) . '%';
                 }
+                if($result[$key]['receive_words'] == 0 && $result[$key]['send_words'] != 0){
+                    $result[$key]['answer_problem'] = '100%';
+                }
+                if($result[$key]['receive_words'] == 0 && $result[$key]['send_words'] == 0){
+                    $result[$key]['answer_problem'] = '0%';
+                }
                 //平均会话时长
                 $result[$key]['conversation'] = round(db('service_log a')->join('alarm b', 'a.servicelog_id=b.servicelog_id')->whereBetween('a.start_time', [$start, $end])->where('a.kf_id', $vo['id'])->avg('b.alarm_cvtOvertime'));
                 if ($result[$key]['conversation'] >= 60) {

+ 1 - 1
application/service/controller/Services.php

@@ -95,7 +95,7 @@ class Services extends Base
 //            if(!empty($username)){
 //                return json(['code' => -1, 'data' => '', 'msg' => '该客服已经存在']);
 //            }
-            
+
             // 更新客服信息
             $param = [
                 'user_name' => $user_name,