From 2742da2640cf76fcf794508a384f9348b77dc189 Mon Sep 17 00:00:00 2001 From: mkm <727897186@qq.com> Date: Wed, 21 Aug 2024 10:52:41 +0800 Subject: [PATCH] =?UTF-8?q?feat(StoreOrderCartInfoTwoLists):=20=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E6=A0=B9=E6=8D=AE=E5=BA=97=E9=93=BA=E5=90=8D=E7=A7=B0?= =?UTF-8?q?=E6=90=9C=E7=B4=A2=E5=95=86=E5=93=81=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../StoreOrderCartInfoTwoLists.php | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/app/admin/lists/store_order_cart_info/StoreOrderCartInfoTwoLists.php b/app/admin/lists/store_order_cart_info/StoreOrderCartInfoTwoLists.php index 468e3ee92..8874e9358 100644 --- a/app/admin/lists/store_order_cart_info/StoreOrderCartInfoTwoLists.php +++ b/app/admin/lists/store_order_cart_info/StoreOrderCartInfoTwoLists.php @@ -23,6 +23,7 @@ use app\common\model\system_store\SystemStore; class StoreOrderCartInfoTwoLists extends BaseAdminDataLists implements ListsSearchInterface, ListsExcelInterface { + public $ids; /** * @notes 设置搜索条件 * @return \string[][] @@ -49,6 +50,16 @@ class StoreOrderCartInfoTwoLists extends BaseAdminDataLists implements ListsSear */ public function lists(): array { + if ($this->request->get('store_name')) { + $store_name = $this->request->get('store_name'); + $ids = StoreProduct::where('store_name', 'like', '%' . $store_name . '%')->column('id'); + if ($ids) { + $this->searchWhere[] = ['product_id', 'in', $ids]; + $this->ids = $ids; + } else { + return []; + } + } if ($this->request->get('start_time') == '') { $this->searchWhere[] = ['create_time', 'between', [strtotime(date('Y-m-d 00:00:00')), strtotime(date('Y-m-d 23:59:59'))]]; }