package com.sw.mes.yb.turnstore.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
@Table(name = "warehousing_statistics_info_yb")
@DynamicUpdate
@DynamicInsert
public class WarehousingStatisticsYb {

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

    /**
     * 晶段编号(短棒)
     */
    @Column(length = 50)
    private String sectionNo;

    /**
     * 托号
     */
    @Column(length = 255)
    private String trayNo;

    /**
     * 单晶组合
     */
    @Column(length = 255)
    private String sectionCompose;

    /**
     * 拉晶车间
     */
    @Column(length=50)
    private String crystalWorkshop;

    /**
     * 炉台号
     */
    @Column(length=50)
    private String deviceNo;

    /**
     * 工厂
     */
    @Column(length=100)
    private String factory;

    /**
     * 系列
     */
    @Column(length=50)
    private String series;

    /**
     * 圆棒规格
     */
    @Column(length = 16)
    private String productTypeSecond;

    /**
     * 导电型号
     */
    @Column(length = 10)
    private String conductiveType;

    /**
     * 订单号
     */
    @Column(length=150)
    private String orderNo;

    /**
     * 料号
     */
    @Column(length=150)
    private String materialCode;

    /**
     * 订单类型（1:量产；2:试验；3:送样;4:返工）
     */
    @Column(length=11)
    private String orderType;

    /**
     * 产品等级
     */
    @Column(length=80)
    private String productLevel;

    /**
     * 实验等级
     */
    @Column(length=150)
    private String productLevelExperiment;

    /**
     * 计划订单号
     */
    @Column(length=150)
    private String planOrderNo;

    // 计划订单类型
    @Column(length = 8)
    private String planOrderType;

    /**
     * 计划物料编码
     */
    @Column(length=50)
    private String planMaterialCode;

    // 计划产品等级
    @Column(length = 50)
    private String planGrade;

    // 计划导电型号
    @Column(length = 8)
    private String planConductiveType;

    // 计划拼数
    @Column(length = 20)
    private String planStickCount;

    /**
     * 计划规格
     */
    @Column(length=50)
    private String planSpecs;

    // 计划长度范围
    @Column(length = 20)
    private String planLenRange;

    // 计划掺杂剂
    @Column(length = 20)
    private String planDopant;

    /**
     * 去向
     */
    @Column(length = 40)
    private String hasGone;

    /**
     * 库别【0-正常；1-直径不良单晶；2-退料；】
     */
    @Column(length=20)
    private String kube;

    /**
     * 复检类别
     */
    @Column(length=40)
    private String reCheckType;

    /**
     * 状态【0：默认，待确认；1：已接收；3: 拒收;】
     */
    @Column(length = 10)
    private Integer state;

    /**
     * 操作人
     */
    @Column(length = 80)
    private String user;

    /**
     * 操作时间
     */
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date operationTime;


    /**
     * 确认时间
     */
    @Column(length = 19)
    @Temporal(TemporalType.TIMESTAMP)
    private Date confirmTime;

    /**
     * 确认人
     */
    @Column(length = 19)
    private String confirmUser;

    /**
     * 入库长度
     */
    @Column(length = 19)
    private BigDecimal wareHouseLength;

    /**
     * 理论重量
     */
    @Column(length = 19)
    private BigDecimal theoryWeight;

    /**
     * 圆棒长度(mm)
     */
    @Column(length = 19)
    private BigDecimal actualLength;

    /**
     * 单晶减长长度
     */
    @Column(length=19)
    private BigDecimal reduceCrystalLength;

    /**
     * 圆棒称重
     */
    @Column(length=19)
    private BigDecimal actualWeight;

    /**
     * 直径Min
     */
    @Column(length=19)
    private BigDecimal diameterMin;

    /**
     * 直径Max
     */
    @Column(length=19)
    private BigDecimal diameterMax;


    /**
     * 细总长
     */
    @Column(length = 19)
    private BigDecimal fineDiameter;

    /**
     * 细减长(mm)
     */
    @Column(length = 19)
    private BigDecimal fineCutLength;

    /**
     * 崩边长度
     */
    @Column(length = 19)
    private BigDecimal edgeBark;

    /**
     * 崩晶线
     */
    @Column(length = 19)
    private BigDecimal collapseLine;

    /**
     * 直径判定
     */
    @Column(length=80)
    private String diamDecide;

    /**
     * 异常汇总
     */
    @Column(length=150)
    private String anomaly;


    // 直径差
    @Column(length = 8)
    private String demcMax;
}
