From 4b5122f1ac239cde50650106617717ac4ed3db2b Mon Sep 17 00:00:00 2001 From: mkm <727897186@qq.com> Date: Wed, 12 Jun 2024 10:58:28 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=A2=9E=E5=8A=A0=E5=95=86=E5=93=81?= =?UTF-8?q?=E7=8A=B6=E6=80=81=E5=92=8C=E5=BA=93=E5=AD=98=E6=9F=A5=E8=AF=A2?= =?UTF-8?q?=E6=9D=A1=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/api/lists/product/ProductLists.php | 2 ++ .../system_store_storage/SystemStoreStorageController.php | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/api/lists/product/ProductLists.php b/app/api/lists/product/ProductLists.php index 02ff4c402..c284d2073 100644 --- a/app/api/lists/product/ProductLists.php +++ b/app/api/lists/product/ProductLists.php @@ -119,6 +119,8 @@ class ProductLists extends BaseAdminDataLists implements ListsSearchInterface }else{ $where[]=['store_id','=',2]; } + $this->searchWhere[]=['status','=',1]; + $this->searchWhere[]=['stock','>',0]; $M_store_id=$this->request->__get('store_id'); if($M_store_id){ $where[]=['store_id','=',$M_store_id]; diff --git a/app/store/controller/system_store_storage/SystemStoreStorageController.php b/app/store/controller/system_store_storage/SystemStoreStorageController.php index eaaf67ae3..11389cf74 100644 --- a/app/store/controller/system_store_storage/SystemStoreStorageController.php +++ b/app/store/controller/system_store_storage/SystemStoreStorageController.php @@ -38,7 +38,7 @@ class SystemStoreStorageController extends BaseAdminController if($id==0){ return $this->fail('参数错误'); } - $res=SystemStoreStorage::where(['id' => $id,'store_id'=>$this->adminInfo['store_id']])->update(['status'=>1,'staff_id'=>$this->adminId]); + $res=SystemStoreStorage::where(['id' => $id,'store_id'=>$this->adminInfo['store_id']])->update(['status'=>1,'staff_id'=>$this->adminId,'mark'=>'入库时间:'.date('Y-m-d H:i:s',time())]); if($res){ $find=SystemStoreStorage::where(['id' => $id])->find(); StoreBranchProduct::where(['product_id'=>$find['product_id'],'store_id'=>$find['store_id']])->inc('stock',$find['nums'])->update();