package com.lutao.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
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.lutao.annotate.Validation;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDateTime;

@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "工况状态信息表")
@TableName("work_status_clm")
public class WorkStatusClm extends Model<WorkStatusClm> {
    private static final long serialVersionUID = -4937619764564072700L;

    @ApiModelProperty(value = "id")
    @TableId
    private Integer id;

    @ApiModelProperty(value = "原始id")
    @Validation(message = "work_status_clm表{id}不能为空")
    private String originId;

    @ApiModelProperty(value = "app_id")
    private String appId;

    @ApiModelProperty(value = "平台编码")
    @Validation(message = "work_status_clm表{platform_code}不能为空")
    private String platformCode;

    @ApiModelProperty(value = "设施名称")
    private String facilityName;

    @ApiModelProperty(value = "设施编码")
    private String facilityCode;

    @ApiModelProperty(value = "设备名称")
    private String equipName;

    @ApiModelProperty(value = "设备编码")
    private String equipCode;

    @ApiModelProperty(value = "状态 0关停，1.启动")
    @Validation(message = "work_status_clm表{status}不能为空")
    private Integer status;

    @ApiModelProperty(value = "上报时间")
    @Validation(message = "work_status_clm表{collect_time}不能为空")
    private LocalDateTime collectTime;

    @ApiModelProperty(value = "关断等级,1.未关断，2.单元关断，3.生产关断，4.火气关断，5.平台关断")
    @Validation(message = "work_status_clm表{to_levle}不能为空")
    private String toLevle;

    @ApiModelProperty(value = "变更原因")
    @Validation(message = "work_status_clm表{change_reason}不能为空")
    private String changeReason;


    @ApiModelProperty(value = "创建日期")
    private LocalDateTime createDate;

    @ApiModelProperty(value = "创建人")
    private String createBy;

    @ApiModelProperty(value = "更新日期")
    private LocalDateTime updateDate;

    @ApiModelProperty(value = "更新人")
    private String updateBy;


    @ApiModelProperty(value = "数据收集时间")
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @ApiModelProperty(value = "数据更新时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;

    private String descs;

}
