diff --git a/src/main/java/com/xkrs/controller/SysUserController.java b/src/main/java/com/xkrs/controller/SysUserController.java index ad50af1..e39528d 100644 --- a/src/main/java/com/xkrs/controller/SysUserController.java +++ b/src/main/java/com/xkrs/controller/SysUserController.java @@ -275,7 +275,7 @@ public class SysUserController { @PostMapping("/adminUpdatePassword") public String adminUpdatePassword(@RequestBody Map map, @RequestHeader(value = "Authorization") String token) { // 要修改的用户的id - Long userId = (Long) map.get("userId"); + Integer userId = (Integer) map.get("userId"); String newPassword = (String) map.get("newPassword"); String confirmPassword = (String) map.get("confirmPassword"); // 验证token @@ -284,7 +284,7 @@ public class SysUserController { if (sysUserEntity == null) { return outputEncapsulationObject(PromptMessageEnum.USER_LOGIN_ERROR, "您还没有注册登录,请先注册登录", locale); } - return sysUserService.adminUpdatePassword(userId, newPassword, confirmPassword); + return sysUserService.adminUpdatePassword(Long.valueOf(userId), newPassword, confirmPassword); } /**