wugg 3 years ago
parent
commit
0a5678de55
2 changed files with 10 additions and 1 deletions
  1. 1 1
      app/admin/controller/Purch.php
  2. 9 0
      app/admin/controller/Resign.php

+ 1 - 1
app/admin/controller/Purch.php

@@ -72,7 +72,7 @@ class Purch extends \app\BaseController
         $count=Db::name("purchease_order")->where($where)->count();
         $total = ceil($count/$size);
         $page = $page >= $total ? $total : $page;
-        $list = Db::name("purchease_order")->where($where)->page($page,$size)->select();
+        $list = Db::name("purchease_order")->where($where)->page($page,$size)->order("addtime desc")->select();
         $data=[];
         foreach ($list as $value){
             $value['wsm_name']="";

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

@@ -50,6 +50,15 @@ class Resign extends BaseController
         if($good_name!=""){
             $where['good_name'] = Db::raw(" like %{$good_name}%");
         }
+
+        $apply_name = isset($this->post['apply_name']) && $this->post['apply_name']!="" ? trim($this->post['apply_name']):"";
+        if($apply_name!=""){
+            $where['apply_name'] =Db::Raw("like '%{$apply_name}%'");
+        }
+        $status = isset($this->post['status']) && $this->post['status']!=="" ? intval($this->post['status']):"";
+        if($status!==""){
+            $where['status'] = $status;
+        }
         $count=Db::name("purchease")->where($where)->count();
         $total = ceil($count/$size);
         $page = $page >= $total ? $total : $page;