From c0078222f505c5527eff5f72db94f83ff280fa1a Mon Sep 17 00:00:00 2001 From: wangw <1594593906@qq.com> Date: Fri, 23 Aug 2024 10:11:06 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=82=E6=95=B0=20undefined=E7=9A=84?= =?UTF-8?q?=E6=83=85=E5=86=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/cashierservice/controller/ProductController.java | 2 +- .../system/cashierservice/dao/TbProductMapper.java | 2 +- .../system/cashierservice/service/ProductService.java | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/chaozhanggui/system/cashierservice/controller/ProductController.java b/src/main/java/com/chaozhanggui/system/cashierservice/controller/ProductController.java index a52d21c..ba8aec0 100644 --- a/src/main/java/com/chaozhanggui/system/cashierservice/controller/ProductController.java +++ b/src/main/java/com/chaozhanggui/system/cashierservice/controller/ProductController.java @@ -83,7 +83,7 @@ public class ProductController { @RequestParam("shopId") String shopId, @RequestParam("productId") String productId, @RequestParam("spec_tag") String spec_tag, - @RequestParam("isVip") Integer isVip + @RequestParam("isVip") String isVip ) { return productService.queryProductSku(code,shopId, productId, spec_tag,isVip); } diff --git a/src/main/java/com/chaozhanggui/system/cashierservice/dao/TbProductMapper.java b/src/main/java/com/chaozhanggui/system/cashierservice/dao/TbProductMapper.java index dc3920a..9e33d9a 100644 --- a/src/main/java/com/chaozhanggui/system/cashierservice/dao/TbProductMapper.java +++ b/src/main/java/com/chaozhanggui/system/cashierservice/dao/TbProductMapper.java @@ -26,7 +26,7 @@ public interface TbProductMapper { List selectByIds(@Param("list") List ids); Integer selectByQcode(@Param("code") String code,@Param("productId") Integer productId,@Param("shopId") String shopId); - Integer selectByCodeAndSkuId(@Param("code") String code,@Param("skuId") Integer skuId,@Param("shopId") String shopId,@Param("isVip") Integer isVip); + Integer selectByCodeAndSkuId(@Param("code") String code,@Param("skuId") Integer skuId,@Param("shopId") String shopId,@Param("isVip") String isVip); Integer selectByNewQcode(@Param("code") String code,@Param("productId") Integer productId,@Param("shopId") String shopId,@Param("list") List list); List selGroups(@Param("proName") String proName,@Param("type") String type, diff --git a/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java b/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java index a1934bd..9ef636d 100644 --- a/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java +++ b/src/main/java/com/chaozhanggui/system/cashierservice/service/ProductService.java @@ -464,8 +464,8 @@ public class ProductService { } - public Result queryProductSku(String code, String shopId, String productId, String spec_tag,Integer isVip) { - if (ObjectUtil.isEmpty(shopId) || ObjectUtil.isEmpty(productId) || ObjectUtil.isEmpty(isVip)) { + public Result queryProductSku(String code, String shopId, String productId, String spec_tag,String isVip) { + if (ObjectUtil.isEmpty(shopId) || ObjectUtil.isEmpty(productId) || StringUtils.isEmpty(isVip)|| isVip.equals("undefined") ) { return Result.fail("参数错误"); } TbProductSkuWithBLOBs tbProductSkuWithBLOBs = tbProductSkuMapper.selectByShopIdAndProductIdAndSpec(shopId, productId, spec_tag);