diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/iotio/SwebProcurementPlanOrder.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/SwebProcurementPlanOrder.java similarity index 89% rename from modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/iotio/SwebProcurementPlanOrder.java rename to modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/SwebProcurementPlanOrder.java index 1b43c58..34116e8 100644 --- a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/iotio/SwebProcurementPlanOrder.java +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/SwebProcurementPlanOrder.java @@ -1,4 +1,4 @@ -package cn.estsh.i3plus.pojo.wms.bean.iotio; +package cn.estsh.i3plus.pojo.wms.bean; import cn.estsh.i3plus.pojo.base.bean.BaseBean; import io.swagger.annotations.Api; @@ -49,4 +49,8 @@ public class SwebProcurementPlanOrder extends BaseBean { @ApiParam(value = "物料名称") private String partName; + @Column(name = "CONSIGNMENT") + @ApiParam(value = "是否寄售") + private Integer consignment; + } diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/WmsPart.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/WmsPart.java index 1c1dbdc..20705ab 100644 --- a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/WmsPart.java +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/WmsPart.java @@ -143,6 +143,10 @@ public class WmsPart extends BaseBean { @ApiParam("结算供应商") private String outCloseVendor; + @Column(name = "QUALITY_DAYS") + @ApiParam("保质期天数") + private Integer qualityDays; + @Transient @ApiParam("总数量") private Double qty; diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsCheckPoint.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsCheckPoint.java new file mode 100644 index 0000000..738ffbc --- /dev/null +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsCheckPoint.java @@ -0,0 +1,27 @@ +package cn.estsh.i3plus.pojo.wms.bean.snapshot; + +import cn.estsh.i3plus.pojo.base.bean.BaseBean; +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; + +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Table(name="WMS_CHECK_POINT") +public class WmsCheckPoint extends BaseBean { + + private static final long serialVersionUID = 5589497687871639189L; + + @Column(name="SNAPSHOT_TIME") + @ApiParam("快照时间") + public String snapshotTime; +} diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveDetailsSnapshot.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveDetailsSnapshot.java new file mode 100644 index 0000000..01b8aa1 --- /dev/null +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveDetailsSnapshot.java @@ -0,0 +1,268 @@ +package cn.estsh.i3plus.pojo.wms.bean.snapshot; + +import cn.estsh.i3plus.pojo.base.annotation.AnnoOutputColumn; +import cn.estsh.i3plus.pojo.base.bean.BaseBean; +import cn.estsh.i3plus.pojo.base.enumutil.WmsEnumUtil; +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.*; + +/** + * @Description : 库存移动单明细信息 + * @Reference : + * @Author : silliter.yuan + * @CreateDate : 2018-11-06 15:58 + * @Modify: + **/ +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Table(name="WMS_MOVE_DETAILS_SNAPSHOT", indexes = { + @Index(columnList = "PART_NO"), + @Index(columnList = "ORDER_NO"), + @Index(columnList = "ORGANIZE_CODE"), + @Index(columnList = "SNAPSHOT_TIME") +}) +@Api("库存移动单明细信息") +public class WmsMoveDetailsSnapshot extends BaseBean { + + private static final long serialVersionUID = -4095410692227226944L; + + @Column(name="SNAPSHOT_TIME") + @ApiParam("快照时间") + public String snapshotTime; + + @Column(name="ORDER_NO") + @ApiParam("单号") + public String orderNo; + + @Column(name="ITEM") + @ApiParam(value = "行号", example = "0") + public Integer item; + + @Column(name="PART_NO") + @ApiParam("物料编码") + public String partNo; + + @Column(name="PART_NAME_RDD") + @ApiParam("物料名称") + public String partNameRdd; + + @Column(name="VENDOR_NO") + @ApiParam("供应商编号") + public String vendorNo; + + @Column(name="CUST_NO") + @ApiParam("客户编号") + public String custNo; + + @Column(name="TRANS_QTY") + @ApiParam(value = "处理数量", example = "0") + public Double transQty; + + public Double getTransQty(){ + return this.transQty == null ? 0 : this.transQty.doubleValue(); + } + + @Column(name="REJECT_QTY") + @ApiParam(value = "不合格处理数量", example = "0") + public Double rejectQty; + + public Double getRejectQty(){ + return this.rejectQty == null ? 0 : this.rejectQty.doubleValue(); + } + + @Column(name="UNIT") + @ApiParam("单位") + public String unit; + + @Column(name="SRC_WH_NO") + @ApiParam("源仓库代码") + public String srcWhNo; + + @Column(name="SRC_ZONE_NO") + @ApiParam("源存储区代码") + public String srcZoneNo; + + @Column(name="SRC_LOCATE_NO") + @ApiParam("源库位代码") + public String srcLocateNo; + + @Column(name="DEST_WH_NO") + @ApiParam("目标仓库代码") + public String destWhNo; + + @Column(name="DEST_ZONE_NO") + @ApiParam("目标存储区代码") + public String destZoneNo; + + @Column(name="DEST_LOCATE_NO") + @ApiParam("目标库位代码") + public String destLocateNo; + + /** + * 状态:1=创建,10=待处理,20=已处理 + */ + @Column(name="ITEM_STATUS") + @ApiParam(value = "状态", example = "0") + @AnnoOutputColumn(refClass = WmsEnumUtil.MOVE_ORDER_STATUS.class,refForeignKey = "value",value = "description") + public Integer itemStatus; + + @Column(name="REF_ITEM") + @ApiParam("关联单据行号") + public String refItem; + + /** + * ASN,PO,SO + */ + @Column(name="REF_TYPE") + @ApiParam("关联单据类型") + public String refType; + + @Column(name="REF_SRC") + @ApiParam("关联单号") + public String refSrc; + + @ApiParam(value = "待出库数量", example = "0") + @Transient + private Long waitingCounts; + + @ApiParam(value = "已出库数量", example = "0") + @Transient + private Long finishedCounts; + + @Transient + @ApiParam("交易类型") + private String transTypeCode; + + @Transient + @ApiParam("erp库存地") + private String ZoneNo; + + @Transient + @ApiParam("条码") + private String sn; + + @Transient + @ApiParam("交易类型名称") + private String transTypeName; + + @Transient + @ApiParam("业务类型编码") + @AnnoOutputColumn(refClass = WmsEnumUtil.OUT_MOVEMENT_BUSI_TYPE.class,refForeignKey = "value",value = "description") + private Integer busiTypeCode; + + @Transient + @ApiParam("生产线") + private String workCenterCode; + + @Transient + @ApiParam("父物料编码") + private String fpartNo; + + @Transient + @ApiParam("父物料名称") + private String fpartName; + + @Transient + @ApiParam("数量") + private Double qty; + + @Transient + @ApiParam("创建时间") + private String createDateTime; + + @Version + @Column(name = "LOCK_VERSION") + @ApiParam(value = "乐观锁", example = "1") + public transient Integer lockVersion; + /* @JSONField(name="fPartNo") + public String getfPartNo() { + return fPartNo; + } + + @JSONField(name="fPartName") + public String getfPartName() { + return fPartName; + }*/ + + public WmsMoveDetailsSnapshot(){} + + public WmsMoveDetailsSnapshot(String partNo, Long waitingCounts , Long finishedCounts){ + this.partNo = partNo; + this.waitingCounts = waitingCounts; + this.finishedCounts = finishedCounts; + } + + public WmsMoveDetailsSnapshot(String partNo, double transQty){ + this.partNo = partNo; + this.transQty = transQty; + } + + public WmsMoveDetailsSnapshot(String orderNo){ + this.orderNo = orderNo; + } + + public Long getWaitingCounts() { + return waitingCounts == null ? 0L : this.waitingCounts; + } + + public Long getFinishedCounts() { + return finishedCounts == null ? 0L : this.finishedCounts; + } + + public WmsMoveDetailsSnapshot(String organizeCode, String partNo, String partNameRdd, String workCenterCode, String fPartNo, String fPartName, String unit, Double qty, + String createDateTime, String sn, String srcZoneNo){ + this.organizeCode = organizeCode; + this.partNo = partNo; + this.partNameRdd = partNameRdd; + this.workCenterCode = workCenterCode; + this.fpartNo = fPartNo; + this.fpartName = fPartName; + this.unit = unit; + this.qty = qty; + this.createDateTime = createDateTime; + this.sn = sn; + this.srcZoneNo = srcZoneNo; + + } + + public WmsMoveDetailsSnapshot(String organizeCode, String orderNo, Integer item, String partNo, String partNameRdd, String transTypeCode + , String transTypeName, Integer itemStatus, String unit, String srcWhNo, String destWhNo, + String srcZoneNo, String destZoneNo, String srcLocateNo, String destLocateNo, + Double transQty, Double rejectQty, String refSrc, String vendorNo, String custNo, Integer busiTypeCode, + String createUser, String createDatetime, String modifyUser, String modifyDatetime){ + this.organizeCode = organizeCode; + this.partNo = partNo; + this.orderNo = orderNo; + this.item = item; + this.partNameRdd = partNameRdd; + this.transTypeCode = transTypeCode; + this.transTypeName = transTypeName; + this.itemStatus = itemStatus; + this.unit = unit; + this.srcWhNo = srcWhNo; + this.destWhNo = destWhNo; + this.srcZoneNo = srcZoneNo; + this.destZoneNo = destZoneNo; + this.srcLocateNo = srcLocateNo; + this.destLocateNo = destLocateNo; + this.transQty = transQty; + this.rejectQty = rejectQty; + this.refSrc = refSrc; + this.vendorNo = vendorNo; + this.custNo = custNo; + this.busiTypeCode = busiTypeCode; + this.createUser = createUser; + this.createDatetime = createDatetime; + this.modifyDatetime =modifyDatetime; + this.modifyUser =modifyUser; + } +} diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveMasterSnapshot.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveMasterSnapshot.java new file mode 100644 index 0000000..06890f3 --- /dev/null +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveMasterSnapshot.java @@ -0,0 +1,209 @@ +package cn.estsh.i3plus.pojo.wms.bean.snapshot; + +import cn.estsh.i3plus.pojo.base.annotation.AnnoOutputColumn; +import cn.estsh.i3plus.pojo.base.bean.BaseBean; +import cn.estsh.i3plus.pojo.base.enumutil.WmsEnumUtil; +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.*; + +/** + * @Description : 库存移动单主表信息 + * @Reference : + * @Author : silliter.yuan + * @CreateDate : 2018-11-06 15:58 + * @Modify: + **/ +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Table(name = "WMS_MOVE_MASTER_SNAPSHOT", indexes = { + @Index(columnList = "TRANS_TYPE_CODE"), + @Index(columnList = "ORDER_NO"), + @Index(columnList = "ORGANIZE_CODE"), + @Index(columnList = "SNAPSHOT_TIME") +}) +@Api("库存移动单主表信息") +public class WmsMoveMasterSnapshot extends BaseBean { + + private static final long serialVersionUID = 3569874772643448726L; + + @Column(name="SNAPSHOT_TIME") + @ApiParam("快照时间") + public String snapshotTime; + + @Column(name = "ORDER_NO") + @ApiParam("单号") + public String orderNo; + + /** + * 状态:1=创建,10=待处理,20=已处理 + */ + @Column(name = "ORDER_STATUS") + @ApiParam(value = "状态", example = "0") + @AnnoOutputColumn(refClass = WmsEnumUtil.MOVE_ORDER_STATUS.class,refForeignKey = "value",value = "description") + public Integer orderStatus; + + @Column(name = "REMARK") + @ApiParam("备注") + public String remark; + + @Column(name = "TRANS_TYPE_CODE") + @ApiParam(value = "交易类型代码") + private String transTypeCode; + + @Lob + @Column(name = "ERROR_MESSAGE") + @ApiParam(value = "错误信息") + private String errorMessage; + + @Column(name="IS_URGENT") + @ApiParam(value = "是否紧急", example = "0") + public Integer isUrgent; + + @Column(name = "CAR_NO") + @ApiParam(value = "车牌号") + private String carNo; + + @Column(name = "BUSI_TYPE_CODE") + @ApiParam(value = "业务类型编码") + @AnnoOutputColumn(refClass = WmsEnumUtil.OUT_MOVEMENT_BUSI_TYPE.class,refForeignKey = "value",value = "description") + private Integer busiTypeCode; + + @Column(name = "REF_ORDER_NO") + @ApiParam("关联移动单号") + public String refOrderNo; + + @Transient + @ApiParam("物料编码") + private String partNo; + + @Transient + @ApiParam("状态") + @AnnoOutputColumn(refClass = WmsEnumUtil.MOVE_ORDER_STATUS.class,refForeignKey = "value",value = "description") + private Integer itemStatus; + + @Transient + @ApiParam("erp库存地") + private String ZoneNo; + + @Transient + @ApiParam("关联单号") + private String refSrc; + + @Transient + @ApiParam("目标仓库") + private String destWhNo; + + @Transient + @ApiParam("存储区") + private String destZoneNo; + + @Transient + @ApiParam("供应商编码") + private String vendorNo; + + @Transient + @ApiParam("条码") + private String sn; + + @Transient + @ApiParam("物料名称") + private String partNameRdd; + + @Transient + @ApiParam("单位") + private String unit; + + @Transient + @ApiParam("源仓库") + private String srcWhNo; + + @Transient + @ApiParam("源存储区代码") + private String srcZoneNo; + + @Transient + @ApiParam("处理数量") + private Double transQty; + + @Transient + @ApiParam("不合格处理数量") + private Double rejectQty; + + @Transient + @ApiParam("库位") + private String destLocateNo; + + @Transient + @ApiParam("交易类型名称") + private String transTypeName; + + @Column(name="FIX_ID") + @ApiParam(value = "设备编号") + public String fixId; + + @Version + @Column(name = "LOCK_VERSION") + @ApiParam(value = "乐观锁", example = "1") + public transient Integer lockVersion; + + public WmsMoveMasterSnapshot(){}; + + public WmsMoveMasterSnapshot(String orderNo, Integer orderStatus, String transTypeCode, String errorMessage, + Integer isUrgent, String carNo, Integer busiTypeCode, String refOrderNo, String refSrc, String partNo, Integer itemStatus, String remark, + String organizeCode, String createDatetime, String createUser, String modifyDatetime, String modifyUser, String fixId) { + this.orderNo = orderNo; + this.orderStatus = orderStatus; + this.remark = remark; + this.isUrgent=isUrgent; + this.transTypeCode = transTypeCode; + this.errorMessage = errorMessage; + this.busiTypeCode = busiTypeCode; + this.partNo = partNo; + this.itemStatus = itemStatus; + this.refOrderNo = refOrderNo; + this.carNo = carNo; + this.refSrc = refSrc; + this.organizeCode =organizeCode; + this.createDatetime= createDatetime; + this.createUser = createUser; + this.modifyDatetime =modifyDatetime; + this.modifyUser =modifyUser; + this.fixId = fixId; + } + + public WmsMoveMasterSnapshot(Long id, String orderNo, String organizeCode, String partNo, String partNameRdd, String transTypeCode, String transTypeName, Integer itemStatus, + String unit, String srcWhNo, String srcZoneNo, String destWhNo, String destZoneNo, Double transQty, Double rejectQty, String fixId, Integer busiTypeCode, String refSrc, + String createDatetime, String createUser, String modifyUser, String modifyDatetime) { + this.id = id; + this.orderNo = orderNo; + this.organizeCode = organizeCode; + this.partNo = partNo; + this.partNameRdd = partNameRdd; + this.transTypeCode = transTypeCode; + this.transTypeName = transTypeName; + this.itemStatus = itemStatus; + this.unit = unit; + this.srcWhNo = srcWhNo; + this.srcZoneNo = srcZoneNo; + this.destWhNo = destWhNo; + this.destZoneNo = destZoneNo; + this.transQty = transQty; + this.rejectQty = rejectQty; + this.fixId = fixId; + this.busiTypeCode = busiTypeCode; + this.refSrc = refSrc; + this.createDatetime= createDatetime; + this.createUser = createUser; + this.modifyUser =modifyUser; + this.modifyDatetime =modifyDatetime; + } +} diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveSnSnapshot.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveSnSnapshot.java new file mode 100644 index 0000000..6f781aa --- /dev/null +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsMoveSnSnapshot.java @@ -0,0 +1,265 @@ +package cn.estsh.i3plus.pojo.wms.bean.snapshot; + +import cn.estsh.i3plus.pojo.base.annotation.AnnoOutputColumn; +import cn.estsh.i3plus.pojo.base.bean.BaseBean; +import cn.estsh.i3plus.pojo.base.enumutil.WmsEnumUtil; +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.*; + +/** + * @Description : 库存移动单条码信息 + * @Reference : + * @Author : silliter.yuan + * @CreateDate : 2018-11-06 15:58 + * @Modify: + **/ +@Data +@Entity +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Table(name = "WMS_MOVE_SN_SNAPSHOT", indexes = { + @Index(columnList = "PART_NO"), + @Index(columnList = "ORDER_NO"), + @Index(columnList = "SN"), + @Index(columnList = "ORGANIZE_CODE"), + @Index(columnList = "SNAPSHOT_TIME") +}) +@Api("库存移动单条码信息") +public class WmsMoveSnSnapshot extends BaseBean { + + private static final long serialVersionUID = 2588101374261238353L; + + @Column(name="SNAPSHOT_TIME") + @ApiParam("快照时间") + public String snapshotTime; + + @Column(name = "ORDER_NO") + @ApiParam("单号") + public String orderNo; + + @Column(name = "ITEM") + @ApiParam("行号") + public Integer item; + + @Column(name = "PART_NO") + @ApiParam("物料编码") + public String partNo; + + @Column(name = "PART_NAME_RDD") + @ApiParam("物料名称") + public String partNameRdd; + + @Column(name = "UNIT") + @ApiParam(value = "单位") + public String unit; + + @Column(name = "SN") + @ApiParam("条码") + public String sn; + + @Column(name = "CSN") + @ApiParam("客户条码") + public String csn; + + /** + * 状态:1=创建,10=待处理,20=已处理 + */ + @Column(name = "ITEM_STATUS") + @ApiParam(value = "状态", example = "1") + @AnnoOutputColumn(refClass = WmsEnumUtil.MOVE_ORDER_STATUS.class, refForeignKey = "value", value = "description") + public Integer itemStatus; + + @Column(name = "REMARK") + @ApiParam("备注") + public String remark; + + @Column(name = "LOT_NO") + @ApiParam("批次编号") + public String lotNo; + + @Column(name = "PACKAGE_NO") + @ApiParam("容器编号") + public String packAgeNo; + + @Column(name = "SRC_QTY") + @ColumnDefault("0") + @ApiParam(value = "源数量", example = "0") + public Double srcQty; + + @Column(name = "SRC_WH_NO") + @ApiParam("源仓库代码") + public String srcWhNo; + + @Column(name = "SRC_ZONE_NO") + @ApiParam("源存储区代码") + public String srcZoneNo; + + @Column(name = "SRC_LOCATE_NO") + @ApiParam("源库位代码") + public String srcLocateNo; + + @Column(name = "DEST_WH_NO") + @ApiParam("目标仓库代码") + public String destWhNo; + + @Column(name = "DEST_ZONE_NO") + @ApiParam("目标存储区代码") + public String destZoneNo; + + @Column(name = "DEST_LOCATE_NO") + @ApiParam("目标库位代码") + public String destLocateNo; + + @ApiParam("待上架箱数") + @Transient + private Long waitingCounts; + + @ApiParam("已上架箱数") + @Transient + private Long finishedCounts; + + @Column(name = "DEST_QTY") + @ColumnDefault("0") + @ApiParam(value = "目标数量", example = "0") + public Double destQty; + + @Column(name = "QTY") + @ColumnDefault("0") + @ApiParam(value = "数量", example = "0") + public Double qty; + + @Column(name = "SRC_QC_STATUS") + @ApiParam(value = "源质量状态", example = "1") + @AnnoOutputColumn(refClass = WmsEnumUtil.STOCK_SN_QC_STATUS.class, refForeignKey = "value", value = "description") + public Integer srcQcStatus; + + @Column(name = "SRC_SN_STATUS") + @ApiParam(value = "源条码状态", example = "1") + @AnnoOutputColumn(refClass = WmsEnumUtil.STOCK_SN_STATUS.class, refForeignKey = "value", value = "description") + public Integer srcSnStatus; + + @Column(name = "DEST_QC_STATUS") + @ApiParam(value = "目的质量状态", example = "1") + @AnnoOutputColumn(refClass = WmsEnumUtil.STOCK_SN_QC_STATUS.class, refForeignKey = "value", value = "description") + public Integer descQcStatus; + + @Column(name = "DEST_SN_STATUS") + @ApiParam(value = "目的条码状态", example = "1") + @AnnoOutputColumn(refClass = WmsEnumUtil.STOCK_SN_STATUS.class, refForeignKey = "value", value = "description") + public Integer destSnStatus; + + @Column(name = "DATE_CODE") + @ApiParam("生产日期") + public String dateCode; + + @Column(name = "FIX_LOT_NO") + @ApiParam("特殊批次") + public String fixLotNo; + + @Column(name = "VENDOR_NO") + @ApiParam("供应商编号") + private String vendorNo; + + @Transient + @ApiParam("业务类型编码") + @AnnoOutputColumn(refClass = WmsEnumUtil.OUT_MOVEMENT_BUSI_TYPE.class, refForeignKey = "value", value = "description") + private Integer busiTypeCode; + + @Transient + @ApiParam(value = "交易类型代码") + private String transTypeCode; + + @Transient + @ApiParam("关联单号") + public String refSrc; + + @Transient + @ApiParam("erp库存地") + private String ZoneNo; + + @Transient + @ApiParam("交易类型名称") + private String transTypeName; + + @Version + @Column(name = "LOCK_VERSION") + @ApiParam(value = "乐观锁", example = "1") + public transient Integer lockVersion; + + public WmsMoveSnSnapshot() { + } + + public WmsMoveSnSnapshot(String partNo, Long finishedCounts, Long waitingCounts) { + this.partNo = partNo; + this.waitingCounts = waitingCounts; + this.finishedCounts = finishedCounts; + } + + public Long getWaitingCounts() { + return waitingCounts == null ? 0L : this.waitingCounts; + } + + public Long getFinishedCounts() { + return finishedCounts == null ? 0L : this.finishedCounts; + } + + public WmsMoveSnSnapshot(String partNo, String partNameRdd, Double destQty, Integer busiTypeCode, String transTypeCode, String refSrc) { + this.partNo = partNo; + this.partNameRdd = partNameRdd; + this.destQty = destQty; + this.busiTypeCode = busiTypeCode; + this.transTypeCode = transTypeCode; + this.refSrc = refSrc; + } + + public WmsMoveSnSnapshot(String partNo, String partNameRdd, Double destQty, String transTypeCode, String refSrc) { + this.partNo = partNo; + this.partNameRdd = partNameRdd; + this.destQty = destQty; + this.transTypeCode = transTypeCode; + this.refSrc = refSrc; + } + + public WmsMoveSnSnapshot(String organizeCode, String orderNo, Integer item, String partNo, String partNameRdd, + String transTypeCode, String transTypeName, Integer itemStatus, String unit, String srcLocateNo, String destLocateNo, Double srcQty, Double destQty, Integer srcQcStatus, Integer descQcStatus, Integer srcSnStatus, + Integer destSnStatus, String lotNo, String dateCode, String refSrc, String destZoneNo, String destWhNo, Integer busiTypeCode, String sn, + String createUser, String createDatetime, String modifyDatetime, String modifyUser) { + this.organizeCode = organizeCode; + this.orderNo = orderNo; + this.item = item; + this.partNo = partNo; + this.partNameRdd = partNameRdd; + this.transTypeCode = transTypeCode; + this.transTypeName = transTypeName; + this.itemStatus = itemStatus; + this.unit = unit; + this.srcLocateNo = srcLocateNo; + this.destLocateNo = destLocateNo; + this.srcQty = srcQty; + this.srcQty = srcQty; + this.destQty = destQty; + this.srcQcStatus = srcQcStatus; + this.descQcStatus = descQcStatus; + this.srcSnStatus = srcSnStatus; + this.destSnStatus = destSnStatus; + this.lotNo = lotNo; + this.dateCode = dateCode; + this.refSrc = refSrc; + this.destZoneNo = destZoneNo; + this.destWhNo = destWhNo; + this.busiTypeCode = busiTypeCode; + this.sn = sn; + this.createUser = createUser; + this.createDatetime = createDatetime; + this.modifyDatetime = modifyDatetime; + this.modifyUser = modifyUser; + } +} diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsStockQuanSnapshot.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsStockQuanSnapshot.java new file mode 100644 index 0000000..dddfab4 --- /dev/null +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsStockQuanSnapshot.java @@ -0,0 +1,292 @@ +package cn.estsh.i3plus.pojo.wms.bean.snapshot; + +import cn.estsh.i3plus.pojo.base.bean.BaseBean; +import cn.estsh.i3plus.pojo.wms.bean.WmsLocate; +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.*; +import java.util.List; + +/** + * @Description : 库存信息 + * @Reference : + * @Author : jessica.chen + * @CreateDate : 2018-11-02 11:06 + * @Modify: + **/ +@Data +@Entity +@Table(name = "WMS_STOCK_QUAN_SNAPSHOT", indexes = { + @Index(columnList = "WH_NO"), + @Index(columnList = "ZONE_NO"), + @Index(columnList = "LOCATE_NO"), + @Index(columnList = "ORGANIZE_CODE"), + @Index(columnList = "SNAPSHOT_TIME") +}) +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Api(value = "库存信息", description = "库存信息") +public class WmsStockQuanSnapshot extends BaseBean { + + private static final long serialVersionUID = 8335719859185712904L; + + @Column(name="SNAPSHOT_TIME") + @ApiParam("快照时间") + public String snapshotTime; + + @Column(name = "WH_NO") + @ApiParam(value = "仓库代码") + private String whNo; + + @Column(name = "ZONE_NO") + @ApiParam(value = "存储区编号") + private String zoneNo; + + @Column(name = "LOCATE_NO") + @ApiParam(value = "库位代码") + private String locateNo; + + @Column(name = "PART_NO") + @ApiParam(value = "物料编号") + private String partNo; + + @Column(name = "PART_NAME_RDD") + @ApiParam(value = "物料名称") + private String partNameRdd; + + @Column(name = "UNIT") + @ApiParam("单位") + public String unit; + + @Column(name = "CUST_NO") + @ApiParam(value = "客户编码") + private String custNo; + + @Transient + @ApiParam(value = "项目代码") + private String prodCfgTypeCode; + + @Transient + @ApiParam(value = "含0库存显示") + private Boolean includeZeroStock = false; + + @Transient + @ColumnDefault("0") + @ApiParam(value = "库存数量总和") + private Double sumQty; + + @Transient + @ApiParam(value = "库位信息") + private WmsLocate wmsLocate; + + + @Column(name = "QTY") + @ColumnDefault("0") + @ApiParam(value = "可用数量", example = "0") + public Double qty; + + @Column(name = "FAIL_QTY") + @ColumnDefault("0") + @ApiParam(value = "不合格数量", example = "0") + private Double failQty; + + @Column(name = "HOLD_QTY") + @ColumnDefault("0") + @ApiParam(value = "隔离数量", example = "0") + private Double holdQty; + + @Column(name = "QC_QTY") + @ColumnDefault("0") + @ApiParam(value = "质检中数量", example = "0") + private Double qcQty; + + @Column(name = "RIN_QTY") + @ColumnDefault("0") + @ApiParam(value = "待入库数量", example = "0") + private Double rinQty; + + @Column(name = "FREEZE_QTY") + @ColumnDefault("0") + @ApiParam(value = "冻结数量", example = "0") + private Double freezeQty; + + @Column(name = "CONSIGN_QTY") + @ColumnDefault("0") + @ApiParam(value = "寄售数量", example = "0") + private Double consignQty; + + @Column(name = "LOCK_QTY") + @ColumnDefault("0") + @ApiParam(value = "锁定数量", example = "0") + private Double lockQty; + + @Column(name = "SCRAP_QTY") + @ColumnDefault("0") + @ApiParam(value = "报废数量", example = "0") + private Double scrapQty; + + @Transient + @ApiParam(value = "总数量") + private Double totalQty; + + @Transient + @ApiParam(value = "项目名称") + private String prodCfgTypeName; + + @Transient + @ApiParam(value = "箱数", example = "-1") + private Integer boxQty; + + @Transient + @ApiParam(value = "零件数", example = "-1") + private Double partQty; + + @Transient + @ApiParam(value = "ERP库存地") + private String areaNo; + + @Transient + @ApiParam(value = "存储区集合") + private List zoneList; + + @Transient + @ApiParam(value = "移动单条码集合") + private List wmsMoveSnList; + + + public String getAreaNo() { + return areaNo; + } + + public Double getQtyVal() { + return this.qty == null ? 0 : this.qty; + } + + public Double getFailQtyVal() { + return this.failQty == null ? 0 : this.failQty; + } + + public Double getHoldQtyVal() { + return this.holdQty == null ? 0 : this.holdQty; + } + + public Double getQcQtyVal() { + return this.qcQty == null ? 0 : this.qcQty; + } + + public Double getRinQtyVal() { + return this.rinQty == null ? 0 : this.rinQty; + } + + public Double getFreezeQtyVal() { + return this.freezeQty == null ? 0 : this.freezeQty; + } + + public Double getConsignQtyVal() { + return this.consignQty == null ? 0 : this.consignQty; + } + + public Double getLockQtyVal() { + return this.lockQty == null ? 0 : this.lockQty; + } + + public Double getScrapQtyVal() { + return this.scrapQty == null ? 0 : this.scrapQty; + } + + public Double getTotalVal() { + return this.totalQty == null ? 0 : this.totalQty; + } + + public Double getPartQtyVal() { + return this.partQty == null ? 0 : this.partQty; + } + + public Integer getBoxQtyVal() { + return this.boxQty == null ? 0 : this.boxQty; + } + + public WmsStockQuanSnapshot() { + } + + public WmsStockQuanSnapshot(String whNo, String zoneNo, String unit, String partNo, String partName, + Double qty, Double failQty, Double holdQty, Double qcQty, Double rinQty, Double freezeQty, + Double consignQty, Double lockQty, Double sumQty, String prodCfgTypeCode, String prodCfgTypeName, Double scrapQty) { + this.whNo = whNo; + this.zoneNo = zoneNo; + this.partNo = partNo; + this.partNameRdd = partName; + this.unit = unit; + this.qty = qty; + this.failQty = failQty; + this.holdQty = holdQty; + this.qcQty = qcQty; + this.rinQty = rinQty; + this.freezeQty = freezeQty; + this.consignQty = consignQty; + this.lockQty = lockQty; + this.prodCfgTypeCode = prodCfgTypeCode; + this.prodCfgTypeName = prodCfgTypeName; + this.scrapQty = scrapQty; + } + + public WmsStockQuanSnapshot(Double qty, Double failQty, Double holdQty, Double qcQty, Double rinQty, Double freezeQty, Double consignQty, Double lockQty, Double scrapQty) { + this.qty = qty; + this.failQty = failQty; + this.holdQty = holdQty; + this.qcQty = qcQty; + this.rinQty = rinQty; + this.freezeQty = freezeQty; + this.consignQty = consignQty; + this.lockQty = lockQty; + this.scrapQty = scrapQty; + } + + public WmsStockQuanSnapshot(String locateNo, Integer boxQty, Double partQty, String partNo, String partNameRdd, String unit, + Double sumQty, Double qty, Double failQty, Double holdQty, Double qcQty, Double rinQty, Double freezeQty, Double consignQty, Double lockQty, Double scrapQty) { + this.locateNo = locateNo; + this.boxQty = boxQty; + this.partQty = partQty; + this.partNo = partNo; + this.partNameRdd = partNameRdd; + this.unit = unit; + this.sumQty = sumQty; + this.qty = qty; + this.failQty = failQty; + this.holdQty = holdQty; + this.qcQty = qcQty; + this.rinQty = rinQty; + this.freezeQty = freezeQty; + this.consignQty = consignQty; + this.lockQty = lockQty; + this.scrapQty = scrapQty; + } + + public WmsStockQuanSnapshot(String whNo, String zoneNo, String locateNo, Integer boxQty, Double partQty, String partNo, String partNameRdd, String unit, + Double qty, Double failQty, Double holdQty, Double qcQty, Double rinQty, Double freezeQty, Double consignQty, Double lockQty, Double scrapQty) { + this.whNo = whNo; + this.zoneNo = zoneNo; + this.locateNo = locateNo; + this.boxQty = boxQty; + this.partQty = partQty; + this.partNo = partNo; + this.partNameRdd = partNameRdd; + this.unit = unit; + this.qty = qty; + this.failQty = failQty; + this.holdQty = holdQty; + this.qcQty = qcQty; + this.rinQty = rinQty; + this.freezeQty = freezeQty; + this.consignQty = consignQty; + this.lockQty = lockQty; + this.scrapQty = scrapQty; + } +} diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsStockSnSnapshot.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsStockSnSnapshot.java new file mode 100644 index 0000000..436d126 --- /dev/null +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/bean/snapshot/WmsStockSnSnapshot.java @@ -0,0 +1,268 @@ +package cn.estsh.i3plus.pojo.wms.bean.snapshot; + +import cn.estsh.i3plus.pojo.base.annotation.AnnoOutputColumn; +import cn.estsh.i3plus.pojo.base.bean.BaseBean; +import cn.estsh.i3plus.pojo.base.enumutil.WmsEnumUtil; +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 org.springframework.format.annotation.DateTimeFormat; + +import javax.persistence.*; +import java.util.Date; +import java.util.List; + +/** + * @Description : 库存条码信息 + * @Reference : + * @Author : dragon.xu + * @CreateDate : 2018-11-17 14:50 + * @Modify: + **/ +@Data +@Entity +@Table(name = "WMS_STOCK_SN_SNAPSHOT", indexes = { + @Index(columnList = "PACKAGE_NO"), + @Index(columnList = "PART_NO"), + @Index(columnList = "REF_SRC"), + @Index(columnList = "SN"), + @Index(columnList = "SN_2D"), + @Index(columnList = "WH_NO"), + @Index(columnList = "ZONE_NO"), + @Index(columnList = "LOCATE_NO"), + @Index(columnList = "LOT_NO"), + @Index(columnList = "FIX_LOT_NO"), + @Index(columnList = "DATE_CODE"), + @Index(columnList = "VENDOR_NO"), + @Index(columnList = "ORGANIZE_CODE"), + @Index(columnList = "SNAPSHOT_TIME") + }) +@DynamicInsert +@DynamicUpdate +@EqualsAndHashCode(callSuper = true) +@Api(value = "库存条码信息", description = "库存条码信息") +public class WmsStockSnSnapshot extends BaseBean { + + private static final long serialVersionUID = 8641922373097608315L; + + @Column(name="SNAPSHOT_TIME") + @ApiParam("快照时间") + public String snapshotTime; + + @Column(name = "WH_NO") + @ApiParam(value = "仓库代码") + private String whNo; + + @Column(name = "ZONE_NO") + @ApiParam(value = "存储区编号") + private String zoneNo; + + @Column(name = "LOCATE_NO") + @ApiParam(value = "库位代码") + private String locateNo; + + @Column(name = "PART_NO") + @ApiParam(value = "物料编号") + private String partNo; + + @Column(name = "PART_NAME_RDD") + @ApiParam(value = "物料名称") + private String partNameRdd; + + @Column(name = "LOT_NO", nullable = false) + @ApiParam("收货日期(批次编码)") + public String lotNo = ""; + + @Column(name = "DATE_CODE", nullable = false) + @ApiParam(value = "生产日期") + public String dateCode = ""; + + @Column(name = "LEFT_CODE", nullable = false) + @ApiParam(value = "有效期") + private String leftCode = ""; + + @Column(name = "VENDOR_NO") + @ApiParam(value = "供应商编码") + public String vendorNo; + + @Column(name = "FIX_LOT_NO", nullable = false) + @ApiParam(value = "特殊批次") + private String fixLotNo = ""; + + @Column(name = "CUST_NO") + @ApiParam(value = "客户编码") + private String custNo; + + @Column(name = "SHIPPING_FLAG") + @ApiParam(value = "发往地") + private String shippingFlag; + + @Column(name = "SN") + @ApiParam(value = "条码") + private String sn; + + @Column(name = "SN_2D") + @ApiParam(value = "二维码") + private String sn2d; + + @Column(name = "PACKAGE_NO") + @ApiParam(value = "包装编号") + private String packageNo; + + @Column(name = "UNIT") + @ApiParam(value = "单位") + private String unit; + + @Column(name = "QTY") + @ApiParam(value = "数量", example = "0") + private Double qty = 0d; + + /** + * 质量状态:10=合格,20=不合格,30=隔离 + */ + @Column(name = "QC_STATUS") + @ApiParam(value = "质检状态", example = "0") + @AnnoOutputColumn(refClass = WmsEnumUtil.STOCK_SN_QC_STATUS.class,refForeignKey = "value",value = "description") + private Integer qcStatus; + /** + * 条码状态:1=创建,10=质检中,20=待入库,30=入库,40=配料,50=出库,60=报废,70=在途 + */ + @Column(name = "SN_STATUS") + @ApiParam(value = "条码状态", example = "0") + @AnnoOutputColumn(refClass = WmsEnumUtil.STOCK_SN_STATUS.class,refForeignKey = "value",value = "description") + private Integer snStatus; + /** + * 1:已打印;2:未打印 + */ + @Column(name = "PRINTED") + @ApiParam(value = "是否打印", example = "0") + @AnnoOutputColumn(refClass = WmsEnumUtil.TRUE_OR_FALSE.class,refForeignKey = "value",value = "description") + private Integer printed; + + @Column(name = "PDATE") + @ApiParam(value = "打印时间") + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") + private Date pdate; + /** + * 1=ASN,10=PO,20=SO + */ + @Column(name = "REF_TYPE") + @ApiParam(value = "关联单据类型") + private String refType; + + @Column(name = "REF_SRC") + @ApiParam(value = "关联单号") + private String refSrc; + + @Column(name = "CUST_SN") + @ApiParam(value = "客户条码") + private String custSn; + + @Column(name = "WORK_CENTER_CODE") + @ApiParam(value = "工作中心代码") + private String workCenterCode; + + @Column(name = "SN_TYPE") + @ApiParam(value = "条码类型", example = "10") + @AnnoOutputColumn(refClass = WmsEnumUtil.WMS_STOCK_TYPE.class,refForeignKey = "value",value = "description") + private Integer snType = 10; + + @ApiParam(value = "仓库名称") + @Transient + public String whNameRdd; + + @ApiParam(value = "存储区名称") + @Transient + public String zoneNameRdd; + + @ApiParam(value = "库位名称") + @Transient + public String locateNameRdd; + + @ApiParam(value = "物料类型描述") + @Transient + public String partTypeDesc; + + @ApiParam(value = "客户名称") + @Transient + public String custNameRdd; + + @ApiParam(value = "供应商名称") + @Transient + public String vendorNameRdd; + + @ApiParam(value = "二维码内容") + @Transient + public String barCode; + + @ApiParam(value = "散件质检输入不良数量") + @Transient + public Double inputNCQty; + + @ApiParam(value = "前端散件表格是否编辑") + @Transient + public Boolean isSet = false; + + @ApiParam(value = "加减库容标志") + @Transient + public Boolean isAdd; + + @ApiParam(value = "项目名称") + @Transient + public String prodCfgTypeName; + + @ApiParam(value = "标签编号") + @Transient + public String labelNo; + + @Transient + @ApiParam(value = "工厂名称") + public String organizeName; + + @Transient + @ApiParam(value = "物料数量总和") + public Double sumPartQty; + + @Transient + @ApiParam(value = "条码数量总和") + public Long snCount; + + @Transient + @ApiParam(value = "物料编码集合") + public List partNoList; + + @Transient + @ApiParam(value = "ERP库存地集合") + public List erpZoneNoList; + + @Transient + @ApiParam(value = "ERP库存地") + public String erpZoneNo; + + @Transient + @ApiParam(value = "目标数量") + public Double destQty; + + public WmsStockSnSnapshot(){} + + public WmsStockSnSnapshot(String partNo){ + this.partNo = partNo; + } + + public Integer getSnType() { return snType == null ? 0 : snType.intValue();} + + public Double getQty() { + return qty == null ? 0L : qty.doubleValue(); + } + + public Double getInputNCQty(){return inputNCQty == null ? 0L : this.inputNCQty.doubleValue();} + + public WmsStockSnSnapshot(Long snCount, Double sumPartQty, String locateNo) { + this.snCount = snCount; + this.sumPartQty = sumPartQty; + this.locateNo = locateNo; + } +} diff --git a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/repository/SwebProcurementPlanOrderRepository.java b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/repository/SwebProcurementPlanOrderRepository.java index 130a355..6b6a05e 100644 --- a/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/repository/SwebProcurementPlanOrderRepository.java +++ b/modules/i3plus-pojo-wms/src/main/java/cn/estsh/i3plus/pojo/wms/repository/SwebProcurementPlanOrderRepository.java @@ -1,7 +1,7 @@ package cn.estsh.i3plus.pojo.wms.repository; import cn.estsh.i3plus.pojo.base.jpa.dao.BaseRepository; -import cn.estsh.i3plus.pojo.wms.bean.iotio.SwebProcurementPlanOrder; +import cn.estsh.i3plus.pojo.wms.bean.SwebProcurementPlanOrder; import org.springframework.stereotype.Repository; /**