删除 yes or no 枚举

This commit is contained in:
gong
2025-12-18 20:38:33 +08:00
parent 47f28d7bbb
commit 8ea7ef8c50
18 changed files with 99 additions and 130 deletions

View File

@@ -4,10 +4,7 @@ import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.util.StrUtil;
import com.czg.TimeQueryParam;
import com.czg.account.entity.PictureClassify;
import com.czg.account.entity.ShopInfo;
import com.czg.account.service.ShopInfoService;
import com.czg.enums.YesNoEnum;
import com.czg.exception.CzgException;
import com.czg.market.dto.MkLimitTimeDiscountDTO;
import com.czg.market.entity.MkLimitTimeDiscount;
@@ -29,7 +26,6 @@ import java.time.format.DateTimeFormatter;
import java.time.format.DateTimeParseException;
import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;
/**
* 限时折扣 服务层实现。

View File

@@ -127,7 +127,7 @@ public class PpPackageServiceImpl extends ServiceImpl<PpPackageMapper, PpPackage
@Override
@Transactional
public boolean updateOnlineStatus(Long id, Integer onlineStatus) {
if (!SystemConstants.OneZero.ZERO.equals(onlineStatus) && !SystemConstants.OneZero.ONE.equals(onlineStatus)) {
if (SystemConstants.OneZero.ZERO != onlineStatus && SystemConstants.OneZero.ONE != onlineStatus) {
throw new CzgException("参数错误");
}
Long shopId = StpKit.USER.getShopId();
@@ -138,7 +138,7 @@ public class PpPackageServiceImpl extends ServiceImpl<PpPackageMapper, PpPackage
throw new RuntimeException("无权限");
}
if (SystemConstants.OneZero.ZERO.equals(onlineStatus)) {
if (SystemConstants.OneZero.ZERO == onlineStatus) {
cancelProgressingPackageOrder(StpKit.USER.getShopId(), id);
}
@@ -152,7 +152,7 @@ public class PpPackageServiceImpl extends ServiceImpl<PpPackageMapper, PpPackage
// 如果没有开启操作,直接返回空数据
ShopConfig shopConfig = shopConfigService.getById(shopId);
if (SystemConstants.OneZero.ZERO.equals(shopConfig.getIsPackagePromotion())) {
if (SystemConstants.OneZero.ZERO == shopConfig.getIsPackagePromotion()) {
return new Page<>();
}