package cn.sh.stc.sict.theme.hphy.model;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModelProperty;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import lombok.EqualsAndHashCode;

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

/**
 * 问卷题目
 *
 * @author F_xh
 * @date 2020-09-30 14:16:33
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("hphy_question")
public class HphyQuestion extends Model<HphyQuestion> {
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId
    @ApiModelProperty(hidden = false, value = "id")
    private Long id;

    @ApiModelProperty(hidden = true, value = "对应健海问题id")
    private String jhId;
    /**
     * 父id
     */
    @ApiModelProperty(hidden = false, value = "父id")
    private Long parentId;
    /**
     * 下一题id
     */
    @ApiModelProperty(hidden = false, value = "下一题id")
    private Long nextId;
    /**
     * 类型：0-问卷 1-语音
     */
    @ApiModelProperty(hidden = false, value = "类型：0-问卷 1-语音")
    private String type;
    /**
     * ui类型：radio-单选 multi-select-多选 input-输入框
     */
    @ApiModelProperty(hidden = false, value = "ui类型：radio-单选 multi-select-多选 input-输入框")
    private String uiType;
    /**
     * 题目
     */
    @ApiModelProperty(hidden = false, value = "题目")
    private String title;
    /**
     * 是否有其他：0-无 1-有
     */
    @ApiModelProperty(hidden = false, value = "是否有其他：0-无 1-有")
    private String hasExt;
    private String tag;
    /**
     * 更新时间
     */
    @TableField(fill = FieldFill.UPDATE)
    @ApiModelProperty(hidden = true, value = "更新时间")
    private Date updateTime;

    /**
     * 主键值
     */
    @Override
    protected Serializable pkVal() {
        return this.id;
    }
}
