package cn.estsh.i3plus.pojo.wms.bean;

import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.annotations.ColumnDefault;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * @Description : 质检单操作明细信息
 * @Reference :
 * @Author : silliter.yuan
 * @CreateDate : 2018-11-06 15:58
 * @Modify:
 **/
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Table(name="WMS_QC_TRANS")
@Api("质检单操作明细信息")
public class WmsQCTrans extends BaseBean {

    private static final long serialVersionUID = 7779401323803118985L;
    @Column(name="ORDER_NO")
    @ApiParam("单号")
    public String orderNo;

    @Column(name="ITEM")
    @ApiParam("行号")
    public String item;

    /**
     * 状态:1=创建,10=已处理
     */
    @Column(name="ITEM_STATUS")
    @ApiParam(value = "状态", example = "1")
    public Integer itemStatus;

    @Column(name="REMARK")
    @ApiParam("备注")
    public String remark;

    @Column(name="PASS_QTY", nullable = false)
    @ApiParam("合格数量")
    @ColumnDefault("0")
    public double passQty;

    @Column(name="REJECT_QTY", nullable = false)
    @ApiParam("不合格数量")
    @ColumnDefault("0")
    public double rejectQty;

    @Column(name="UNIT")
    @ApiParam("单位")
    public String unit;

    @Column(name="PART_NO")
    @ApiParam("物料编码")
    public String partNo;

    @Column(name="PART_NAME_RDD")
    @ApiParam("物料名称")
    public String partNameRdd;

    @Column(name="SN")
    @ApiParam("条码")
    public String sn;

    @Column(name = "QC_USER")
    @ApiParam("检验员")
    public String qcUser;

    @Column(name = "QC_TIME")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @ApiParam(value = "检验时间", example = "2000-01-01 01:00:00")
    public String qcTime;

    @Column(name = "VENDOR_NO")
    @ApiParam(value = "供应商编码")
    public String vendorNo;
}
