Commit 8fe46b79 authored by honghy's avatar honghy Committed by wux

等级启动禁用清空bug修改

parent 6ac38f2d
......@@ -160,17 +160,16 @@ public class MemberUserLevelConfigServiceImpl extends AbstractService<MemberUser
throw exception(LEVEL_RULE_NOT_EXISTS);
}
Integer oldStatus = memberUserLevelConfigDO.getStatus();
MemberUserLevelConfigDO upMemberLevelConfigDO = new MemberUserLevelConfigDO();
upMemberLevelConfigDO.setId(memberUserLevelStatusReqVO.getId());
if (oldStatus == MemberLevelStatusEnum.ENABLED.getValue() && memberUserLevelStatusReqVO.getStatus() == MemberLevelStatusEnum.CLOSED.getValue()) {
upMemberLevelConfigDO.setStatus(memberUserLevelStatusReqVO.getStatus());
memberUserLevelConfigDO.setStatus(memberUserLevelStatusReqVO.getStatus());
} else if (oldStatus == MemberLevelStatusEnum.DRAFT.getValue() && memberUserLevelStatusReqVO.getStatus() == MemberLevelStatusEnum.ENABLED.getValue()) {
upMemberLevelConfigDO.setStatus(memberUserLevelStatusReqVO.getStatus());
upMemberLevelConfigDO.setEnableDate(new Date());
memberUserLevelConfigDO.setStatus(memberUserLevelStatusReqVO.getStatus());
memberUserLevelConfigDO.setEnableDate(new Date());
} else {
throw exception(SCORE_RULE_STATUS_ERROR);
}
memberUserLevelConfigMapper.updateById(upMemberLevelConfigDO);
memberUserLevelConfigMapper.updateById(memberUserLevelConfigDO);
}
private void createLog(MemberUserLevelConfigDO memberUserLevelConfigDO,Integer operateType){
MemberUserLevelLogCreateReq memberUserLevelLogcreateReq = MemberUserLevelLogCreateReq
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment