Browse Source
!799 update ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysProfileController.java.
Merge pull request !799 from 张利/N/A
newMaster
若依
2 years ago
committed by
Gitee
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with
3 additions and
2 deletions
-
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysProfileController.java
|
|
@ -100,10 +100,11 @@ public class SysProfileController extends BaseController |
|
|
|
{ |
|
|
|
return error("新密码不能与旧密码相同"); |
|
|
|
} |
|
|
|
if (userService.resetUserPwd(userName, SecurityUtils.encryptPassword(newPassword)) > 0) |
|
|
|
newPassword = SecurityUtils.encryptPassword(newPassword); |
|
|
|
if (userService.resetUserPwd(userName, newPassword) > 0) |
|
|
|
{ |
|
|
|
// 更新缓存用户密码
|
|
|
|
loginUser.getUser().setPassword(SecurityUtils.encryptPassword(newPassword)); |
|
|
|
loginUser.getUser().setPassword(newPassword); |
|
|
|
tokenService.setLoginUser(loginUser); |
|
|
|
return success(); |
|
|
|
} |
|
|
|