package com.nantian.cloud.jljc.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.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 java.io.Serializable;
import java.util.Date;

/**
 * 报表1-3-1可比单位产品综合能耗表
 * @since 2021-01-06
 */
@Data
@TableName("t_report_unitenergy_comp")
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "报表1-3-1可比单位产品综合能耗表")
public class TReportUnitenergyComp extends Model<TReportUnitenergyComp> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     *  报表信息表id
     */
    @ApiModelProperty(value = "报表信息表id")
    private Long reportId;

    /**
     * 指标id
     */
    @ApiModelProperty(value = "指标id")
    private Long quotaId;

    /**
     * 指标名称
     */
    @ApiModelProperty(value = "指标名称")
    private String quotaName;

    /**
     * 指标单位
     */
    @ApiModelProperty(value = "指标单位")
    private String quotaUnit;

    /**
     * 指标值
     */
    @ApiModelProperty(value = "指标值")
    private String quotaValue;

    /**
     * 上年指标值
     */
    @ApiModelProperty(value = "上年指标值")
    @TableField(exist = false) //不是数据库表字段
    private String prevQuotaValue;

    /**
     * 指标限额
     */
    @ApiModelProperty(value = "指标限额")
    private String quotaLimit;

    /**
     * 说明
     */
    @ApiModelProperty(value = "说明")
    private String remarks;

    /**
     * 用户id
     */
    @ApiModelProperty(value = "用户id")
    private Integer userid;

    /**
     * 更新时间
     */
    @ApiModelProperty(value = "更新时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern="yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    /**
     * 注销状态（1：未删除，4：已删除）
     */
    @ApiModelProperty(value = "注销状态（1：未删除，4：已删除）")
    private String delFlag;

    /**
     * 部门id
     */
    @ApiModelProperty(value = "部门id")
    private Integer deptId;

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