Browse Source

待处理数量

lizhen_gitee 2 weeks ago
parent
commit
6dfe6852f3
1 changed files with 19 additions and 0 deletions
  1. 19 0
      application/company/controller/Maintain.php

+ 19 - 0
application/company/controller/Maintain.php

@@ -15,6 +15,25 @@ class Maintain extends Apic
 
     protected $table = 'maintain';
 
+    //待处理数量
+    public function count(){
+        $map = [
+            'company_id' => $this->auth->company_id,
+            'status'     => 0,
+        ];
+        if($this->auth->company_id == 1){
+            $map = [
+                'status'     => 0,
+                'liuzhuan_status'     => 1,
+            ];
+        }
+
+        $count = Db::name($this->table)
+            ->where($map)->count();
+
+        $this->success(1,$count);
+    }
+
     //待审核  0
     //报价评估 20,22
     //报价审核 30