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

import cn.estsh.i3plus.pojo.base.annotation.DynamicField;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

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

/**
 * @Description : 道口预约信息
 * @Reference :
 * @Author : jason.niu
 * @CreateDate : 2020-03-29
 * @Modify:
 **/
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Table(name="WMS_DOCK_ORDER_INFO")
@Api("道口预约信息")
public class WmsDockOrderInfo extends BaseBean {

    private static final long serialVersionUID = -18500387985953214L;
    @Column(name="DOCK_CODE")
    @ApiParam("道口代码")
    @DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.TEXT)
    private String dockCode;

    @Column(name="ORDER_DATE")
    @ApiParam("预约日期")
    @DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.DATETIME)
    private String orderDate;

    @Column(name="WINDOW_TIME")
    @ApiParam("窗口时间")
    @DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.DATETIME)
    private String windowTime;

    @Column(name="ORDER_STATUS")
    @ApiParam("预约状态")
    @DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.SELECT, dataSrc = "DOCK_ORDER_STATUS")
    private Integer orderStatus;

    @Column(name="SUPPLIER_CODE")
    @ApiParam("供应商编码")
    @DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.TEXT)
    private String supplierCode;

    @Column(name="CAR_NO")
    @ApiParam("车辆编号")
    @DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.TEXT, isRequire = 2)
    private String carNo;

    @Column(name="DRIVER_NAME")
    @ApiParam("驾驶员")
    @DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.TEXT, isRequire = 2)
    private String driverName;

    @Column(name="ORDER_NO")
    @ApiParam("单据号")
    @DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.TEXT)
    private String orderNo;

    @Transient
    @ApiParam("驾驶员编码")
    private String driverNo;

    @Transient
    @ApiParam("库位代码")
    private Integer masterStatus;
}
