diff --git a/framework/src/main/java/cn/lili/modules/store/serviceimpl/StoreServiceImpl.java b/framework/src/main/java/cn/lili/modules/store/serviceimpl/StoreServiceImpl.java index 4c6931c9..ea77b45b 100644 --- a/framework/src/main/java/cn/lili/modules/store/serviceimpl/StoreServiceImpl.java +++ b/framework/src/main/java/cn/lili/modules/store/serviceimpl/StoreServiceImpl.java @@ -342,10 +342,11 @@ public class StoreServiceImpl extends ServiceImpl implements */ private void checkStoreStatus(Store store) { - //如果店铺状态为申请中或者已申请,则正常走流程,否则抛出异常 - if (store.getStoreDisable().equals(StoreStatusEnum.APPLY.name()) || store.getStoreDisable().equals(StoreStatusEnum.APPLYING.name())) { - return; - } else { + //如果店铺状态为已开启、已关闭、申请中,则抛出异常 + if (store.getStoreDisable().equals(StoreStatusEnum.OPEN.name()) + || store.getStoreDisable().equals(StoreStatusEnum.CLOSED.name()) + || store.getStoreDisable().equals(StoreStatusEnum.APPLYING.name()) + ) { throw new ServiceException(ResultCode.STORE_STATUS_ERROR); } @@ -381,7 +382,7 @@ public class StoreServiceImpl extends ServiceImpl implements AuthUser currentUser = UserContext.getCurrentUser(); List skuIdList = new ArrayList<>(); for (FootPrint footPrint : footprintService.list(new LambdaUpdateWrapper().eq(FootPrint::getStoreId, currentUser.getStoreId()).eq(FootPrint::getMemberId, memberId))) { - if(footPrint.getSkuId() != null){ + if (footPrint.getSkuId() != null) { skuIdList.add(footPrint.getSkuId()); } }