package com.sw.mes.yb.deviceCheck.entity;

import lombok.Data;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.*;
import java.math.BigDecimal;
import java.util.Date;

@Data
@Entity
@DynamicUpdate
@DynamicInsert
@Table(name = "zhxx_operate_device_check")
public class DeviceCheck {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Integer id;

    /**
     * 设备编号
     */
//    @JSONField(name = "deviceno", serialize = false)
    @Column(name = "device_no", length = 40)
    private String deviceNo;

    /**
     * 设备系列
     */
//    @JSONField(name = "deviceno", serialize = false)
    @Column(name = "device_series", length = 40)
    private String deviceSeries;

    /**
     * 炉次号
     */
//    @JSONField(name = "furnaceno", serialize = false)
    @Column(name = "lot_no", length = 80)
    private String lotNo;

    /**
     * 大清/小清/空烧
     */
//    @JSONField(name = "daxiaoqing", serialize = false)
    @Column(name = "big_or_small", length = 40)
    private String bigOrSmall;

    /**
     * 拆清操作人1
     */
//    @JSONField(name = "createusername", serialize = false)
    @Column(name = "operate_user", length = 40)
    private String operateUser;

    /**
     * 拆清操作人2
     */
    @Column(name = "operate_user2", length = 40)
    private String operateUser2;

    /**
     * 停炉时间
     */
//    @JSONField(name = "lastshutdowntime", serialize = false)
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date shutdownTime;

    /**
     * 点检开始时间
     */
//    @JSONField(name = "startcleantime", serialize = false)
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date startTime;

    /**
     * 点检完成时间
     */
//    @JSONField(name = "checktime", serialize = false)
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date operateTime;

    /**
     * 开始点检时间（废弃）
     */
//    @JSONField(name = "startchecktime", serialize = false)
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date checkTime;

    /**
     * 创建时间
     */
//    @JSONField(name = "createtime", serialize = false)
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date createTime;

    /**
     * 超时原因
     */
//    @JSONField(name = "zerenrenmark", serialize = false)
    @Column(name = "zerenren", length = 40)
    private String zerenren;

    /**
     * 班长
     */
//    @JSONField(name = "banzhangmark", serialize = false)
    @Column(name = "banzhang", length = 40)
    private String banzhang;

    /**
     * 拉晶操作人
     */
//    @JSONField(name = "lajingmark", serialize = false)
    @Column(name = "lajing", length = 40)
    private String lajing;

    /**
     * 管道操作
     */
//    @JSONField(name = "lajingzuzhangmark", serialize = false)
    @Column(name = "zuzhang", length = 40)
    private String zuzhang;

    /**
     * 工序长
     */
//    @JSONField(name = "gongxuzhangmark", serialize = false)
    @Column(name = "gongxuzhang", length = 40)
    private String gongxuzhang;

    /**
     * 点检结果
     */
//    @JSONField(name = "results", serialize = false)
    @Column(name = "results")
    private String results;

    /**
     * 超时时长
     */
    @Column(name = "over_time")
    private BigDecimal overTime;

    /**
     * 拆清开始时间
     */
    @Column(name = "dismantle_start_time")
    private Date dismantleStartTime;

    /**
     * 拆清结束时间
     */
    @Column(name = "dismantle_end_time")
    private Date dismantleEndTime;

    /**
     * 拆清耗时
     */
    @Column(name = "dismantle_consume")
    private BigDecimal dismantleConsume;

    /**
     * 备注
     * 正常、退单，默认正常
     */
    @Column(length = 40)
    private String remark;

    public static String REMARK = "退单";

    /**
     * 转单时间
     */
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date transferTime;

    /**
     * 捅管道开始时间
     */
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date pokeStartTime;

    /**
     * 捅管道结束时间
     */
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date pokeEndTime;

    /**
     * 捅管管道操作人
     */
    @Column(length = 50)
    private String pokeOpertor;

    /**
     * 打磨人
     */
    @Column(length = 50)
    private String polishOpertor;

    /**
     * 开始打磨时间
     */
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date polishStartTime;

    /**
     * 结束打磨时间
     */
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date polishEndTime;


}
