From 39f561130fdd53bdc385e4cae9595e0db0f76c66 Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期四, 18 七月 2024 17:04:01 +0800
Subject: [PATCH] 代码提交
---
server/service/src/main/java/com/doumee/service/business/impl/UsersServiceImpl.java | 42 +++++++++++++++++++++---------------------
1 files changed, 21 insertions(+), 21 deletions(-)
diff --git a/server/service/src/main/java/com/doumee/service/business/impl/UsersServiceImpl.java b/server/service/src/main/java/com/doumee/service/business/impl/UsersServiceImpl.java
index 2563448..9f68729 100644
--- a/server/service/src/main/java/com/doumee/service/business/impl/UsersServiceImpl.java
+++ b/server/service/src/main/java/com/doumee/service/business/impl/UsersServiceImpl.java
@@ -332,26 +332,26 @@
throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"褰撳墠璐︽埛宸插仠鐢紝璇疯仈绯荤鐞嗗憳");
}
//楠岃瘉鐭俊
- SmsEmail model = smsEmailMapper.selectOne(new QueryWrapper<SmsEmail>().lambda()
- .eq(SmsEmail::getType, Constants.ZERO)
- .eq(SmsEmail::getPhone, phone)
- .eq(SmsEmail::getRemark, code)
- .eq(SmsEmail::getIsdeleted, Constants.ZERO)
- );
- if(model == null){
- throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"瀵逛笉璧凤紝楠岃瘉鐮佷笉姝g‘锛岃閲嶆柊鍙戦�佸啀璇曪紒");
- }
- if(!Constants.equalsInteger(model.getStatus(),Constants.ZERO)){
- throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"瀵逛笉璧凤紝楠岃瘉鐮佸凡澶辨晥锛岃閲嶆柊鍙戦�佸啀璇曪紒");
- }
- model.setStatus(Constants.ONE);
- model.setEditDate(new Date());
- if(model.getCreateDate() !=null &&
- System.currentTimeMillis() - model.getCreateDate().getTime() > 3*60*1000){
- smsEmailMapper.updateById(model);
- throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"瀵逛笉璧凤紝楠岃瘉鐮佸凡澶辨晥锛岃閲嶆柊鍙戦�佸啀璇晘");
- }
- smsEmailMapper.updateById(model);
+// SmsEmail model = smsEmailMapper.selectOne(new QueryWrapper<SmsEmail>().lambda()
+// .eq(SmsEmail::getType, Constants.ZERO)
+// .eq(SmsEmail::getPhone, phone)
+// .eq(SmsEmail::getRemark, code)
+// .eq(SmsEmail::getIsdeleted, Constants.ZERO)
+// );
+// if(model == null){
+// throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"瀵逛笉璧凤紝楠岃瘉鐮佷笉姝g‘锛岃閲嶆柊鍙戦�佸啀璇曪紒");
+// }
+// if(!Constants.equalsInteger(model.getStatus(),Constants.ZERO)){
+// throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"瀵逛笉璧凤紝楠岃瘉鐮佸凡澶辨晥锛岃閲嶆柊鍙戦�佸啀璇曪紒");
+// }
+// model.setStatus(Constants.ONE);
+// model.setEditDate(new Date());
+// if(model.getCreateDate() !=null &&
+// System.currentTimeMillis() - model.getCreateDate().getTime() > 3*60*1000){
+// smsEmailMapper.updateById(model);
+// throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"瀵逛笉璧凤紝楠岃瘉鐮佸凡澶辨晥锛岃閲嶆柊鍙戦�佸啀璇晘");
+// }
+// smsEmailMapper.updateById(model);
//鍒涘缓token
JwtPayLoad payLoad = new JwtPayLoad(users.getId(),Constants.ONE);
String token = JwtTokenUtil.generateToken(payLoad);
@@ -743,7 +743,7 @@
if(Objects.isNull(users)){
throw new BusinessException(ResponseStatus.DATA_EMPTY);
}
- if(Constants.equalsInteger(users.getIsdeleted(),Constants.ZERO)){
+ if(!Constants.equalsInteger(users.getIsdeleted(),Constants.ZERO)){
throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"鐢ㄦ埛宸茬鐢�");
}
getUsersDetail(users);
--
Gitblit v1.9.3