package org.jeecg.module.custom.ocr.dataobject;

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.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;


/**
 * 表单字段配置信息表
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@ApiModel(value = "表单字段配置信息表", description = "表单字段配置信息表")
@TableName(value = "form_config")
public class FormConfig implements Serializable {

    private static final long serialVersionUID = -1037833124337760L;

    @ApiModelProperty(value = "主键")
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @JsonSerialize(using = ToStringSerializer.class)
    @TableField(value = "ID")
    private Long id;

    @ApiModelProperty(value = "状态")
    @TableField(value = "status")
    private String status;

    @ApiModelProperty(value = "信息")
    @TableField(value = "message")
    private String message;

    @ApiModelProperty(value = "时间戳")
    @TableField(value = "timeStamp")
    private Long timestamp;

    @ApiModelProperty(value = "签名")
    @TableField(value = "signature")
    private String signature;

    @ApiModelProperty(value = "数据")
    @TableField(value = "data")
    private String data;

    @ApiModelProperty(value = "租户雪花no")
    @TableField(value = "tenantNo")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long tenantNo;

    @ApiModelProperty(value = "业务主体雪花no")
    @TableField(value = "accountNo")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long accountNo;

    @ApiModelProperty(value = "关联项目no")
    @TableField(value = "projectNo")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long projectNo;

    @ApiModelProperty(value = "任务表单no")
    @TableField(value = "taskFormNo")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long taskFormNo;

    @ApiModelProperty(value = "字段集合 json")
    @TableField(value = "fieldList")
    private String fieldList;

    @ApiModelProperty(value = "字段类型, 1:固定字段 2:动态字段")
    @TableField(value = "字段类型")
    private Integer type;

    @ApiModelProperty(value = "字段英文名")
    @TableField(value = "fieldCode")
    private String fieldCode;

    @ApiModelProperty(value = "字段中文名")
    @TableField(value = "fieldName")
    private String fieldName;

    @ApiModelProperty(value = "父字段英文名")
    @TableField(value = "parentFileCode")
    private String parentFileCode;

    @ApiModelProperty(value = "层级")
    @TableField(value = "level")
    private Integer level;
}
