From e4a8af42756612906969a27d407a9e494e5e08e9 Mon Sep 17 00:00:00 2001 From: luofei <604446095@qq.com> Date: Mon, 29 May 2023 14:09:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BE=9B=E8=B4=A7=E9=87=87=E8=B4=AD=E4=B8=8D?= =?UTF-8?q?=E5=B1=95=E7=A4=BA=E6=9C=AA=E4=B8=8A=E6=9E=B6=E5=95=86=E5=93=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/common/model/store/product/Product.php | 3 +++ app/common/model/system/merchant/Merchant.php | 1 + 2 files changed, 4 insertions(+) diff --git a/app/common/model/store/product/Product.php b/app/common/model/store/product/Product.php index d3dbd9e3..21e9b6e4 100644 --- a/app/common/model/store/product/Product.php +++ b/app/common/model/store/product/Product.php @@ -37,6 +37,9 @@ class Product extends BaseModel protected $deleteTime = 'is_del'; protected $defaultSoftDelete = 0; + + const IS_SHOW = 1; //上架 + const IS_NOT_SHOW = 0; //下架 /** * @Author:Qinii * @Date: 2020/5/8 diff --git a/app/common/model/system/merchant/Merchant.php b/app/common/model/system/merchant/Merchant.php index f3d83c9c..fdaf5872 100644 --- a/app/common/model/system/merchant/Merchant.php +++ b/app/common/model/system/merchant/Merchant.php @@ -122,6 +122,7 @@ class Merchant extends BaseModel { $list = Product::where('mer_id', $this['mer_id']) ->where((new ProductDao())->productTypeShow(98)) + ->where('is_show', Product::IS_SHOW) ->field('mer_id,product_id,product_type,store_name,image,price,is_show,status,is_gift_bag,is_good,cate_id') ->order('sort DESC, create_time DESC') ->limit(10)