更新登录接口返回的用户信息
This commit is contained in:
parent
85f50f4aad
commit
081d5cd66c
@ -3,6 +3,7 @@ package com.xkrs.common.account;
|
|||||||
import com.xkrs.common.encapsulation.OutputEncapsulation;
|
import com.xkrs.common.encapsulation.OutputEncapsulation;
|
||||||
import com.xkrs.common.encapsulation.PromptMessageEnum;
|
import com.xkrs.common.encapsulation.PromptMessageEnum;
|
||||||
import com.xkrs.model.entity.SysUserEntity;
|
import com.xkrs.model.entity.SysUserEntity;
|
||||||
|
import com.xkrs.utilsnew.SysUserConvertUtils;
|
||||||
import io.jsonwebtoken.Claims;
|
import io.jsonwebtoken.Claims;
|
||||||
import io.jsonwebtoken.Jwts;
|
import io.jsonwebtoken.Jwts;
|
||||||
import io.jsonwebtoken.security.Keys;
|
import io.jsonwebtoken.security.Keys;
|
||||||
@ -80,7 +81,7 @@ public class TokenAuthenticationService {
|
|||||||
// 签名设置
|
// 签名设置
|
||||||
.signWith(key).compact();
|
.signWith(key).compact();
|
||||||
map.put("token", jwt);
|
map.put("token", jwt);
|
||||||
map.put("user", sysUserEntity);
|
map.put("user", SysUserConvertUtils.convert(sysUserEntity));
|
||||||
// 将 JWT 写入 body
|
// 将 JWT 写入 body
|
||||||
PrintWriter out = null;
|
PrintWriter out = null;
|
||||||
try {
|
try {
|
||||||
|
Loading…
Reference in New Issue
Block a user