diff --git a/rc-service/rc-service-other/other-infrastructure/src/main/java/com/red/circle/other/infra/database/rds/service/user/user/impl/UserBeautifulNumberApplyServiceImpl.java b/rc-service/rc-service-other/other-infrastructure/src/main/java/com/red/circle/other/infra/database/rds/service/user/user/impl/UserBeautifulNumberApplyServiceImpl.java index 25ba3adc..0752cd20 100644 --- a/rc-service/rc-service-other/other-infrastructure/src/main/java/com/red/circle/other/infra/database/rds/service/user/user/impl/UserBeautifulNumberApplyServiceImpl.java +++ b/rc-service/rc-service-other/other-infrastructure/src/main/java/com/red/circle/other/infra/database/rds/service/user/user/impl/UserBeautifulNumberApplyServiceImpl.java @@ -51,8 +51,6 @@ public class UserBeautifulNumberApplyServiceImpl extends @Override public void handleApply(Long id, Integer state) { UserBeautifulNumberApply apply = query().eq(UserBeautifulNumberApply::getId, id).getOne(); - ResponseAssert.notNull(CommonErrorCode.DATA_ERROR, apply); - apply.setUpdateTime(TimestampUtils.now()); apply.setState(state); updateSelectiveById(apply); diff --git a/rc-service/rc-service-other/other-inner-endpoint/src/main/java/com/red/circle/other/app/inner/service/user/user/impl/UserBeautifulNumberClientServiceImpl.java b/rc-service/rc-service-other/other-inner-endpoint/src/main/java/com/red/circle/other/app/inner/service/user/user/impl/UserBeautifulNumberClientServiceImpl.java index 0cea175d..7950da60 100644 --- a/rc-service/rc-service-other/other-inner-endpoint/src/main/java/com/red/circle/other/app/inner/service/user/user/impl/UserBeautifulNumberClientServiceImpl.java +++ b/rc-service/rc-service-other/other-inner-endpoint/src/main/java/com/red/circle/other/app/inner/service/user/user/impl/UserBeautifulNumberClientServiceImpl.java @@ -52,10 +52,13 @@ public class UserBeautifulNumberClientServiceImpl implements @Override public void handleApply(Long id, Integer state, String remark) { + UserBeautifulNumberApply beautifulNumberApply = userBeautifulNumberApplyService.getById(id); + ResponseAssert.notNull(CommonErrorCode.DATA_ERROR, beautifulNumberApply); ResponseAssert.isTrue(CommonErrorCode.TYPE_IS_NOT_IN_SCOPE, checkState(state)); + ResponseAssert.isTrue(CommonErrorCode.DATA_ERROR, beautifulNumberApply.getState() == 0); + userBeautifulNumberApplyService.handleApply(id, state); - UserBeautifulNumberApply beautifulNumberApply = userBeautifulNumberApplyService.getById(id); String content; if (state == 1) { UserSpecialId userSpecialId = userSpecialIdService.getByUserId(beautifulNumberApply.getApplyUser());