From a7d540841ccd61f3fb2a8298d1e7539cdc0c4ef3 Mon Sep 17 00:00:00 2001 From: yaooo <272523191@qq.com> Date: Mon, 14 Aug 2023 09:42:19 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E4=BF=AE=E5=A4=8D=E5=8F=AF?= =?UTF-8?q?=E8=BD=AC=E5=94=AE=E5=95=86=E5=93=81=E5=88=97=E8=A1=A8=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/common/repositories/community/CommunityRepository.php | 1 - app/common/repositories/store/product/ProductRepository.php | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/common/repositories/community/CommunityRepository.php b/app/common/repositories/community/CommunityRepository.php index ee931ed2..449a9f71 100644 --- a/app/common/repositories/community/CommunityRepository.php +++ b/app/common/repositories/community/CommunityRepository.php @@ -99,7 +99,6 @@ class CommunityRepository extends BaseRepository $config = systemConfig("community_app_switch"); if (!isset($where['is_type']) && $config) $where['is_type'] = is_array($config) ? implode(',', $config) : $config; $where['is_del'] = 0; - // print_r($where); $query = $this->dao->search($where)->when(in_array(self::COMMUNITY_TYPE_RESALE, explode(',', $where['is_type'])), function ($query) { $query->where('is_sale', 0); })->order('start DESC,Community.create_time DESC,community_id DESC'); diff --git a/app/common/repositories/store/product/ProductRepository.php b/app/common/repositories/store/product/ProductRepository.php index 4db61fc0..2ec4d5cb 100644 --- a/app/common/repositories/store/product/ProductRepository.php +++ b/app/common/repositories/store/product/ProductRepository.php @@ -2445,6 +2445,8 @@ class ProductRepository extends BaseRepository { $merId = Db::name('store_service')->where('uid', $where['uid'])->where('status', 1)->value('mer_id', 0); unset($where['uid']); + $where['status'] = 1; + $where['is_show'] = 1; $query = $this->dao->search($merId, $where)->with(['merCateId.category', 'storeCategory', 'brand', 'attrValue']); $count = $query->count(); $data = $query->page($page, $limit)->setOption('field', [])->field($this->filed)->select();