package com.ynfy.buss.practice.userpracticequestion.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 com.fasterxml.jackson.annotation.JsonFormat;
import com.ynfy.buss.exam.question.entity.Question;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * @Description: 用户练习题目表
 * @Author: jeecg-boot
 * @Date: 2023-11-19
 * @Version: V1.0
 */
@Data
@TableName("user_practice_question")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "user_practice_question对象", description = "用户练习题目表")
public class UserPracticeQuestion implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(type = IdType.ASSIGN_ID)
    @ApiModelProperty(value = "id")
    private String id;
    /**
     * 试卷id
     */
    @Excel(name = "试卷id", width = 15)
    @ApiModelProperty(value = "试卷id")
    private String userPracticeId;
    /**
     * 题目id
     */
    @Excel(name = "题目id", width = 15)
    @ApiModelProperty(value = "题目id")
    private String questionId;
    /**
     * 题目类型
     */
    @Excel(name = "题目类型", width = 15)
    @ApiModelProperty(value = "题目类型")
    private Integer questionType;
    /**
     * 问题排序
     */
    @Excel(name = "问题排序", width = 15)
    @ApiModelProperty(value = "问题排序")
    private Integer sort;
    /**
     * 是否已答
     */
    @Excel(name = "是否已答", width = 15)
    @ApiModelProperty(value = "是否已答")
    private Boolean answered;
    /**
     * 是否答对
     */
    @Excel(name = "是否答对", width = 15)
    @ApiModelProperty(value = "是否答对")
    private Boolean isRight;
    /**
     * 答案
     */
    @Excel(name = "答案", width = 15)
    @ApiModelProperty(value = "答案")
    private String answer;

    /**
     * 创建人
     */
    @ApiModelProperty(value = "创建人")
    private String createBy;
    /**
     * 创建日期
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建日期")
    private Date createTime;
    /**
     * 更新人
     */
    @ApiModelProperty(value = "更新人")
    private String updateBy;
    /**
     * 更新日期
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "更新日期")
    private Date updateTime;

    @TableField(exist = false)
    private Question question;

    @TableField(exist = false)
    private String questionTypeName;
}
