This commit is contained in:
guohb
2024-05-28 15:19:01 +08:00
parent 9cc17211bc
commit 6041f49efa
2 changed files with 6 additions and 0 deletions

View File

@@ -192,6 +192,8 @@ public enum ErrorCodeEnum {
TIME_NULL_FALSE(109013, "有时间为空", null),
UNISSUED_STATEMENT_2(109014, "该门店已发布账单", null),
INSERT_OPENING_OPERATION_PLAN_AUDIT_FALSE(103001,"插入运营方案审核信息失败",null),
INSERT_OPENING_OPERATION_PLAN_FALSE(103002,"插入运营方案失败",null),

View File

@@ -59,6 +59,10 @@ public class FranchiseFeeServiceImpl implements FranchiseFeeService {
franchiseFeeDO.setId(request.getId());
franchiseFeeMapper.updateByPrimaryKeySelective(franchiseFeeDO);
} else {
FranchiseFeeDO isExist = franchiseFeeMapper.selectByShopId(request.getShopId());
if (Objects.nonNull(isExist)){
throw new ServiceException(ErrorCodeEnum.UNISSUED_STATEMENT_2);
}
franchiseFeeMapper.insertSelective(franchiseFeeDO);
}
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(request.getShopId());