feat:请不要使用系统默认店名

This commit is contained in:
苏竹红
2025-11-17 19:51:20 +08:00
parent 1ab05c19e5
commit e8782b21cb
2 changed files with 7 additions and 1 deletions

View File

@@ -212,7 +212,9 @@ public enum ErrorCodeEnum {
INVOICING_EXIST(109016, "当前门店发票信息已存在!", null), INVOICING_EXIST(109016, "当前门店发票信息已存在!", null),
SHOP_STATUS_NOT_SUPPORT_HANDLER(109016, "当前门店状态为:{0},不能进行结束跟进操作", null), SHOP_STATUS_NOT_SUPPORT_HANDLER(109017, "当前门店状态为:{0},不能进行结束跟进操作", null),
SYSTEM_NAME_NOT__SUPPORT(109018, "请不要使用系统默认店名!", null),
INSERT_OPENING_OPERATION_PLAN_AUDIT_FALSE(103001,"插入运营方案审核信息失败",null), INSERT_OPENING_OPERATION_PLAN_AUDIT_FALSE(103001,"插入运营方案审核信息失败",null),

View File

@@ -177,6 +177,10 @@ public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResu
if (Objects.isNull(request.getShopId())) { if (Objects.isNull(request.getShopId())) {
throw new ServiceException(ErrorCodeEnum.SHOP_ID_NOT_EXIST); throw new ServiceException(ErrorCodeEnum.SHOP_ID_NOT_EXIST);
} }
//不要使用系统默认名称
if (StringUtils.isNotEmpty(request.getShopName())&&request.getShopName().matches("^店铺.$")) {
throw new ServiceException(ErrorCodeEnum.SYSTEM_NAME_NOT__SUPPORT);
}
SignFranchiseDO isExist = signFranchiseMapper.selectByShopId(request.getShopId()); SignFranchiseDO isExist = signFranchiseMapper.selectByShopId(request.getShopId());
if (Objects.nonNull(isExist) && Objects.isNull(request.getId())) { if (Objects.nonNull(isExist) && Objects.isNull(request.getId())) {
throw new ServiceException(ErrorCodeEnum.DUPLICATE_SUBMISSION); throw new ServiceException(ErrorCodeEnum.DUPLICATE_SUBMISSION);