From 75e153031bac493c94c942290541528d0ded92af Mon Sep 17 00:00:00 2001 From: lewis <604446095@qq.com> Date: Wed, 22 Jan 2025 17:49:48 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E9=87=87=E8=B4=AD=E5=95=86?= =?UTF-8?q?=E5=93=81=E6=9F=A5=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../BeforehandOrderCartInfoController.php | 3 +++ .../PurchaseProductOfferLists.php | 12 ++++++++++++ 2 files changed, 15 insertions(+) diff --git a/app/admin/controller/beforehand_order_cart_info/BeforehandOrderCartInfoController.php b/app/admin/controller/beforehand_order_cart_info/BeforehandOrderCartInfoController.php index 41e0ecc6..ea170896 100644 --- a/app/admin/controller/beforehand_order_cart_info/BeforehandOrderCartInfoController.php +++ b/app/admin/controller/beforehand_order_cart_info/BeforehandOrderCartInfoController.php @@ -105,6 +105,9 @@ class BeforehandOrderCartInfoController extends BaseAdminController * @notes 一键入库 */ public function one_click_storage(){ + if (time() > 1737561600) { + return $this->fail('不允许一键入库'); + } $params=$this->request->post(); $params['admin_id']=$this->adminId; BeforehandOrderCartInfoLogic::oneClickStorage($params); diff --git a/app/admin/lists/purchase_product_offer/PurchaseProductOfferLists.php b/app/admin/lists/purchase_product_offer/PurchaseProductOfferLists.php index 51529640..c0498324 100644 --- a/app/admin/lists/purchase_product_offer/PurchaseProductOfferLists.php +++ b/app/admin/lists/purchase_product_offer/PurchaseProductOfferLists.php @@ -65,6 +65,18 @@ class PurchaseProductOfferLists extends BaseAdminDataLists implements ListsSearc $this->searchWhere[]=['order_id','in',$ids]; } } + if(!empty($this->params['order_sn'])){ + $orderIds = BeforehandOrder::where('order_id','like','%'.$this->params['order_sn'].'%')->column('id'); + $this->searchWhere[]=['order_id','in',$orderIds]; + } + if(!empty($this->params['product_name'])){ + $productIds = StoreProduct::where('store_name','like','%'.$this->params['product_name'].'%')->column('id'); + $this->searchWhere[]=['product_id','in',$productIds]; + } + if(!empty($this->params['order_sort_list'])){ + $this->searchWhere[]=['is_storage','=',0]; + $this->searchWhere[]=['total_price','>',0]; + } return PurchaseProductOffer::where($this->searchWhere) ->limit($this->limitOffset, $this->limitLength) ->order(['id' => 'desc'])