wugg 3 years ago
parent
commit
2c1a15cd5e
2 changed files with 12 additions and 11 deletions
  1. 1 0
      app/admin/controller/Resign.php
  2. 11 11
      app/admin/controller/Supplier.php

+ 1 - 0
app/admin/controller/Resign.php

@@ -7,4 +7,5 @@ use app\BaseController;
 class Resign extends \app\BaseController
 {
 
+
 }

+ 11 - 11
app/admin/controller/Supplier.php

@@ -12,27 +12,27 @@ public $post = "";
 public function __construct(App $app){
     parent::__construct($app);
     $this->post = $this->request->post();
-    $token = isset($this->post['token']) ? trim($this->post['token']) : "";
-    if($token==""){
-        return error_show(101,'token不能为空');
-    }
-    $effetc = VerifyTokens($token);
-    if(!empty($effetc) && $effetc['code']!=0){
-        return error_show($effetc['code'],$effetc['message']);
-    }
+//    $token = isset($this->post['token']) ? trim($this->post['token']) : "";
+//    if($token==""){
+//        return error_show(101,'token不能为空');
+//    }
+//    $effetc = VerifyTokens($token);
+//    if(!empty($effetc) && $effetc['code']!=0){
+//        return error_show($effetc['code'],$effetc['message']);
+//    }
 }
 /*列表*/
 public function list(){
     $page = isset($this->post['page']) && $this->post['page'] != "" ? intval($this->post['page']) : 1;
     $size = isset($this->post['size']) && $this->post['size'] != "" ? intval($this->post['size']) : 10;
-    $where = ['is_del'=>0];
+    $where = [['is_del',"=",0]];
     $name = isset($this->post['name']) && $this->post['name'] !== "" ? trim($this->post['name']) : "";
     if ($name !== "") {
-        $where['name'] = ["like", "%$name%"];
+        $where[] = ["name","like", "%{$name}%"];
     }
     $code = isset($this->post['code']) && $this->post['code'] !== "" ? trim($this->post['code']) : "";
     if ($code !== "") {
-        $where['code'] = $code;
+        $where[] = ["code","=", $code];
     }
 //    $source = isset($this->post['source']) && $this->post['source'] !== "" ? trim($this->post['source']) : "";
 //    if ($source !== "") {