package com.tofly.bigscreen.entity;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 大屏指标管理数据
 *
 * @author he shan
 * @date 2022/8/22
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName(value="TF_YWPN_BIGSCREEN_DATA",resultMap = "bigScreenDataMap")
@KeySequence("TF_YWPN_BIGSCREEN_DATA")
@ApiModel
public class BigScreenData extends Model<BigScreenData> {
    private static final long serialVersionUID = 1L;

    @TableId(value = "ID",type= IdType.INPUT)
    @ApiModelProperty(value = "主键ID")
    private Long id;

    @ApiModelProperty(value = "分组")
    @Excel(name = "分组", width = 15,needMerge = true)
    private String dataGroup;

    @ApiModelProperty(value = "项目编码")
    @Excel(name = "项目编码", width = 15,needMerge = true)
    private String projectCode;

    @ApiModelProperty(value = "项目名称")
    @Excel(name = "项目名称", width = 15,needMerge = true)
    private String projectName;

    @ApiModelProperty(value = "管理领域")
    @Excel(name = "管理领域", width = 15,needMerge = true)
    private String mangeField;

    @ApiModelProperty(value = "指标分类")
    @Excel(name = "指标分类", width = 15,needMerge = true)
    private String indexType;

    @ApiModelProperty(value = "指标编码")
    @Excel(name = "指标编码", width = 15,needMerge = true)
    private String indexCode;

    @ApiModelProperty(value = "指标名称")
    @Excel(name = "指标名称", width = 15,needMerge = true)
    private String indexName;

    @ApiModelProperty(value = "指标值")
    @Excel(name = "指标值", width = 10,needMerge = true)
    private String indexValue;

    @ApiModelProperty(value = "单位")
    @Excel(name = "单位", width = 15,needMerge = true)
    private String unit;

    @ApiModelProperty(value = "提示信息")
    @Excel(name = "提示信息", width = 40,needMerge = true)
    private String floatTips;

    @ApiModelProperty(value = "指标值精度")
    private BigDecimal indexPrecision;

    @ApiModelProperty(value = "备注")
    private String note;

    @ApiModelProperty(value = "数据统计日期")
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @Excel(name = "数据统计日期", width = 40,needMerge = true)
    private Date stsDate;

    @ApiModelProperty(value = "数据来源 1 导入 0 新增")
    private String source;

    @ApiModelProperty(value = "是否最新 1 是 0否")
    private String isNew;

    @ApiModelProperty(value = "操作人")
    private String createUserName;

    @ApiModelProperty(value = "操作日期")
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @TableField(value = "CREATE_DATE",fill = FieldFill.INSERT)
    private Date createDate;


    @ApiModelProperty(value = "统计周期开始日期")
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @Excel(name = "统计周期开始日期", width = 40,needMerge = true)
    private Date statisticalPeriodStartDate;

    @ApiModelProperty(value = "统计周期结束日期")
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @Excel(name = "统计周期结束日期", width = 40,needMerge = true)
    private Date statisticalPeriodEndDate;



}
