From bb09235bf6bb89d2ef6e837b3c1a6ca7cdb743a0 Mon Sep 17 00:00:00 2001 From: clunt Date: Mon, 21 Mar 2022 09:39:34 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AF=AD=E6=B3=95=E8=A7=84=E8=8C=83=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ghy/goods/service/impl/GoodsCategoryServiceImpl.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ghy-goods/src/main/java/com/ghy/goods/service/impl/GoodsCategoryServiceImpl.java b/ghy-goods/src/main/java/com/ghy/goods/service/impl/GoodsCategoryServiceImpl.java index 2da46633..67731858 100644 --- a/ghy-goods/src/main/java/com/ghy/goods/service/impl/GoodsCategoryServiceImpl.java +++ b/ghy-goods/src/main/java/com/ghy/goods/service/impl/GoodsCategoryServiceImpl.java @@ -57,14 +57,18 @@ public class GoodsCategoryServiceImpl implements GoodsCategoryService { @Override public boolean checkGoodsCategoryNameUnique(GoodsCategory goodsCategory) { GoodsCategory category = goodsCategoryMapper.selectByGoodsCategoryName(goodsCategory.getGoodsCategoryName()); - if (category == null) return false; + if (category == null){ + return false; + } return category.getGoodsCategoryId().equals(goodsCategory.getGoodsCategoryId()); } @Override public boolean checkGoodsCategoryCodeUnique(GoodsCategory goodsCategory) { GoodsCategory category = goodsCategoryMapper.selectByGoodsCategoryCode(goodsCategory.getGoodsCategoryCode()); - if (category == null) return false; + if (category == null){ + return false; + } return category.getGoodsCategoryId().equals(goodsCategory.getGoodsCategoryId()); } }