kongdeqiang
2026-10-12 7c687dd3c8fba9f7632f5e29d94a708e5f497abd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package com.custom.webui.dto.resp;
 
import lombok.Data;
 
/** 登录成功返回体:JWT + 当前用户信息。 */
@Data
public class LoginResponse {
 
    /** JWT,前端后续请求放入 Authorization: Bearer {token} */
    private String token;
 
    /** 过期时间戳(毫秒),前端可据此提前续期 */
    private Long expiresAt;
 
    private UserDTO user;
 
    public LoginResponse(String token, Long expiresAt, UserDTO user) {
        this.token = token;
        this.expiresAt = expiresAt;
        this.user = user;
    }
}