package com.tofly.spire.entity;


import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.haiqiu.tools.excel.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * 小表（户表）(SpireMinGrid)表实体类
 *
 * @author HaiQiu
 * @since 2022-11-11 11:52:49
 */
@Data
@Accessors(chain = true)
@NoArgsConstructor
@EqualsAndHashCode(callSuper = false)
@TableName(value = "SPIRE_MIN_GRID", resultMap = "SpireMinGridMap")
@ApiModel(value = "SpireMinGrid对象", description = "小表（户表）")
public class SpireMinGrid extends Model<SpireMinGrid> {

    private static final long serialVersionUID = 105857779987001113L;

    /**
     * 主键ID
     */
    @Excel(name = "主键ID")
    @ApiModelProperty(value = "主键ID")
    @TableId(type = IdType.ASSIGN_ID)
    private Long id;

    /**
     * 累计量(m³)
     */
    @Excel(name = "累计量(m³)")
    @ApiModelProperty(value = "累计量(m³)")
    private String accFlow;

    /**
     * 瞬时量 (m³/h)
     */
    @Excel(name = "瞬时量 (m³/h)")
    @ApiModelProperty(value = "瞬时量 (m³/h)")
    private String flow;

    /**
     * 温度 (℃)
     */
    @Excel(name = "温度 (℃)")
    @ApiModelProperty(value = "温度 (℃)")
    private String temp;

    /**
     * 表具状态
     */
    @Excel(name = "表具状态")
    @ApiModelProperty(value = "表具状态")
    private String meterStatus;

    /**
     * 表具时间
     */
    @Excel(name = "表具时间")
    @ApiModelProperty(value = "表具时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date readTime;

    /**
     * 表号
     */
    @Excel(name = "表号")
    @ApiModelProperty(value = "表号")
    private String sn;

    /**
     * 上传时间
     */
    @Excel(name = "上传时间")
    @ApiModelProperty(value = "上传时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date uploadTime;

    /**
     * 创建时间
     */
    @Excel(name = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    /**
     * 修改时间
     */
    @Excel(name = "修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    @ApiModelProperty(value = "修改时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

}

