修复登录时密码错误 提示异常

master
jiakun.lin 4 years ago
parent 53a036611c
commit 0cc24aac96
  1. 11
      src/main/java/com/yipin/liuwanr/service/UserInfoService.java

@ -404,7 +404,11 @@ public class UserInfoService {
try {
UserInfo user=userInfoMapper.loginsAP(userInfo);
//区分密码大小写
boolean num = user.getPassword().equals(userInfo.getPassword());
boolean num = false;
if (user != null){
num = userInfo.getPassword().equals(user.getPassword());
}
if(user!=null && num == true) {
Integer userId = user.getUserId();
@ -476,8 +480,11 @@ public class UserInfoService {
try {
UserInfo user=userInfoMapper.adminLogins(userInfo);
//区分密码大小写
boolean num = user.getPassword().equals(userInfo.getPassword());
boolean num = false;
if (user != null){
num = userInfo.getPassword().equals(user.getPassword());
user.setPassword(null);
}
if(user != null){
if (user.getRoleId().contains("1")){
user.setSchoolId(null);

Loading…
Cancel
Save