Commit 4bce1da1 authored by nie'hong's avatar nie'hong

Merge remote-tracking branch 'origin/dev' into dev

parents 479ab021 ab52d363
...@@ -66,8 +66,12 @@ public class SystemOperationLogService extends ServiceImpl<SysLogMapper, SysLog> ...@@ -66,8 +66,12 @@ public class SystemOperationLogService extends ServiceImpl<SysLogMapper, SysLog>
if (StringUtils.isBlank(header)) { if (StringUtils.isBlank(header)) {
throw new AuthenticationException("token失效,请重新登录"); throw new AuthenticationException("token失效,请重新登录");
} }
String username = JwtTokenUtil.getUsername(header); /**
return userService.selectByUsername(username); * 决绝修改用户名会报错的问题
*/
// String username = JwtTokenUtil.getUsername(header);
String userId = JwtTokenUtil.getEmployeeId(header);
return userService.selectById(userId);
} }
/** /**
......
...@@ -263,8 +263,10 @@ public class BaseController implements Serializable { ...@@ -263,8 +263,10 @@ public class BaseController implements Serializable {
* </p> * </p>
*/ */
protected TUser getcurUser() { protected TUser getcurUser() {
String userName = getUserName(); // String userName = getUserName();
TUser user = userService.selectByUsername(userName); String userId = getUserId();
// TUser user = userService.selectByUsername(userName);
TUser user = userService.selectById(userId);
return user; return user;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment