package org.jeecg.modules.system.app.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecg.common.aspect.annotation.Dict;
import org.jeecgframework.poi.excel.annotation.Excel;
import org.springframework.format.annotation.DateTimeFormat;

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

/**
 * @Description: 保险表
 * @Author: jeecg-boot
 * @Date:   2025-07-03
 * @Version: V1.0
 */
@Data
@TableName("nm_insure")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@Schema(description="保险表")
public class AppInsure implements Serializable {
    private static final long serialVersionUID = 1L;

	/**id*/
	@TableId(type = IdType.ASSIGN_ID)
    @Schema(description = "id")
    private String id;
	/**部门id*/
	@Excel(name = "部门id", width = 15)
    @Schema(description = "部门id")
    private String orgCode;
	/**租户id*/
	@Excel(name = "租户id", width = 15)
    @Schema(description = "租户id")
    private String tenantId;

    @Dict(dicCode = "insurance_name")
    @Schema(description = "保险公司")
    private Integer insuranceName;
    @TableField(exist = false)
    @Schema(description = "保险公司名称")
    private String insuranceName_dictText;
    @Dict(dicCode = "insurance_type")
    @Schema(description = "保险类型,暂时为0 意外险")
    private Integer insuranceType;
    @TableField(exist = false)
    @Schema(description = "保险类型名称,暂时为0 意外险")
    private String insuranceType_dictText;
    @Schema(description = "保险责任与保额使用json存储key为保险责任，value为保额")
    private String insuranceObvious;
	/**险种*/
	@Excel(name = "险种", width = 15)
    @Schema(description = "险种")
    private String name;
	/**略图*/
	@Excel(name = "封面", width = 15)
    @Schema(description = "封面")
    private String coverImg;
	/**创建人;创建人*/
    @Schema(description = "创建人;创建人")
    private String createBy;
	/**创建时间;创建时间*/
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @Schema(description = "创建时间;创建时间")
    private Date createTime;
	/**更新人;更新人*/
    @Schema(description = "更新人;更新人")
    private String updateBy;
	/**更新时间;更新时间*/
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @Schema(description = "更新时间;更新时间")
    private Date updateTime;
	/**系统状态;状态(0-正常,1-冻结)*/
	@Excel(name = "系统状态;状态(0-正常,1-冻结)", width = 15)
    @Schema(description = "系统状态;状态(0-正常,1-冻结)")
    private Integer status;
	/**删除标志;删除状态(0-正常,1-已删除)*/
	@Excel(name = "删除标志;删除状态(0-正常,1-已删除)", width = 15)
    @Schema(description = "删除标志;删除状态(0-正常,1-已删除)")
    @TableLogic
    private Integer delFlag;


    @TableField(exist = false)
    @Schema(description = "保险期限")
    private List<InsurePrice> priceDataList;
}
