package com.ningdatech.kqapi.user.model.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.ningdatech.kqapi.user.model.enumerization.AccountStatus;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 用户基本信息
 * </p>
 *
 * @author Liuxinxin
 * @since 2022-11-23
 */
@Data
@TableName("nd_user_info")
@ApiModel(value = "UserInfo对象")
public class UserInfo implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty("创建时间")
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createOn;

    @ApiModelProperty("最后修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateOn;

    @ApiModelProperty("创建人")
    @TableField(fill = FieldFill.INSERT)
    private Long createBy;

    @ApiModelProperty("最后修改人")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Long updateBy;

    @ApiModelProperty("用户名")
    private String username;

    @ApiModelProperty("手机")
    private String mobile;

    @ApiModelProperty("用户真实姓名")
    private String realName;

    @ApiModelProperty("角色")
    private String role;

    @ApiModelProperty("头像文件id")
    private Long avatarFileId;

    @ApiModelProperty("账号状态")
    private AccountStatus accountStatus;

    @TableLogic
    @ApiModelProperty("逻辑删除")
    private Boolean deleted;

}
