From e019118123cb0fe8184df35fe1b0d9842fafc251 Mon Sep 17 00:00:00 2001 From: shengchanzhe <179998674@qq.com> Date: Tue, 26 Dec 2023 10:26:21 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/common/repositories/store/product/ProductRepository.php | 2 +- app/controller/api/store/product/StoreProduct.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/common/repositories/store/product/ProductRepository.php b/app/common/repositories/store/product/ProductRepository.php index 1546f5e8..6f36ec4e 100644 --- a/app/common/repositories/store/product/ProductRepository.php +++ b/app/common/repositories/store/product/ProductRepository.php @@ -341,7 +341,7 @@ class ProductRepository extends BaseRepository } $ret = Spu::getInstance()->where('product_id', $id)->whereIn('product_type', [0, 98, 99])->find(); app()->make(SpuRepository::class)->update($ret->spu_id, ['mer_labels' => $data['mer_labels']]); - return true; + return false; } if (!$data['spec_type']) { $data['attr'] = []; diff --git a/app/controller/api/store/product/StoreProduct.php b/app/controller/api/store/product/StoreProduct.php index 5625a0c2..601cc19c 100644 --- a/app/controller/api/store/product/StoreProduct.php +++ b/app/controller/api/store/product/StoreProduct.php @@ -224,7 +224,7 @@ class StoreProduct extends BaseController return app('json')->fail('编辑免申商品参数错误'); } $res=$this->repository->freeTrial($id, $data,$mer_id); - if($res && $params['is_stock']==1){ + if($res && $data['is_stock']==1){ $arr=[ 'mer_id'=>$mer_id, 'uid'=>$uid,