package cn.reghao.tnb.auth.app.model.vo;

import lombok.Getter;

import java.io.Serializable;

/**
 * 用户登入成功(/api/auth/signin 接口)返回的数据
 *
 * @author reghao
 * @date 2022-07-08 16:27:04
 */
@Getter
public class AccountLoginRet implements Serializable {
    private static final long serialVersionUID = 1L;

    private LoginAccount accountInfo;
    private AccountToken accountToken;
    private String userId;
    private String sessId;
    private int plat;
    private String redirectPath;

    public AccountLoginRet(String redirectPath) {
        this.redirectPath = redirectPath;
    }

    public AccountLoginRet(LoginAccount loginAccount, AccountToken accountToken, String redirectPath) {
        this.accountInfo = loginAccount;
        this.accountToken = accountToken;
        this.redirectPath = redirectPath;
    }

    public AccountLoginRet(String userIdStr, String loginId, int plat, String redirectPath) {
        this.userId = userIdStr;
        this.sessId = loginId;
        this.plat = plat;
        this.redirectPath = redirectPath;
    }
}
