package xyz.luxnk.lproject.bean;

import org.nutz.dao.entity.annotation.*;

import java.util.Date;

/**
 * 用户基本信息Pojo
 * 对应user_info表
 */
@Table("user_info")
public class UserInfo extends BasePojo {

    @Name
    @Prev(els = @EL("snowflake()"))
    private String id;

    @Column
    private String username;

    @Column
    private String password;

    @Column
    private String salt;

    @One(target = UserProfile.class, field = "id", key = "userId")
    private UserProfile profile;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getSalt() {
        return salt;
    }

    public void setSalt(String salt) {
        this.salt = salt;
    }

    public UserProfile getProfile() {
        return profile;
    }

    public void setProfile(UserProfile profile) {
        this.profile = profile;
    }
}
