package com.sonic.frog.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.Period;
import java.time.ZoneId;
import java.util.Date;

/**
 * AI用户表
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@TableName("ai_user")
@ApiModel("AI用户表")
public class AiUser {
    @ApiModelProperty("id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty("AI的id")
    @TableField("ai_id")
    private Long aiId;

    @ApiModelProperty("AI所属主人用户id")
    @TableField("user_id")
    private Long userId;

    @ApiModelProperty("AI用户对外展示ID")
    @TableField("id_card")
    private String idCard;

    @ApiModelProperty("昵称")
    @TableField("nickname")
    private String nickname;

    @ApiModelProperty("0,男;1,女;2,自定义")
    @TableField("sex")
    private Integer sex;

    @ApiModelProperty("头像")
    @TableField("head_img")
    private String headImg;

    @ApiModelProperty("出生日期")
    @TableField("birthday")
    private LocalDateTime birthday;

    @ApiModelProperty("角色code 对应ai_dict表中code")
    @TableField("role_code")
    private String roleCode;

    @ApiModelProperty("性格code 对应ai_dict表中code")
    @TableField("character_code")
    private String characterCode;

    @ApiModelProperty("标签code 对应ai_dict表中code")
    @TableField("tag_code")
    private String tagCode;

    @ApiModelProperty("简介")
    @TableField("introduction")
    private String introduction;

    @ApiModelProperty("权限 1: 公开 2：私密")
    @TableField("permission")
    private Integer permission;

    @ApiModelProperty("形象图")
    @TableField("image_url")
    private String imageUrl;

    @ApiModelProperty("主页头图-创建编辑时会改变")
    @TableField("home_image_url")
    private String homeImageUrl;

    @ApiModelProperty("基图-首次创建AI时选择的形象图")
    @TableField("base_image_url")
    private String baseImageUrl;

    @ApiModelProperty("最后一次聊天时间")
    @TableField("last_chat_time")
    private LocalDateTime lastChatTime;

    @ApiModelProperty("是否删除（1.是，0.否）")
    @TableField("is_delete")
    private Boolean isDelete;

    @ApiModelProperty("创建时间")
    @TableField("create_time")
    private LocalDateTime createTime;

    @ApiModelProperty("修改人")
    @TableField("editor_id")
    private Long editorId;

    @ApiModelProperty("更新时间")
    @TableField("edit_time")
    private LocalDateTime editTime;

}