出入库单oms;
This commit is contained in:
@@ -2,14 +2,14 @@ package com.mhd.system.api;
|
||||
|
||||
import com.mhd.common.core.constant.ServiceNameConstants;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.system.api.domain.MaterialBaseInfoFeign;
|
||||
import com.mhd.system.api.domain.MaterialInventoryDTO;
|
||||
import com.mhd.system.api.domain.NoticeOrderDTO;
|
||||
import com.mhd.system.api.domain.*;
|
||||
import com.mhd.system.api.factory.RemoteWmsFallbackFactory;
|
||||
import com.mhd.system.api.feign.FeignAutoConfiguration;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
@@ -65,4 +65,33 @@ public interface WmsServiceFeign {
|
||||
*/
|
||||
@GetMapping("/materialInventoryApi/listAll")
|
||||
public AjaxResult materialInventoryApiListAll(MaterialInventoryDTO materialInventoryDTO);
|
||||
}
|
||||
|
||||
/**
|
||||
* oms下发单保存
|
||||
*/
|
||||
@ApiOperation("oms下发单保存")
|
||||
@PostMapping(value = "/stockOutOrderApi/omsOutOrderAdd")
|
||||
public void omsOutOrderAdd(@RequestBody StockOutOrder stockOutOrder);
|
||||
|
||||
/**
|
||||
* oms下发单明细保存
|
||||
*/
|
||||
@ApiOperation("oms下发单明细保存")
|
||||
@PostMapping(value = "/stockOutOrderApi/omsOutOrderAddDetail")
|
||||
public void omsOutOrderAddDetail(@RequestBody List<OutMaterialDetail> outMaterialDetails);
|
||||
|
||||
|
||||
/**
|
||||
* oms下发单保存
|
||||
*/
|
||||
@ApiOperation("oms下发单保存")
|
||||
@PostMapping(value = "/stockInOrderApi/omsInOrderAdd")
|
||||
public void omsInOrderAdd(@RequestBody StockInOrder stockInOrder);
|
||||
|
||||
/**
|
||||
* oms下发单明细保存
|
||||
*/
|
||||
@ApiOperation("oms下发单明细保存")
|
||||
@PostMapping(value = "/stockInOrderApi/omsInOrderAddDetail")
|
||||
public void omsInOrderAddDetail(@RequestBody List<InMaterialDetail> inMaterialDetails);
|
||||
}
|
||||
@@ -0,0 +1,367 @@
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
|
||||
/**
|
||||
* 物料明细对象 material_detail
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class InMaterialDetail extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("订单物料明细id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long materialDetailId;
|
||||
|
||||
@ApiModelProperty("业务唯一id")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long uniqueId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("物料基础信息id")
|
||||
@Excel(name = "物料基础信息id")
|
||||
private Long materialBaseInfoId;
|
||||
|
||||
@ApiModelProperty("物料编码")
|
||||
@Excel(name = "物料编码")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty("物料名称")
|
||||
@Excel(name = "物料名称")
|
||||
private String materialName;
|
||||
|
||||
@ApiModelProperty("物料条形码")
|
||||
@Excel(name = "物料条形码")
|
||||
private String barCode;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("收货数量")
|
||||
@Excel(name = "收货数量")
|
||||
private BigDecimal receiptQuantity;
|
||||
|
||||
@ApiModelProperty("上架数量")
|
||||
@Excel(name = "上架数量")
|
||||
private BigDecimal shelvesQuantity;
|
||||
|
||||
@ApiModelProperty("作业数量(例如:收货数量 上架数量)")
|
||||
@Excel(name = "作业数量(例如:收货数量 上架数量)")
|
||||
private BigDecimal actualQuantity;
|
||||
|
||||
@ApiModelProperty("收货状态: 1-待收货 2-收货中 3-已收货 4-已收货(少收) 5-已收货(超收)")
|
||||
@Excel(name = "收货状态: 1-待收货 2-收货中 3-已收货 4-已收货(少收) 5-已收货(超收)")
|
||||
private Integer receiptStatus;
|
||||
|
||||
@ApiModelProperty("上架状态: 1-待上架 2-上架中 3-已上架 4-已上架(少上) 5-已上架(超上)")
|
||||
@Excel(name = "上架状态: 1-待上架 2-上架中 3-已上架 4-已上架(少上) 5-已上架(超上)")
|
||||
private Integer shelvesStatus;
|
||||
|
||||
@ApiModelProperty("包装规格id")
|
||||
@Excel(name = "包装规格id")
|
||||
private Long packId;
|
||||
|
||||
@ApiModelProperty("包装规格编码")
|
||||
@Excel(name = "包装规格编码")
|
||||
private String packCode;
|
||||
|
||||
@ApiModelProperty("包装规格名称")
|
||||
@Excel(name = "包装规格名称")
|
||||
private String packName;
|
||||
|
||||
@ApiModelProperty("包装详情id")
|
||||
@Excel(name = "包装详情id")
|
||||
private Long packDetailId;
|
||||
|
||||
@ApiModelProperty("单位代码:EA IP CS PL OT")
|
||||
@Excel(name = "单位代码:EA IP CS PL OT")
|
||||
private String unitCode;
|
||||
|
||||
@ApiModelProperty("单位名称")
|
||||
@Excel(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty("单位数量")
|
||||
@Excel(name = "单位数量")
|
||||
private BigDecimal unitNumber;
|
||||
|
||||
@ApiModelProperty("物料仓库控制信息id")
|
||||
@Excel(name = "物料仓库控制信息id")
|
||||
private Long materialWarehouseControlId;
|
||||
|
||||
@ApiModelProperty("是否序列号管理: 1-是 2-否")
|
||||
@Excel(name = "是否序列号管理: 1-是 2-否")
|
||||
private Integer serialNumberManage;
|
||||
|
||||
@ApiModelProperty("是否质检管理: 1-是 2-否")
|
||||
@Excel(name = "是否质检管理: 1-是 2-否")
|
||||
private Integer qualityInspectionManage;
|
||||
|
||||
@ApiModelProperty("质检阶段: 1-收货前 2-收货后上架前")
|
||||
@Excel(name = "质检阶段: 1-收货前 2-收货后上架前")
|
||||
private Integer qualityInspectionStage;
|
||||
|
||||
@ApiModelProperty("质检规则: 1-全检 2-抽检 ")
|
||||
@Excel(name = "质检规则: 1-全检 2-抽检 ")
|
||||
private Integer qualityInspectionRule;
|
||||
|
||||
@ApiModelProperty("抽检比例")
|
||||
@Excel(name = "抽检比例")
|
||||
private BigDecimal qualityInspectionRatio;
|
||||
|
||||
@ApiModelProperty("质检项: 1-包装 2-纯度")
|
||||
@Excel(name = "质检项: 1-包装 2-纯度")
|
||||
private Integer qualityInspectionTerm;
|
||||
|
||||
@ApiModelProperty("质检结果: 1-正常 2-异常")
|
||||
@Excel(name = "质检结果: 1-正常 2-异常")
|
||||
private Integer qualityInspectionResults;
|
||||
|
||||
@ApiModelProperty("是否允许超收: 1-是 2-否")
|
||||
@Excel(name = "是否允许超收: 1-是 2-否")
|
||||
private Integer allowOvercharge;
|
||||
|
||||
@ApiModelProperty("超收比例")
|
||||
@Excel(name = "超收比例")
|
||||
private BigDecimal overchargeRatio;
|
||||
|
||||
@ApiModelProperty("批次号")
|
||||
@Excel(name = "批次号")
|
||||
private String batchNumber;
|
||||
|
||||
@ApiModelProperty("物料状态编码")
|
||||
@Excel(name = "物料状态编码")
|
||||
private String materialStatusCode;
|
||||
|
||||
@ApiModelProperty("物料状态名称")
|
||||
@Excel(name = "物料状态名称")
|
||||
private String materialStatusName;
|
||||
|
||||
@ApiModelProperty("分配规则id")
|
||||
@Excel(name = "分配规则id")
|
||||
private Long distributeRuleId;
|
||||
|
||||
@ApiModelProperty("分配规则编码")
|
||||
@Excel(name = "分配规则编码")
|
||||
private String distributeRuleCode;
|
||||
|
||||
@ApiModelProperty("分配规则名称")
|
||||
@Excel(name = "分配规则名称")
|
||||
private String distributeRuleName;
|
||||
|
||||
@ApiModelProperty("容器id")
|
||||
@Excel(name = "容器id")
|
||||
private Long containerId;
|
||||
|
||||
@ApiModelProperty("容器编码")
|
||||
@Excel(name = "容器编码")
|
||||
private String containerCode;
|
||||
|
||||
@ApiModelProperty("容器类型 数据字典")
|
||||
@Excel(name = "容器类型 数据字典")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("容器类型名称 数据字典")
|
||||
@Excel(name = "容器类型名称 数据字典")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("上架仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("上架仓库编码")
|
||||
@Excel(name = "上架仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("上架库区id")
|
||||
@Excel(name = "上架库区id")
|
||||
private Long storageSectionId;
|
||||
|
||||
@ApiModelProperty("上架库区编码")
|
||||
@Excel(name = "上架库区编码")
|
||||
private String storageCode;
|
||||
|
||||
@ApiModelProperty("上架库区名称")
|
||||
@Excel(name = "上架库区名称")
|
||||
private String storageName;
|
||||
|
||||
@ApiModelProperty("上架库位id")
|
||||
@Excel(name = "上架库位id")
|
||||
private Long storageLocationId;
|
||||
|
||||
@ApiModelProperty("上架库位编码")
|
||||
@Excel(name = "上架库位编码")
|
||||
private String storageLocationCode;
|
||||
|
||||
@ApiModelProperty("上架库位名称")
|
||||
@Excel(name = "上架库位名称")
|
||||
private String storageLocationName;
|
||||
|
||||
@ApiModelProperty("层级深度,从一级开始递增")
|
||||
private Integer level;
|
||||
|
||||
@ApiModelProperty("父级唯一Id")
|
||||
private Long parentUniqueId;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("越库单id")
|
||||
private Long overStockId;
|
||||
|
||||
@ApiModelProperty("越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
@Excel(name = "越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
private Integer overStockStatus;
|
||||
|
||||
@ApiModelProperty("越库类型:1-直接越库 2-分拨越库")
|
||||
@Excel(name = "越库类型:1-直接越库 2-分拨越库")
|
||||
private Long overStockType;
|
||||
|
||||
// ========== 报关相关明细字段 ==========
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号/ITEM")
|
||||
private String specificationModel;
|
||||
|
||||
@ApiModelProperty("SKU码")
|
||||
@Excel(name = "SKU码")
|
||||
private String skuCode;
|
||||
|
||||
@ApiModelProperty("Invoice No.")
|
||||
@Excel(name = "Invoice No.")
|
||||
private String invoiceNo;
|
||||
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private BigDecimal liter;
|
||||
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String dimensions;
|
||||
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declarationUnit;
|
||||
|
||||
@ApiModelProperty("Batch Ref NO's")
|
||||
@Excel(name = "Batch Ref NO's")
|
||||
private String batchRefNo;
|
||||
|
||||
@ApiModelProperty("Sheet Ref NO's")
|
||||
@Excel(name = "Sheet Ref NO's")
|
||||
private String sheetRefNo;
|
||||
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String originCountry;
|
||||
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String boxPalletNo;
|
||||
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private BigDecimal declaredQuantity;
|
||||
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private BigDecimal boxCount;
|
||||
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private BigDecimal pieceCount;
|
||||
|
||||
@ApiModelProperty("入库数量(输入大于等于0的数字,可以为小数)")
|
||||
@Excel(name = "入库数量")
|
||||
private BigDecimal inboundQuantity;
|
||||
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private BigDecimal totalNetWeight;
|
||||
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private BigDecimal totalGrossWeight;
|
||||
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private BigDecimal totalVolume;
|
||||
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private BigDecimal totalArea;
|
||||
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private BigDecimal totalPrice;
|
||||
|
||||
@ApiModelProperty("合同收费")
|
||||
@Excel(name = "合同收费")
|
||||
private BigDecimal contractFee;
|
||||
|
||||
@ApiModelProperty("每月仓租")
|
||||
@Excel(name = "每月仓租")
|
||||
private BigDecimal monthlyWarehouseFee;
|
||||
|
||||
@ApiModelProperty("半月仓租")
|
||||
@Excel(name = "半月仓租")
|
||||
private BigDecimal halfMonthWhFee;
|
||||
|
||||
@ApiModelProperty("折扣(%)")
|
||||
@Excel(name = "折扣(%)")
|
||||
private BigDecimal discountRate;
|
||||
|
||||
@ApiModelProperty("单体积(CBM)")
|
||||
@Excel(name = "单体积(CBM)")
|
||||
private BigDecimal singleVolume;
|
||||
|
||||
@ApiModelProperty("单毛重(KG)")
|
||||
@Excel(name = "单毛重(KG)")
|
||||
private BigDecimal singleGrossWeight;
|
||||
|
||||
@ApiModelProperty("lot编号")
|
||||
@Excel(name = "lot编号")
|
||||
private String lotNo;
|
||||
}
|
||||
+496
@@ -0,0 +1,496 @@
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
/**
|
||||
* 物料明细对象 material_detail
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class OutMaterialDetail extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("订单物料明细id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long materialDetailId;
|
||||
|
||||
@ApiModelProperty("业务唯一id")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long uniqueId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("物料基础信息id")
|
||||
@Excel(name = "物料基础信息id")
|
||||
private Long materialBaseInfoId;
|
||||
|
||||
@ApiModelProperty("物料编码")
|
||||
@Excel(name = "物料编码")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty("物料名称")
|
||||
@Excel(name = "物料名称")
|
||||
private String materialName;
|
||||
|
||||
@ApiModelProperty("物料条形码")
|
||||
@Excel(name = "物料条形码")
|
||||
private String barCode;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("已分配数量")
|
||||
@Excel(name = "已分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("本次分配数量")
|
||||
@Excel(name = "本次分配数量")
|
||||
@TableField(exist = false)
|
||||
private BigDecimal nowAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("包装规格id")
|
||||
@Excel(name = "包装规格id")
|
||||
private Long packId;
|
||||
|
||||
@ApiModelProperty("包装规格编码")
|
||||
@Excel(name = "包装规格编码")
|
||||
private String packCode;
|
||||
|
||||
@ApiModelProperty("包装规格名称")
|
||||
@Excel(name = "包装规格名称")
|
||||
private String packName;
|
||||
|
||||
@ApiModelProperty("包装详情id")
|
||||
@Excel(name = "包装详情id")
|
||||
private Long packDetailId;
|
||||
|
||||
@ApiModelProperty("单位代码:EA IP CS PL OT")
|
||||
@Excel(name = "单位代码:EA IP CS PL OT")
|
||||
private String unitCode;
|
||||
|
||||
@ApiModelProperty("单位名称")
|
||||
@Excel(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty("单位数量")
|
||||
@Excel(name = "单位数量")
|
||||
private BigDecimal unitNumber;
|
||||
|
||||
@ApiModelProperty("物料仓库控制信息id")
|
||||
@Excel(name = "物料仓库控制信息id")
|
||||
private Long materialWarehouseControlId;
|
||||
|
||||
@ApiModelProperty("是否序列号管理: 1-是 2-否")
|
||||
@Excel(name = "是否序列号管理: 1-是 2-否")
|
||||
private Integer serialNumberManage;
|
||||
|
||||
@ApiModelProperty("物料库存id")
|
||||
@Excel(name = "物料库存id")
|
||||
private Long materialInventoryId;
|
||||
|
||||
@ApiModelProperty("批次号")
|
||||
@Excel(name = "批次号")
|
||||
private String batchNumber;
|
||||
|
||||
@ApiModelProperty("物料状态编码")
|
||||
@Excel(name = "物料状态编码")
|
||||
private String materialStatusCode;
|
||||
|
||||
@ApiModelProperty("物料状态名称")
|
||||
@Excel(name = "物料状态名称")
|
||||
private String materialStatusName;
|
||||
|
||||
@ApiModelProperty("容器id")
|
||||
@Excel(name = "容器id")
|
||||
private Long containerId;
|
||||
|
||||
@ApiModelProperty("容器编码")
|
||||
@Excel(name = "容器编码")
|
||||
private String containerCode;
|
||||
|
||||
@ApiModelProperty("容器类型 数据字典")
|
||||
@Excel(name = "容器类型 数据字典")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("容器类型名称 数据字典")
|
||||
@Excel(name = "容器类型名称 数据字典")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("分配仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("分配仓库编码")
|
||||
@Excel(name = "分配仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("分配库区id")
|
||||
@Excel(name = "分配库区id")
|
||||
private Long storageSectionId;
|
||||
|
||||
@ApiModelProperty("分配库区编码")
|
||||
@Excel(name = "分配库区编码")
|
||||
private String storageCode;
|
||||
|
||||
@ApiModelProperty("分配库区名称")
|
||||
@Excel(name = "分配库区名称")
|
||||
private String storageName;
|
||||
|
||||
@ApiModelProperty("分配库位id")
|
||||
@Excel(name = "分配库位id")
|
||||
private Long storageLocationId;
|
||||
|
||||
@ApiModelProperty("分配库位编码")
|
||||
@Excel(name = "分配库位编码")
|
||||
private String storageLocationCode;
|
||||
|
||||
@ApiModelProperty("分配库位名称")
|
||||
@Excel(name = "分配库位名称")
|
||||
private String storageLocationName;
|
||||
|
||||
@ApiModelProperty("层级深度,从一级开始递增")
|
||||
private Integer level;
|
||||
|
||||
@ApiModelProperty("父级唯一Id")
|
||||
private Long parentUniqueId;
|
||||
|
||||
@ApiModelProperty("是否允许修改: 1-是 2-否 分配后 不再支持修改")
|
||||
@Excel(name = "是否允许修改: 1-是 2-否")
|
||||
private Integer allowModify;
|
||||
|
||||
@ApiModelProperty("是否生成拣货单: 1-是 2-否")
|
||||
@Excel(name = "是否生成拣货单: 1-是 2-否")
|
||||
private Integer genPickingOrder;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("越库单id")
|
||||
private Long overStockId;
|
||||
|
||||
@ApiModelProperty("越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
@Excel(name = "越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
private Integer overStockStatus;
|
||||
|
||||
@ApiModelProperty("越库类型:1-直接越库 2-分拨越库")
|
||||
@Excel(name = "越库类型:1-直接越库 2-分拨越库")
|
||||
private Long overStockType;
|
||||
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
/**
|
||||
* 商品SKU码
|
||||
*/
|
||||
@ApiModelProperty("商品SKU码")
|
||||
@Excel(name = "商品SKU码")
|
||||
private String skucode;
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO’s")
|
||||
@Excel(name = "Batch Ref NO’s")
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO’s")
|
||||
@Excel(name = "Sheet Ref NO’s")
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String boxPalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private BigDecimal declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private BigDecimal caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private BigDecimal pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
private BigDecimal outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private BigDecimal totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private BigDecimal totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private BigDecimal totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private BigDecimal totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private BigDecimal totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
@ApiModelProperty("扩展属性1")
|
||||
@Excel(name = "扩展属性1")
|
||||
@TableField("ext_attr_1")
|
||||
private String extAttr1;
|
||||
|
||||
@ApiModelProperty("扩展属性2")
|
||||
@Excel(name = "扩展属性2")
|
||||
@TableField("ext_attr_2")
|
||||
private String extAttr2;
|
||||
|
||||
@ApiModelProperty("生产日期")
|
||||
@Excel(name = "生产日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date productionDate;
|
||||
|
||||
@ApiModelProperty("过期日期")
|
||||
@Excel(name = "过期日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expiryDate;
|
||||
|
||||
@ApiModelProperty("存货日期")
|
||||
@Excel(name = "存货日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date inventoryDate;
|
||||
|
||||
@ApiModelProperty("扩展属性3")
|
||||
@Excel(name = "扩展属性3", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
@TableField("ext_attr_3")
|
||||
private Date extAttr3;
|
||||
|
||||
@ApiModelProperty("扩展属性4")
|
||||
@Excel(name = "扩展属性4", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
@TableField("ext_attr_4")
|
||||
private Date extAttr4;
|
||||
|
||||
/**
|
||||
* 库存数量(仅用于前端展示,从material_inventory表中带出)
|
||||
*/
|
||||
@ApiModelProperty("分配时库存数量")
|
||||
private BigDecimal inventoryQuantity;
|
||||
|
||||
@TableField(exist = false)
|
||||
private BigDecimal actualQuantity;
|
||||
|
||||
@ApiModelProperty("复核总净重(KG)")
|
||||
@Excel(name = "复核总净重(KG)")
|
||||
private BigDecimal checkNetWeight;
|
||||
|
||||
@ApiModelProperty("复核总毛重(KG)")
|
||||
@Excel(name = "复核总毛重(KG)")
|
||||
private BigDecimal checkGrossWeight;
|
||||
|
||||
@ApiModelProperty("复核总体积(CBM)")
|
||||
@Excel(name = "复核总体积(CBM)")
|
||||
private BigDecimal checkVolume;
|
||||
|
||||
@ApiModelProperty("复核总面积(SQM)")
|
||||
@Excel(name = "复核总面积(SQM)")
|
||||
private BigDecimal checkArea;
|
||||
|
||||
@ApiModelProperty("是否已分配")
|
||||
@Excel(name = "是否已分配")
|
||||
private String isAllocated;
|
||||
|
||||
|
||||
@ApiModelProperty("合同收费")
|
||||
@Excel(name = "合同收费")
|
||||
private BigDecimal contractFee;
|
||||
|
||||
@ApiModelProperty("每月仓租")
|
||||
@Excel(name = "每月仓租")
|
||||
private BigDecimal monthlyWarehouseFee;
|
||||
|
||||
@ApiModelProperty("半月仓租")
|
||||
@Excel(name = "半月仓租")
|
||||
private BigDecimal halfMonthWhFee;
|
||||
|
||||
@ApiModelProperty("折扣(%)")
|
||||
@Excel(name = "折扣(%)")
|
||||
private BigDecimal discountRate;
|
||||
|
||||
@ApiModelProperty("单体积(CBM)")
|
||||
@Excel(name = "单体积(CBM)")
|
||||
private BigDecimal singleVolume;
|
||||
|
||||
@ApiModelProperty("单毛重(KG)")
|
||||
@Excel(name = "单毛重(KG)")
|
||||
private BigDecimal singleGrossWeight;
|
||||
|
||||
@ApiModelProperty("lot编号")
|
||||
@Excel(name = "lot编号")
|
||||
private String lotNo;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("库存单位")
|
||||
@Excel(name = "库存单位")
|
||||
private String stockUnit;
|
||||
|
||||
@ApiModelProperty("库存数量")
|
||||
@Excel(name = "库存数量")
|
||||
private BigDecimal stockQuantity;
|
||||
}
|
||||
@@ -0,0 +1,355 @@
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
/**
|
||||
* 入库单对象 stock_in_order
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class StockInOrder extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("入库单id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long inOrderId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("入库状态: 1-已创建 2-已审核 3-收货中 4-上架中 5-已入库 6-已取消 7-已关闭")
|
||||
@Excel(name = "入库状态: 1-已创建 2-已审核 3-收货中 4-上架中 5-已入库 6-已取消 7-已关闭")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("入库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
@Excel(name = "入库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
private Integer auditStatus;
|
||||
|
||||
@ApiModelProperty("入库单审核备注")
|
||||
@Excel(name = "入库单审核备注")
|
||||
private String auditRemark;
|
||||
|
||||
@ApiModelProperty("入库单审核人")
|
||||
@Excel(name = "入库单审核人")
|
||||
private Long auditBy;
|
||||
|
||||
@ApiModelProperty("入库单审核人姓名")
|
||||
@Excel(name = "入库单审核人姓名")
|
||||
private String auditByName;
|
||||
|
||||
@ApiModelProperty("入库单审核时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "入库单审核时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date auditTime;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("入库单类型编码")
|
||||
@Excel(name = "入库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("入库单类型名称")
|
||||
@Excel(name = "入库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("供应商id")
|
||||
@Excel(name = "供应商id")
|
||||
private Long supplierId;
|
||||
|
||||
@ApiModelProperty("供应商编码")
|
||||
@Excel(name = "供应商编码")
|
||||
private String supplierCode;
|
||||
|
||||
@ApiModelProperty("供应商名称")
|
||||
@Excel(name = "供应商名称")
|
||||
private String supplierName;
|
||||
|
||||
@ApiModelProperty("预计到货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计到货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接入库: 1-是 2-否")
|
||||
@Excel(name = "是否直接入库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("物料种数")
|
||||
@Excel(name = "物料种数")
|
||||
private Integer materialQuantity;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("是否取消订单: 1-是 2-否")
|
||||
@Excel(name = "是否取消订单: 1-是 2-否")
|
||||
private Integer cancelOrder;
|
||||
|
||||
@ApiModelProperty("取消订单备注")
|
||||
@Excel(name = "取消订单备注")
|
||||
private String cancelRemark;
|
||||
|
||||
@ApiModelProperty("取消订单人")
|
||||
@Excel(name = "取消订单人")
|
||||
private Long cancelBy;
|
||||
|
||||
@ApiModelProperty("取消订单人姓名")
|
||||
@Excel(name = "取消订单人姓名")
|
||||
private String cancelByName;
|
||||
|
||||
@ApiModelProperty("取消订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "取消订单时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date cancelTime;
|
||||
|
||||
@ApiModelProperty("是否关闭订单: 1-是 2-否")
|
||||
@Excel(name = "是否关闭订单: 1-是 2-否")
|
||||
private Integer closeOrder;
|
||||
|
||||
@ApiModelProperty("关闭订单备注")
|
||||
@Excel(name = "关闭订单备注")
|
||||
private String closeRemark;
|
||||
|
||||
@ApiModelProperty("关闭订单人")
|
||||
@Excel(name = "关闭订单人")
|
||||
private Long closeBy;
|
||||
|
||||
@ApiModelProperty("关闭订单人姓名")
|
||||
@Excel(name = "关闭订单人姓名")
|
||||
private String closeByName;
|
||||
|
||||
@ApiModelProperty("关闭订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "关闭订单时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date closeTime;
|
||||
|
||||
@ApiModelProperty("入库单来源: 1-正常录入 2-通知单生成 3-无单收货")
|
||||
@Excel(name = "入库单来源: 1-正常录入 2-通知单生成 3-无单收货")
|
||||
private Integer orderSource;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("调度单号")
|
||||
private String mobilizeCode;
|
||||
|
||||
@ApiModelProperty("越库单id")
|
||||
private Long overStockId;
|
||||
|
||||
@ApiModelProperty("越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
@Excel(name = "越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
private Integer overStockStatus;
|
||||
|
||||
@ApiModelProperty("越库类型:1-直接越库 2-分拨越库")
|
||||
@Excel(name = "越库类型:1-直接越库 2-分拨越库")
|
||||
private Long overStockType;
|
||||
|
||||
// ========== 报关相关字段 ==========
|
||||
@ApiModelProperty("To")
|
||||
@Excel(name = "To")
|
||||
@TableField(value = "\"TO\"")
|
||||
private String to;
|
||||
|
||||
@ApiModelProperty("联系人")
|
||||
@Excel(name = "联系人")
|
||||
private String contactPerson;
|
||||
|
||||
@ApiModelProperty("车型及车牌")
|
||||
@Excel(name = "车型及车牌")
|
||||
private String vehicleInfo;
|
||||
|
||||
@ApiModelProperty("委托编号NO")
|
||||
@Excel(name = "委托编号NO")
|
||||
private String consignmentNo;
|
||||
|
||||
@ApiModelProperty("Tel")
|
||||
@Excel(name = "Tel")
|
||||
private String tel;
|
||||
|
||||
@ApiModelProperty("司机签名")
|
||||
@Excel(name = "司机签名")
|
||||
private String driverSignature;
|
||||
|
||||
@ApiModelProperty("Fax")
|
||||
@Excel(name = "Fax")
|
||||
private String fax;
|
||||
|
||||
@ApiModelProperty("申报地关区")
|
||||
@Excel(name = "申报地关区")
|
||||
private String declarationArea;
|
||||
|
||||
@ApiModelProperty("生产商")
|
||||
@Excel(name = "生产商")
|
||||
private String manufacturer;
|
||||
|
||||
@ApiModelProperty("报关员姓名及联系方式")
|
||||
@Excel(name = "报关员姓名及联系方式")
|
||||
private String customsBrokerInfo;
|
||||
|
||||
@ApiModelProperty("送货地址")
|
||||
@Excel(name = "送货地址")
|
||||
private String deliveryAddress;
|
||||
|
||||
@ApiModelProperty("进出境关别")
|
||||
@Excel(name = "进出境关别")
|
||||
private String entryExitCustoms;
|
||||
|
||||
@ApiModelProperty("起运/运抵国(地区)")
|
||||
@Excel(name = "起运/运抵国(地区)")
|
||||
private String originDestinationCountry;
|
||||
|
||||
@ApiModelProperty("承运商")
|
||||
@Excel(name = "承运商")
|
||||
private String carrier;
|
||||
|
||||
@ApiModelProperty("柜号")
|
||||
@Excel(name = "柜号")
|
||||
private String containerNo;
|
||||
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportMethod;
|
||||
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionMethod;
|
||||
|
||||
@ApiModelProperty("海关是否查验货物")
|
||||
@Excel(name = "海关是否查验货物")
|
||||
private Integer customsInspection;
|
||||
|
||||
@ApiModelProperty("是否需要报关")
|
||||
@Excel(name = "是否需要报关")
|
||||
private Integer needCustomsDeclaration;
|
||||
|
||||
@ApiModelProperty("是否需要运输")
|
||||
@Excel(name = "是否需要运输")
|
||||
private Integer needTransport;
|
||||
|
||||
@ApiModelProperty("入仓日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "入仓日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date warehouseDate;
|
||||
|
||||
@ApiModelProperty("完成时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date completionTime;
|
||||
|
||||
@ApiModelProperty("下单日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "下单日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date orderDate;
|
||||
|
||||
@ApiModelProperty("业务单号")
|
||||
@Excel(name = "业务单号")
|
||||
private String businessOrderNo;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
@Excel(name = "业务类型")
|
||||
private String businessType;
|
||||
|
||||
@ApiModelProperty("制单人")
|
||||
@Excel(name = "制单人")
|
||||
private String documentCreator;
|
||||
|
||||
@ApiModelProperty("制单人名称")
|
||||
@Excel(name = "制单人名称")
|
||||
private String documentCreatorName;
|
||||
|
||||
@ApiModelProperty("制单日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "制单日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date documentDate;
|
||||
|
||||
@ApiModelProperty("订单状态")
|
||||
@Excel(name = "订单状态")
|
||||
private String orderStatus;
|
||||
}
|
||||
@@ -0,0 +1,398 @@
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
/**
|
||||
* 出库单对象 stock_out_order
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class StockOutOrder extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("出库单id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long outOrderId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭 12-已复核")
|
||||
@Excel(name = "出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭 12-已复核")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
@Excel(name = "出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
private Integer auditStatus;
|
||||
|
||||
@ApiModelProperty("出库单审核备注")
|
||||
@Excel(name = "出库单审核备注")
|
||||
private String auditRemark;
|
||||
|
||||
@ApiModelProperty("出库单审核人")
|
||||
@Excel(name = "出库单审核人")
|
||||
private Long auditBy;
|
||||
|
||||
@ApiModelProperty("出库单审核人姓名")
|
||||
@Excel(name = "出库单审核人姓名")
|
||||
private String auditByName;
|
||||
|
||||
@ApiModelProperty("出库单审核时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "出库单审核时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date auditTime;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("出库单类型编码")
|
||||
@Excel(name = "出库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("出库单类型名称")
|
||||
@Excel(name = "出库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("客户id")
|
||||
@Excel(name = "客户id")
|
||||
private Long customerId;
|
||||
|
||||
@ApiModelProperty("客户编码")
|
||||
@Excel(name = "客户编码")
|
||||
private String customerCode;
|
||||
|
||||
@ApiModelProperty("客户名称")
|
||||
@Excel(name = "客户名称")
|
||||
private String customerName;
|
||||
|
||||
@ApiModelProperty("预计出货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计出货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接出库: 1-是 2-否")
|
||||
@Excel(name = "是否直接出库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("是否复核: 1-是 2-否")
|
||||
@Excel(name = "是否复核: 1-是 2-否")
|
||||
private Integer review;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("物料种数")
|
||||
@Excel(name = "物料种数")
|
||||
private Integer materialQuantity;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
|
||||
@ApiModelProperty("已生成拣货单数量")
|
||||
@Excel(name = "已生成拣货单分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("是否取消订单: 1-是 2-否")
|
||||
@Excel(name = "是否取消订单: 1-是 2-否")
|
||||
private Integer cancelOrder;
|
||||
|
||||
@ApiModelProperty("取消订单备注")
|
||||
@Excel(name = "取消订单备注")
|
||||
private String cancelRemark;
|
||||
|
||||
@ApiModelProperty("取消订单人")
|
||||
@Excel(name = "取消订单人")
|
||||
private Long cancelBy;
|
||||
|
||||
@ApiModelProperty("取消订单人姓名")
|
||||
@Excel(name = "取消订单人姓名")
|
||||
private String cancelByName;
|
||||
|
||||
@ApiModelProperty("取消订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "取消订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date cancelTime;
|
||||
|
||||
@ApiModelProperty("是否关闭订单: 1-是 2-否")
|
||||
@Excel(name = "是否关闭订单: 1-是 2-否")
|
||||
private Integer closeOrder;
|
||||
|
||||
@ApiModelProperty("关闭订单备注")
|
||||
@Excel(name = "关闭订单备注")
|
||||
private String closeRemark;
|
||||
|
||||
@ApiModelProperty("关闭订单人")
|
||||
@Excel(name = "关闭订单人")
|
||||
private Long closeBy;
|
||||
|
||||
@ApiModelProperty("关闭订单人姓名")
|
||||
@Excel(name = "关闭订单人姓名")
|
||||
private String closeByName;
|
||||
|
||||
@ApiModelProperty("关闭订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "关闭订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date closeTime;
|
||||
|
||||
@ApiModelProperty("复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
@Excel(name = "复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer checkStatus;
|
||||
|
||||
@ApiModelProperty("复核任务是否下发: 1-是 2-否")
|
||||
@Excel(name = "复核任务是否下发: 1-是 2-否")
|
||||
private Integer checkTaskDistribution;
|
||||
|
||||
@ApiModelProperty("复核任务下发时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "复核任务下发时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date checkTaskDistributionTime;
|
||||
|
||||
@ApiModelProperty("复核作业人用户ID")
|
||||
@Excel(name = "复核作业人用户ID")
|
||||
private Long checkOperatorsBy;
|
||||
|
||||
@ApiModelProperty("复核作业人姓名")
|
||||
@Excel(name = "复核作业人姓名")
|
||||
private String checkOperatorsName;
|
||||
|
||||
@ApiModelProperty("调度单号")
|
||||
@Excel(name = "调度单号")
|
||||
private String mobilizeCode;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("越库单id")
|
||||
private Long overStockId;
|
||||
|
||||
@ApiModelProperty("越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
@Excel(name = "越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
private Integer overStockStatus;
|
||||
|
||||
@ApiModelProperty("越库类型:1-直接越库 2-分拨越库")
|
||||
@Excel(name = "越库类型:1-直接越库 2-分拨越库")
|
||||
private Long overStockType;
|
||||
|
||||
@ApiModelProperty("to")
|
||||
@Excel(name = "to")
|
||||
@TableField(value = "\"TO\"")
|
||||
private String to;
|
||||
|
||||
@ApiModelProperty("联系人")
|
||||
@Excel(name = "联系人")
|
||||
private String contactPerson;
|
||||
|
||||
@ApiModelProperty("车型及车牌")
|
||||
@Excel(name = "车型及车牌")
|
||||
private String vehicleModelPlate;
|
||||
|
||||
@ApiModelProperty("委托编号")
|
||||
@Excel(name = "委托编号")
|
||||
private String entrustNo;
|
||||
|
||||
@ApiModelProperty("Tel")
|
||||
@Excel(name = "Tel")
|
||||
private String tel;
|
||||
|
||||
@ApiModelProperty("司机签名")
|
||||
@Excel(name = "司机签名")
|
||||
private String driverSign;
|
||||
|
||||
@ApiModelProperty("Fax")
|
||||
@Excel(name = "Fax")
|
||||
private String fax;
|
||||
|
||||
@ApiModelProperty("申报地关区")
|
||||
@Excel(name = "申报地关区")
|
||||
private String declareCustoms;
|
||||
|
||||
@ApiModelProperty("生产商")
|
||||
@Excel(name = "生产商")
|
||||
private String manufacturer;
|
||||
|
||||
@ApiModelProperty("报关员姓名及联系方式")
|
||||
@Excel(name = "报关员姓名及联系方式")
|
||||
private String customsDeclarerInfo;
|
||||
|
||||
@ApiModelProperty("送货地址")
|
||||
@Excel(name = "送货地址")
|
||||
private String deliveryAddr;
|
||||
|
||||
@ApiModelProperty("进出境关别")
|
||||
@Excel(name = "进出境关别")
|
||||
private String entryExitCustoms;
|
||||
|
||||
@ApiModelProperty("起运/运抵国(地区)")
|
||||
@Excel(name = "起运/运抵国(地区)")
|
||||
private String departureArrivalCountry;
|
||||
|
||||
@ApiModelProperty("承运商")
|
||||
@Excel(name = "承运商")
|
||||
private String carrier;
|
||||
|
||||
@ApiModelProperty("承运商名称")
|
||||
@Excel(name = "承运商名称")
|
||||
private String carrierName;
|
||||
|
||||
@ApiModelProperty("柜号")
|
||||
@Excel(name = "柜号")
|
||||
private String containerNo;
|
||||
|
||||
@ApiModelProperty("柜")
|
||||
@Excel(name = "柜")
|
||||
private String containerNoName;
|
||||
|
||||
@ApiModelProperty("出仓日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "出仓日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date outboundDate;
|
||||
@ApiModelProperty("完成时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date completeTime;
|
||||
@ApiModelProperty("orderDate")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "orderDate", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date orderDate;
|
||||
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeCode;
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeName;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeCode;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeName;
|
||||
@ApiModelProperty("海关是否查验货物")
|
||||
@Excel(name = "海关是否查验货物")
|
||||
private String customsInspectionFlag;
|
||||
@ApiModelProperty("是否需要报关")
|
||||
@Excel(name = "是否需要报关")
|
||||
private String needDeclareFlag;
|
||||
@ApiModelProperty("是否需要运输")
|
||||
@Excel(name = "是否需要运输")
|
||||
private String needTransportFlag;
|
||||
@ApiModelProperty("app上传的图片")
|
||||
private String pictureApp;
|
||||
|
||||
@ApiModelProperty("业务单号")
|
||||
@Excel(name = "业务单号")
|
||||
private String businessOrderNo;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
@Excel(name = "业务类型")
|
||||
private String businessType;
|
||||
|
||||
@ApiModelProperty("制单人")
|
||||
@Excel(name = "制单人")
|
||||
private String documentCreator;
|
||||
|
||||
@ApiModelProperty("制单人名称")
|
||||
@Excel(name = "制单人名称")
|
||||
private String documentCreatorName;
|
||||
|
||||
@ApiModelProperty("制单日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "制单日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date documentDate;
|
||||
|
||||
}
|
||||
+19
-4
@@ -4,15 +4,14 @@ import com.mhd.common.core.domain.entity.R;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.system.api.WlhyServiceFeign;
|
||||
import com.mhd.system.api.WmsServiceFeign;
|
||||
import com.mhd.system.api.domain.MaterialBaseInfoFeign;
|
||||
import com.mhd.system.api.domain.MaterialInventoryDTO;
|
||||
import com.mhd.system.api.domain.NoticeOrderDTO;
|
||||
import com.mhd.system.api.domain.*;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.cloud.openfeign.FallbackFactory;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
@@ -54,6 +53,22 @@ public class RemoteWmsFallbackFactory implements FallbackFactory<WmsServiceFeign
|
||||
public AjaxResult materialInventoryApiListAll(MaterialInventoryDTO materialInventoryDTO) {
|
||||
return AjaxResult.error(cause.getMessage());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void omsOutOrderAdd(StockOutOrder stockOutOrder) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void omsOutOrderAddDetail(List<OutMaterialDetail> outMaterialDetails) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void omsInOrderAdd(StockInOrder stockInOrder) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void omsInOrderAddDetail(List<InMaterialDetail> inMaterialDetails) {
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
+496
@@ -0,0 +1,496 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
/**
|
||||
* 物料明细对象 material_detail
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ReservationOutMaterialDetail extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("订单物料明细id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long materialDetailId;
|
||||
|
||||
@ApiModelProperty("业务唯一id")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long uniqueId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("物料基础信息id")
|
||||
@Excel(name = "物料基础信息id")
|
||||
private Long materialBaseInfoId;
|
||||
|
||||
@ApiModelProperty("物料编码")
|
||||
@Excel(name = "物料编码")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty("物料名称")
|
||||
@Excel(name = "物料名称")
|
||||
private String materialName;
|
||||
|
||||
@ApiModelProperty("物料条形码")
|
||||
@Excel(name = "物料条形码")
|
||||
private String barCode;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("已分配数量")
|
||||
@Excel(name = "已分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("本次分配数量")
|
||||
@Excel(name = "本次分配数量")
|
||||
@TableField(exist = false)
|
||||
private BigDecimal nowAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("包装规格id")
|
||||
@Excel(name = "包装规格id")
|
||||
private Long packId;
|
||||
|
||||
@ApiModelProperty("包装规格编码")
|
||||
@Excel(name = "包装规格编码")
|
||||
private String packCode;
|
||||
|
||||
@ApiModelProperty("包装规格名称")
|
||||
@Excel(name = "包装规格名称")
|
||||
private String packName;
|
||||
|
||||
@ApiModelProperty("包装详情id")
|
||||
@Excel(name = "包装详情id")
|
||||
private Long packDetailId;
|
||||
|
||||
@ApiModelProperty("单位代码:EA IP CS PL OT")
|
||||
@Excel(name = "单位代码:EA IP CS PL OT")
|
||||
private String unitCode;
|
||||
|
||||
@ApiModelProperty("单位名称")
|
||||
@Excel(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty("单位数量")
|
||||
@Excel(name = "单位数量")
|
||||
private BigDecimal unitNumber;
|
||||
|
||||
@ApiModelProperty("物料仓库控制信息id")
|
||||
@Excel(name = "物料仓库控制信息id")
|
||||
private Long materialWarehouseControlId;
|
||||
|
||||
@ApiModelProperty("是否序列号管理: 1-是 2-否")
|
||||
@Excel(name = "是否序列号管理: 1-是 2-否")
|
||||
private Integer serialNumberManage;
|
||||
|
||||
@ApiModelProperty("物料库存id")
|
||||
@Excel(name = "物料库存id")
|
||||
private Long materialInventoryId;
|
||||
|
||||
@ApiModelProperty("批次号")
|
||||
@Excel(name = "批次号")
|
||||
private String batchNumber;
|
||||
|
||||
@ApiModelProperty("物料状态编码")
|
||||
@Excel(name = "物料状态编码")
|
||||
private String materialStatusCode;
|
||||
|
||||
@ApiModelProperty("物料状态名称")
|
||||
@Excel(name = "物料状态名称")
|
||||
private String materialStatusName;
|
||||
|
||||
@ApiModelProperty("容器id")
|
||||
@Excel(name = "容器id")
|
||||
private Long containerId;
|
||||
|
||||
@ApiModelProperty("容器编码")
|
||||
@Excel(name = "容器编码")
|
||||
private String containerCode;
|
||||
|
||||
@ApiModelProperty("容器类型 数据字典")
|
||||
@Excel(name = "容器类型 数据字典")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("容器类型名称 数据字典")
|
||||
@Excel(name = "容器类型名称 数据字典")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("分配仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("分配仓库编码")
|
||||
@Excel(name = "分配仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("分配库区id")
|
||||
@Excel(name = "分配库区id")
|
||||
private Long storageSectionId;
|
||||
|
||||
@ApiModelProperty("分配库区编码")
|
||||
@Excel(name = "分配库区编码")
|
||||
private String storageCode;
|
||||
|
||||
@ApiModelProperty("分配库区名称")
|
||||
@Excel(name = "分配库区名称")
|
||||
private String storageName;
|
||||
|
||||
@ApiModelProperty("分配库位id")
|
||||
@Excel(name = "分配库位id")
|
||||
private Long storageLocationId;
|
||||
|
||||
@ApiModelProperty("分配库位编码")
|
||||
@Excel(name = "分配库位编码")
|
||||
private String storageLocationCode;
|
||||
|
||||
@ApiModelProperty("分配库位名称")
|
||||
@Excel(name = "分配库位名称")
|
||||
private String storageLocationName;
|
||||
|
||||
@ApiModelProperty("层级深度,从一级开始递增")
|
||||
private Integer level;
|
||||
|
||||
@ApiModelProperty("父级唯一Id")
|
||||
private Long parentUniqueId;
|
||||
|
||||
@ApiModelProperty("是否允许修改: 1-是 2-否 分配后 不再支持修改")
|
||||
@Excel(name = "是否允许修改: 1-是 2-否")
|
||||
private Integer allowModify;
|
||||
|
||||
@ApiModelProperty("是否生成拣货单: 1-是 2-否")
|
||||
@Excel(name = "是否生成拣货单: 1-是 2-否")
|
||||
private Integer genPickingOrder;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("越库单id")
|
||||
private Long overStockId;
|
||||
|
||||
@ApiModelProperty("越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
@Excel(name = "越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
private Integer overStockStatus;
|
||||
|
||||
@ApiModelProperty("越库类型:1-直接越库 2-分拨越库")
|
||||
@Excel(name = "越库类型:1-直接越库 2-分拨越库")
|
||||
private Long overStockType;
|
||||
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
/**
|
||||
* 商品SKU码
|
||||
*/
|
||||
@ApiModelProperty("商品SKU码")
|
||||
@Excel(name = "商品SKU码")
|
||||
private String skucode;
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO’s")
|
||||
@Excel(name = "Batch Ref NO’s")
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO’s")
|
||||
@Excel(name = "Sheet Ref NO’s")
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String boxPalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private BigDecimal declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private BigDecimal caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private BigDecimal pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
private BigDecimal outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private BigDecimal totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private BigDecimal totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private BigDecimal totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private BigDecimal totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private BigDecimal totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
@ApiModelProperty("扩展属性1")
|
||||
@Excel(name = "扩展属性1")
|
||||
@TableField("ext_attr_1")
|
||||
private String extAttr1;
|
||||
|
||||
@ApiModelProperty("扩展属性2")
|
||||
@Excel(name = "扩展属性2")
|
||||
@TableField("ext_attr_2")
|
||||
private String extAttr2;
|
||||
|
||||
@ApiModelProperty("生产日期")
|
||||
@Excel(name = "生产日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date productionDate;
|
||||
|
||||
@ApiModelProperty("过期日期")
|
||||
@Excel(name = "过期日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expiryDate;
|
||||
|
||||
@ApiModelProperty("存货日期")
|
||||
@Excel(name = "存货日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date inventoryDate;
|
||||
|
||||
@ApiModelProperty("扩展属性3")
|
||||
@Excel(name = "扩展属性3", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
@TableField("ext_attr_3")
|
||||
private Date extAttr3;
|
||||
|
||||
@ApiModelProperty("扩展属性4")
|
||||
@Excel(name = "扩展属性4", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
@TableField("ext_attr_4")
|
||||
private Date extAttr4;
|
||||
|
||||
/**
|
||||
* 库存数量(仅用于前端展示,从material_inventory表中带出)
|
||||
*/
|
||||
@ApiModelProperty("分配时库存数量")
|
||||
private BigDecimal inventoryQuantity;
|
||||
|
||||
@TableField(exist = false)
|
||||
private BigDecimal actualQuantity;
|
||||
|
||||
@ApiModelProperty("复核总净重(KG)")
|
||||
@Excel(name = "复核总净重(KG)")
|
||||
private BigDecimal checkNetWeight;
|
||||
|
||||
@ApiModelProperty("复核总毛重(KG)")
|
||||
@Excel(name = "复核总毛重(KG)")
|
||||
private BigDecimal checkGrossWeight;
|
||||
|
||||
@ApiModelProperty("复核总体积(CBM)")
|
||||
@Excel(name = "复核总体积(CBM)")
|
||||
private BigDecimal checkVolume;
|
||||
|
||||
@ApiModelProperty("复核总面积(SQM)")
|
||||
@Excel(name = "复核总面积(SQM)")
|
||||
private BigDecimal checkArea;
|
||||
|
||||
@ApiModelProperty("是否已分配")
|
||||
@Excel(name = "是否已分配")
|
||||
private String isAllocated;
|
||||
|
||||
|
||||
@ApiModelProperty("合同收费")
|
||||
@Excel(name = "合同收费")
|
||||
private BigDecimal contractFee;
|
||||
|
||||
@ApiModelProperty("每月仓租")
|
||||
@Excel(name = "每月仓租")
|
||||
private BigDecimal monthlyWarehouseFee;
|
||||
|
||||
@ApiModelProperty("半月仓租")
|
||||
@Excel(name = "半月仓租")
|
||||
private BigDecimal halfMonthWhFee;
|
||||
|
||||
@ApiModelProperty("折扣(%)")
|
||||
@Excel(name = "折扣(%)")
|
||||
private BigDecimal discountRate;
|
||||
|
||||
@ApiModelProperty("单体积(CBM)")
|
||||
@Excel(name = "单体积(CBM)")
|
||||
private BigDecimal singleVolume;
|
||||
|
||||
@ApiModelProperty("单毛重(KG)")
|
||||
@Excel(name = "单毛重(KG)")
|
||||
private BigDecimal singleGrossWeight;
|
||||
|
||||
@ApiModelProperty("lot编号")
|
||||
@Excel(name = "lot编号")
|
||||
private String lotNo;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("库存单位")
|
||||
@Excel(name = "库存单位")
|
||||
private String stockUnit;
|
||||
|
||||
@ApiModelProperty("库存数量")
|
||||
@Excel(name = "库存数量")
|
||||
private BigDecimal stockQuantity;
|
||||
}
|
||||
+68
@@ -0,0 +1,68 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.repository.facade;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.mhd.oms.domain.reservationInMaterialDetail.repository.todo.QueryOrderOverStockDO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.entity.ReservationOutMaterialDetail;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.OutMaterialCheckPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.ReservationOutMaterialDetailPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailBaseDO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 物料明细Service接口
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
public interface IReservationOutMaterialDetailService extends IService<ReservationOutMaterialDetail>
|
||||
{
|
||||
/**
|
||||
* 分页查询物料明细列表
|
||||
*/
|
||||
public List<ReservationOutMaterialDetailPO> queryList(ReservationOutMaterialDetailDO outMaterialDetailDO);
|
||||
|
||||
/**
|
||||
* 关联出库单 查询物料明细列表
|
||||
*/
|
||||
public List<ReservationOutMaterialDetailPO> queryOutOrderList(QueryOrderOverStockDO queryOrderOverStockDO);
|
||||
|
||||
|
||||
|
||||
public List<ReservationOutMaterialDetailPO> queryListChildren(ReservationOutMaterialDetailDO outMaterialDetailDO);
|
||||
|
||||
/**
|
||||
* 新增物料明细
|
||||
*/
|
||||
public Boolean insert(ReservationOutMaterialDetailDO outMaterialDetailDO);
|
||||
|
||||
/**
|
||||
* 修改物料明细
|
||||
*/
|
||||
public Boolean update(ReservationOutMaterialDetailDO outMaterialDetailDO);
|
||||
|
||||
/**
|
||||
* 新增物料明细
|
||||
*/
|
||||
public Boolean batchInsert(String orderNumber, List<ReservationOutMaterialDetailDO> outMaterialDetailDOList);
|
||||
|
||||
/**
|
||||
* 修改物料明细
|
||||
*/
|
||||
public Boolean batchUpdate(List<ReservationOutMaterialDetailDO> outMaterialDetailDOList, ReservationOutMaterialDetailBaseDO outMaterialDetailBaseDO);
|
||||
|
||||
|
||||
/**
|
||||
* 批量删除物料明细
|
||||
*/
|
||||
public Boolean delete(Long[] materialDetailIds);
|
||||
|
||||
|
||||
/**
|
||||
* 查询物料明细
|
||||
*/
|
||||
public ReservationOutMaterialDetailPO getInfo(Long materialDetailId);
|
||||
}
|
||||
+56
@@ -0,0 +1,56 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.repository.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mhd.oms.domain.reservationInMaterialDetail.repository.todo.QueryOrderOverStockDO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.entity.ReservationOutMaterialDetail;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.ReservationOutMaterialDetailPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 物料明细Mapper接口
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
public interface ReservationOutMaterialDetailMapper extends BaseMapper<ReservationOutMaterialDetail>
|
||||
{
|
||||
/**
|
||||
* 查询物料明细列表
|
||||
*/
|
||||
public List<ReservationOutMaterialDetailPO> queryList(ReservationOutMaterialDetailDO outMaterialDetailDO);
|
||||
|
||||
/**
|
||||
* 关联出库单 查询物料明细列表
|
||||
*/
|
||||
public List<ReservationOutMaterialDetailPO> queryOutOrderList(QueryOrderOverStockDO queryOrderOverStockDO);
|
||||
|
||||
|
||||
/**
|
||||
* @description 批量修改指定物料明细分配数量
|
||||
* @author ZhouGY
|
||||
* @date 2024/6/7 14:29
|
||||
* @param outMaterialDetailDO
|
||||
* @return int
|
||||
*/
|
||||
public int batchAddAllocationQuantityByIds(ReservationOutMaterialDetailDO outMaterialDetailDO);
|
||||
|
||||
/**
|
||||
* @description 批量修改指定物料明细拣货数量
|
||||
* @author ZhouGY
|
||||
* @date 2024/6/7 14:29
|
||||
* @param outMaterialDetailDO
|
||||
* @return int
|
||||
*/
|
||||
public int batchAddPickingQuantityByIds(ReservationOutMaterialDetailDO outMaterialDetailDO);
|
||||
|
||||
/**
|
||||
* @description 批量修改指定物料明细拣货数量
|
||||
* @author ZhouGY
|
||||
* @date 2024/6/7 14:29
|
||||
* @param outMaterialDetailDO
|
||||
* @return int
|
||||
*/
|
||||
public int batchAddPickingQuantityByUniqueIds(ReservationOutMaterialDetailDO outMaterialDetailDO);
|
||||
}
|
||||
+264
@@ -0,0 +1,264 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.repository.persistence;
|
||||
|
||||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mhd.common.core.constant.SnowFlakeConstants;
|
||||
import com.mhd.common.core.domain.po.UserPo;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.utils.IgnoreNullUtil;
|
||||
import com.mhd.common.core.utils.StringUtils;
|
||||
import com.mhd.common.core.utils.bean.BeanUtils;
|
||||
import com.mhd.common.core.utils.uuid.IdGenerator;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.oms.domain.reservationInMaterialDetail.repository.todo.QueryOrderOverStockDO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.entity.ReservationOutMaterialDetail;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.facade.IReservationOutMaterialDetailService;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.mapper.ReservationOutMaterialDetailMapper;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.OutMaterialCheckPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.ReservationOutMaterialDetailPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailBaseDO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.mapper.ReservationStockInOrderMapper;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.po.MaterialBaseInfoPO;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
import org.springframework.util.ObjectUtils;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 物料明细Service业务层处理
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
@Service
|
||||
public class ReservationOutMaterialDetailImpl extends ServiceImpl<ReservationOutMaterialDetailMapper, ReservationOutMaterialDetail> implements IReservationOutMaterialDetailService {
|
||||
@Autowired
|
||||
private ReservationOutMaterialDetailMapper outMaterialDetailMapper;
|
||||
// @Autowired
|
||||
// private IReservationOutMaterialDetailSerialNumberService outMaterialDetailSerialNumberService;
|
||||
@Autowired
|
||||
private IdGenerator idGenerator;
|
||||
@Autowired
|
||||
private ReservationStockInOrderMapper reservationStockInOrderMapper;
|
||||
// @Autowired
|
||||
// private MaterialBaseInfoMapper materialBaseInfoMapper;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 查询物料明细列表
|
||||
*/
|
||||
@Override
|
||||
public List<ReservationOutMaterialDetailPO> queryList(ReservationOutMaterialDetailDO outMaterialDetailDO)
|
||||
{
|
||||
return outMaterialDetailMapper.queryList(outMaterialDetailDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 关联出库单 查询物料明细列表
|
||||
*/
|
||||
@Override
|
||||
public List<ReservationOutMaterialDetailPO> queryOutOrderList(QueryOrderOverStockDO queryOrderOverStockDO) {
|
||||
return outMaterialDetailMapper.queryOutOrderList(queryOrderOverStockDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询物料明细列表
|
||||
*/
|
||||
@Override
|
||||
public List<ReservationOutMaterialDetailPO> queryListChildren(ReservationOutMaterialDetailDO outMaterialDetailDO)
|
||||
{
|
||||
List<ReservationOutMaterialDetailPO> outMaterialDetailPOList = outMaterialDetailMapper.queryList(outMaterialDetailDO);
|
||||
// 获取查询的层级
|
||||
List<ReservationOutMaterialDetailPO> outMaterialDetailParentList = outMaterialDetailPOList
|
||||
.stream().filter(e -> 1 == e.getLevel()).collect(Collectors.toList());
|
||||
// 递归查询子集
|
||||
outMaterialDetailParentList.forEach(materialDetailPO -> materialDetailPO.setChildren(getChildren(materialDetailPO.getUniqueId(), outMaterialDetailPOList, 2)));
|
||||
return outMaterialDetailParentList;
|
||||
}
|
||||
|
||||
private List<ReservationOutMaterialDetailPO> getChildren(Long parentUniqueId, List<ReservationOutMaterialDetailPO> materialDetailPOList, Integer maxLevel){
|
||||
List<ReservationOutMaterialDetailPO> childrenCityList = materialDetailPOList.stream().filter(materialDetailPO -> parentUniqueId.equals(materialDetailPO.getParentUniqueId())).collect(Collectors.toList());
|
||||
if (!CollectionUtils.isEmpty(childrenCityList)){
|
||||
childrenCityList.forEach(childrenCity -> {
|
||||
if (childrenCity.getLevel() < maxLevel){
|
||||
childrenCity.setChildren(getChildren(childrenCity.getUniqueId(), materialDetailPOList, maxLevel));
|
||||
}
|
||||
});
|
||||
}
|
||||
return childrenCityList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物料明细
|
||||
*/
|
||||
@Override
|
||||
public Boolean insert(ReservationOutMaterialDetailDO outMaterialDetailDO) {
|
||||
ReservationOutMaterialDetail outMaterialDetail = new ReservationOutMaterialDetail();
|
||||
BeanUtils.copyProperties(outMaterialDetailDO, outMaterialDetail);
|
||||
return this.save(outMaterialDetail);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物料明细
|
||||
*/
|
||||
@Override
|
||||
public Boolean update(ReservationOutMaterialDetailDO outMaterialDetailDO) {
|
||||
ReservationOutMaterialDetail outMaterialDetail = new ReservationOutMaterialDetail();
|
||||
BeanUtils.copyProperties(outMaterialDetailDO, outMaterialDetail);
|
||||
return this.updateById(outMaterialDetail);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 批量新增物流明细
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/22 9:27
|
||||
* @param outOrderNumber
|
||||
* @param outMaterialDetailDOList
|
||||
* @return Boolean
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public Boolean batchInsert(String outOrderNumber, List<ReservationOutMaterialDetailDO> outMaterialDetailDOList) {
|
||||
if (CollectionUtils.isEmpty(outMaterialDetailDOList)) {
|
||||
throw new ServiceException("物料明细不能为空");
|
||||
}
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
// 批量新增或修改
|
||||
// 获取用户姓名(优先从UserPo获取,如果为空则使用realname,最后使用username作为兜底)
|
||||
final String userRealName = (loginUser.getUserPo() != null && loginUser.getUserPo().getUserName() != null
|
||||
&& !loginUser.getUserPo().getUserName().trim().isEmpty())
|
||||
? loginUser.getUserPo().getUserName()
|
||||
: (loginUser.getRealname() != null && !loginUser.getRealname().trim().isEmpty())
|
||||
? loginUser.getRealname()
|
||||
: loginUser.getUsername();
|
||||
List<ReservationOutMaterialDetail> outMaterialDetailList = new ArrayList<>();
|
||||
for (ReservationOutMaterialDetailDO outMaterialDetailDO : outMaterialDetailDOList){
|
||||
ReservationOutMaterialDetail outMaterialDetail = new ReservationOutMaterialDetail();
|
||||
BeanUtils.copyProperties(outMaterialDetailDO, outMaterialDetail);
|
||||
outMaterialDetail.setUniqueId(idGenerator.snowflakeId(SnowFlakeConstants.wmsId));
|
||||
outMaterialDetail.setOutOrderNumber(outOrderNumber);
|
||||
outMaterialDetail.setTopOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
outMaterialDetail.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
outMaterialDetail.setOrganizationName(loginUser.getUserPo().getOrganizationName());
|
||||
outMaterialDetail.setCreateBy(loginUser.getUserid());
|
||||
outMaterialDetail.setCreateByName(userRealName);
|
||||
outMaterialDetail.setCreateTime(new Date());
|
||||
outMaterialDetail.setQuantity(outMaterialDetail.getOutboundQuantity());
|
||||
String materialNo = outMaterialDetail.getMaterialNo();
|
||||
List<MaterialBaseInfoPO> materialBaseInfos = reservationStockInOrderMapper.getMaterialBaseInfoList(materialNo);
|
||||
//List<MaterialBaseInfoPO> materialBaseInfos = materialBaseInfoMapper.selectList(new QueryWrapper<MaterialBaseInfo>().lambda().eq(MaterialBaseInfo::getMaterialCode, materialNo));
|
||||
if (!CollectionUtils.isEmpty(materialBaseInfos) && materialBaseInfos.size() > 0) {
|
||||
outMaterialDetail.setCommodityName(materialBaseInfos.get(0).getMaterialName());
|
||||
outMaterialDetail.setBarCode(materialBaseInfos.get(0).getBarCode());
|
||||
outMaterialDetail.setPackName(materialBaseInfos.get(0).getPackName());
|
||||
outMaterialDetail.setPackCode(materialBaseInfos.get(0).getPackCode());
|
||||
outMaterialDetail.setUnitCode(materialBaseInfos.get(0).getUnitCode());
|
||||
outMaterialDetail.setUnitName(materialBaseInfos.get(0).getUnitName());
|
||||
}
|
||||
outMaterialDetailList.add(outMaterialDetail);
|
||||
}
|
||||
return saveBatch(outMaterialDetailList);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 批量修改物流明细
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/22 9:27
|
||||
* @param outMaterialDetailDOList
|
||||
* @param outMaterialDetailBaseDO
|
||||
* @return Boolean
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public Boolean batchUpdate(List<ReservationOutMaterialDetailDO> outMaterialDetailDOList, ReservationOutMaterialDetailBaseDO outMaterialDetailBaseDO) {
|
||||
if (CollectionUtils.isEmpty(outMaterialDetailDOList)) {
|
||||
throw new ServiceException("物料明细不能为空");
|
||||
}
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
|
||||
List<ReservationOutMaterialDetail> outMaterialDetailDbList = outMaterialDetailMapper.selectList(new QueryWrapper<ReservationOutMaterialDetail>().lambda().eq(ReservationOutMaterialDetail::getOutOrderNumber, outMaterialDetailBaseDO.getOutOrderNumber()));
|
||||
Map<Long, ReservationOutMaterialDetail> materialDetailMap = outMaterialDetailDbList.stream().collect(Collectors.toMap(ReservationOutMaterialDetail::getMaterialDetailId, Function.identity()));
|
||||
//批量新增或修改物料信息
|
||||
List<ReservationOutMaterialDetail> outMaterialDetailList = new ArrayList<>();
|
||||
//需要修改的物流明细
|
||||
List<Long> materialDetailIdsByUpdate = new ArrayList<>();
|
||||
for (ReservationOutMaterialDetailDO outMaterialDetailDO : outMaterialDetailDOList){
|
||||
//判断是否需要修改
|
||||
ReservationOutMaterialDetail outMaterialDetail = materialDetailMap.get(outMaterialDetailDO.getMaterialDetailId());
|
||||
if (outMaterialDetail == null){
|
||||
outMaterialDetail = new ReservationOutMaterialDetail();
|
||||
BeanUtils.copyProperties(outMaterialDetailDO, outMaterialDetail);
|
||||
outMaterialDetail.setUniqueId(idGenerator.snowflakeId(SnowFlakeConstants.wmsId));
|
||||
outMaterialDetail.setOutOrderNumber(outMaterialDetailBaseDO.getOutOrderNumber());
|
||||
outMaterialDetail.setOrganizationId(outMaterialDetailBaseDO.getOrganizationId());
|
||||
outMaterialDetail.setOrganizationName(outMaterialDetailBaseDO.getOrganizationName());
|
||||
outMaterialDetail.setTopOrganizationId(outMaterialDetailBaseDO.getTopOrganizationId());
|
||||
}else {
|
||||
BeanUtils.copyProperties(outMaterialDetailDO, outMaterialDetail);
|
||||
outMaterialDetail.setUpdateBy(loginUser.getUserid());
|
||||
outMaterialDetail.setUpdateByName(loginUser.getUsername());
|
||||
outMaterialDetail.setUpdateTime(new Date());
|
||||
materialDetailIdsByUpdate.add(outMaterialDetailDO.getMaterialDetailId());
|
||||
}
|
||||
outMaterialDetailList.add(outMaterialDetail);
|
||||
}
|
||||
//需修改的物料明细id集合不为空
|
||||
if (!CollectionUtils.isEmpty(materialDetailIdsByUpdate)){
|
||||
List<Long> materialDetailIdsByDb = outMaterialDetailDbList.stream().map(ReservationOutMaterialDetail::getMaterialDetailId).collect(Collectors.toList());
|
||||
//过滤需要修改的id集合
|
||||
materialDetailIdsByDb.removeAll(materialDetailIdsByUpdate);
|
||||
//判断是否存在需要删除的物流明细 标记删除
|
||||
if (!CollectionUtils.isEmpty(materialDetailIdsByDb)){
|
||||
update(new UpdateWrapper<ReservationOutMaterialDetail>().lambda()
|
||||
.set(ReservationOutMaterialDetail::getDelFlag, 2)
|
||||
.set(ReservationOutMaterialDetail::getUpdateBy, loginUser.getUserid())
|
||||
.set(ReservationOutMaterialDetail::getUpdateByName, loginUser.getUsername())
|
||||
.set(ReservationOutMaterialDetail::getUpdateTime, new Date())
|
||||
.in(ReservationOutMaterialDetail::getMaterialDetailId, materialDetailIdsByDb));
|
||||
}
|
||||
}
|
||||
//保存物料明细信息
|
||||
return saveOrUpdateBatch(outMaterialDetailList);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 批量删除物料明细
|
||||
*/
|
||||
@Override
|
||||
public Boolean delete(Long[] materialDetailIds ) {
|
||||
List<ReservationOutMaterialDetail> list = new ArrayList<>();
|
||||
for (Long id : materialDetailIds) {
|
||||
ReservationOutMaterialDetail outMaterialDetail = new ReservationOutMaterialDetail();
|
||||
outMaterialDetail.setMaterialDetailId(id);
|
||||
outMaterialDetail.setDelFlag(2);
|
||||
list.add(outMaterialDetail);
|
||||
}
|
||||
return this.updateBatchById(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物料明细
|
||||
*/
|
||||
@Override
|
||||
public ReservationOutMaterialDetailPO getInfo(Long materialDetailId) {
|
||||
ReservationOutMaterialDetail outMaterialDetail = this.getById(materialDetailId);
|
||||
ReservationOutMaterialDetailPO outMaterialDetailPO = new ReservationOutMaterialDetailPO();
|
||||
BeanUtils.copyProperties(outMaterialDetail, outMaterialDetailPO);
|
||||
return outMaterialDetailPO;
|
||||
}
|
||||
}
|
||||
+42
@@ -0,0 +1,42 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.repository.po;
|
||||
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* @author ZhouGY
|
||||
* @title OutMaterialCheckPO
|
||||
* @description: 出库复审信息统计
|
||||
* @date 2024/5/31 10:33
|
||||
**/
|
||||
@Data
|
||||
public class OutMaterialCheckPO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("物料数")
|
||||
private Integer count;
|
||||
|
||||
@ApiModelProperty("总重量")
|
||||
@Excel(name = "总重量")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("总体积")
|
||||
@Excel(name = "总体积")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("数量EA")
|
||||
private BigDecimal number;
|
||||
|
||||
@ApiModelProperty("需扫描数")
|
||||
private BigDecimal wantNumber;
|
||||
|
||||
@ApiModelProperty("已扫描数")
|
||||
private BigDecimal alreadyNumber;
|
||||
|
||||
@ApiModelProperty("未扫描数")
|
||||
private BigDecimal notHaveNumber;
|
||||
}
|
||||
+528
@@ -0,0 +1,528 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.repository.po;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderBaseDO;
|
||||
import com.mhd.system.api.domain.MaterialMoreDetailPO;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 物料明细对象 material_detail
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "物料明细对象", description = "物料明细响应对象")
|
||||
public class ReservationOutMaterialDetailPO extends ReservationStockOutOrderBaseDO {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("订单物料明细id")
|
||||
private Long materialDetailId;
|
||||
|
||||
@ApiModelProperty("业务唯一id")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long uniqueId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("物料基础信息id")
|
||||
@Excel(name = "物料基础信息id")
|
||||
private Long materialBaseInfoId;
|
||||
|
||||
@ApiModelProperty("物料编码")
|
||||
@Excel(name = "物料编码")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty("物料名称")
|
||||
@Excel(name = "物料名称")
|
||||
private String materialName;
|
||||
|
||||
@ApiModelProperty("物料条形码")
|
||||
@Excel(name = "物料条形码")
|
||||
private String barCode;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("已分配数量")
|
||||
@Excel(name = "已分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
@ApiModelProperty("本次分配数量")
|
||||
@Excel(name = "本次分配数量")
|
||||
@TableField(exist = false)
|
||||
private BigDecimal nowAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("待复核数量")
|
||||
@Excel(name = "待复核数量")
|
||||
private BigDecimal waitCheckQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量输入框字段,默认等于待复核数量")
|
||||
@TableField(exist = false)
|
||||
private BigDecimal actualQuantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("包装规格id")
|
||||
@Excel(name = "包装规格id")
|
||||
private Long packId;
|
||||
|
||||
@ApiModelProperty("包装规格编码")
|
||||
@Excel(name = "包装规格编码")
|
||||
private String packCode;
|
||||
|
||||
@ApiModelProperty("包装规格名称")
|
||||
@Excel(name = "包装规格名称")
|
||||
private String packName;
|
||||
|
||||
@ApiModelProperty("包装详情id")
|
||||
@Excel(name = "包装详情id")
|
||||
private Long packDetailId;
|
||||
|
||||
@ApiModelProperty("单位代码:EA IP CS PL OT")
|
||||
@Excel(name = "单位代码:EA IP CS PL OT")
|
||||
private String unitCode;
|
||||
|
||||
@ApiModelProperty("单位名称")
|
||||
@Excel(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty("单位数量")
|
||||
@Excel(name = "单位数量")
|
||||
private BigDecimal unitNumber;
|
||||
|
||||
@ApiModelProperty("物料仓库控制信息id")
|
||||
@Excel(name = "物料仓库控制信息id")
|
||||
private Long materialWarehouseControlId;
|
||||
|
||||
@ApiModelProperty("是否序列号管理: 1-是 2-否")
|
||||
@Excel(name = "是否序列号管理: 1-是 2-否")
|
||||
private Integer serialNumberManage;
|
||||
|
||||
@ApiModelProperty("物料库存id")
|
||||
@Excel(name = "物料库存id")
|
||||
private Long materialInventoryId;
|
||||
|
||||
@ApiModelProperty("批次号")
|
||||
@Excel(name = "批次号")
|
||||
private String batchNumber;
|
||||
|
||||
@ApiModelProperty("物料状态编码")
|
||||
@Excel(name = "物料状态编码")
|
||||
private String materialStatusCode;
|
||||
|
||||
@ApiModelProperty("物料状态名称")
|
||||
@Excel(name = "物料状态名称")
|
||||
private String materialStatusName;
|
||||
|
||||
@ApiModelProperty("容器id")
|
||||
@Excel(name = "容器id")
|
||||
private Long containerId;
|
||||
|
||||
@ApiModelProperty("容器编码")
|
||||
@Excel(name = "容器编码")
|
||||
private String containerCode;
|
||||
|
||||
@ApiModelProperty("容器类型 数据字典")
|
||||
@Excel(name = "容器类型 数据字典")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("容器类型名称 数据字典")
|
||||
@Excel(name = "容器类型名称 数据字典")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("库存数量(仅展示)")
|
||||
private BigDecimal inventoryQuantity;
|
||||
|
||||
@ApiModelProperty("分配仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("分配仓库编码")
|
||||
@Excel(name = "分配仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("分配库区id")
|
||||
@Excel(name = "分配库区id")
|
||||
private Long storageSectionId;
|
||||
|
||||
@ApiModelProperty("分配库区编码")
|
||||
@Excel(name = "分配库区编码")
|
||||
private String storageCode;
|
||||
|
||||
@ApiModelProperty("分配库区名称")
|
||||
@Excel(name = "分配库区名称")
|
||||
private String storageName;
|
||||
|
||||
@ApiModelProperty("分配库位id")
|
||||
@Excel(name = "分配库位id")
|
||||
private Long storageLocationId;
|
||||
|
||||
@ApiModelProperty("分配库位编码")
|
||||
@Excel(name = "分配库位编码")
|
||||
private String storageLocationCode;
|
||||
|
||||
@ApiModelProperty("分配库位名称")
|
||||
@Excel(name = "分配库位名称")
|
||||
private String storageLocationName;
|
||||
|
||||
@ApiModelProperty("层级深度,从一级开始递增")
|
||||
private Integer level;
|
||||
|
||||
@ApiModelProperty("父级唯一Id")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long parentUniqueId;
|
||||
|
||||
@ApiModelProperty("是否允许修改: 1-是 2-否 分配后 不再支持修改")
|
||||
@Excel(name = "是否允许修改: 1-是 2-否")
|
||||
private Integer allowModify;
|
||||
|
||||
@ApiModelProperty("是否生成拣货单: 1-是 2-否")
|
||||
@Excel(name = "是否生成拣货单: 1-是 2-否")
|
||||
private Integer genPickingOrder;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("物料明细")
|
||||
private List<ReservationOutMaterialDetailPO> children;
|
||||
|
||||
@ApiModelProperty("越库单id")
|
||||
private Long overStockId;
|
||||
|
||||
@ApiModelProperty("越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
@Excel(name = "越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
private Integer overStockStatus;
|
||||
|
||||
@ApiModelProperty("越库类型:1-直接越库 2-分拨越库")
|
||||
@Excel(name = "越库类型:1-直接越库 2-分拨越库")
|
||||
private Long overStockType;
|
||||
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
/**
|
||||
* 商品SKU码
|
||||
*/
|
||||
@ApiModelProperty("商品SKU码")
|
||||
@Excel(name = "商品SKU码")
|
||||
private String skucode;
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO’s")
|
||||
@Excel(name = "Batch Ref NO’s")
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO’s")
|
||||
@Excel(name = "Sheet Ref NO’s")
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String boxPalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private BigDecimal declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private BigDecimal caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private BigDecimal pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
private BigDecimal outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private BigDecimal totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private BigDecimal totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private BigDecimal totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private BigDecimal totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private BigDecimal totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
@ApiModelProperty("扩展字段1")
|
||||
@Excel(name = "扩展字段1")
|
||||
private String extAttr1;
|
||||
|
||||
@ApiModelProperty("扩展字段2")
|
||||
@Excel(name = "扩展字段2")
|
||||
private String extAttr2;
|
||||
|
||||
@ApiModelProperty("生产日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "生产日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date productionDate;
|
||||
|
||||
@ApiModelProperty("过期日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "过期日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expiryDate;
|
||||
|
||||
@ApiModelProperty("存货日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "存货日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date inventoryDate;
|
||||
|
||||
@ApiModelProperty("ExtAttr3")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "ExtAttr3", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date extAttr3;
|
||||
|
||||
@ApiModelProperty("ExtAttr4")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "ExtAttr4", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date extAttr4;
|
||||
|
||||
@ApiModelProperty("更多属性明细列表")
|
||||
@TableField(exist = false)
|
||||
private List<MaterialMoreDetailPO> materialMoreDetailList;
|
||||
|
||||
@ApiModelProperty("分配按钮显示类型:1-显示库存分配,2-显示取消分配")
|
||||
@TableField(exist = false)
|
||||
private Integer allocationButtonType;
|
||||
|
||||
@ApiModelProperty("复核总净重(KG)")
|
||||
@Excel(name = "复核总净重(KG)")
|
||||
private BigDecimal checkNetWeight;
|
||||
|
||||
@ApiModelProperty("复核总毛重(KG)")
|
||||
@Excel(name = "复核总毛重(KG)")
|
||||
private BigDecimal checkGrossWeight;
|
||||
|
||||
@ApiModelProperty("复核总体积(CBM)")
|
||||
@Excel(name = "复核总体积(CBM)")
|
||||
private BigDecimal checkVolume;
|
||||
|
||||
@ApiModelProperty("复核总面积(SQM)")
|
||||
@Excel(name = "复核总面积(SQM)")
|
||||
private BigDecimal checkArea;
|
||||
|
||||
@ApiModelProperty("是否已分配")
|
||||
@Excel(name = "是否已分配")
|
||||
private String isAllocated;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty("合同收费")
|
||||
@Excel(name = "合同收费")
|
||||
private BigDecimal contractFee;
|
||||
|
||||
@ApiModelProperty("每月仓租")
|
||||
@Excel(name = "每月仓租")
|
||||
private BigDecimal monthlyWarehouseFee;
|
||||
|
||||
@ApiModelProperty("半月仓租")
|
||||
@Excel(name = "半月仓租")
|
||||
private BigDecimal halfMonthWhFee;
|
||||
|
||||
@ApiModelProperty("折扣(%)")
|
||||
@Excel(name = "折扣(%)")
|
||||
private BigDecimal discountRate;
|
||||
|
||||
@ApiModelProperty("单体积(CBM)")
|
||||
@Excel(name = "单体积(CBM)")
|
||||
private BigDecimal singleVolume;
|
||||
|
||||
@ApiModelProperty("单毛重(KG)")
|
||||
@Excel(name = "单毛重(KG)")
|
||||
private BigDecimal singleGrossWeight;
|
||||
|
||||
@ApiModelProperty("lot编号")
|
||||
@Excel(name = "lot编号")
|
||||
private String lotNo;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("库存单位")
|
||||
@Excel(name = "库存单位")
|
||||
private String stockUnit;
|
||||
|
||||
@ApiModelProperty("库存数量")
|
||||
@Excel(name = "库存数量")
|
||||
private BigDecimal stockQuantity;
|
||||
|
||||
@ApiModelProperty("出库异常明细:计划数量(复核异常场景=拣货数量)")
|
||||
@TableField(exist = false)
|
||||
private BigDecimal abnormalPlanQuantity;
|
||||
|
||||
@ApiModelProperty("出库异常明细:作业数量(复核异常场景=实际复核数量)")
|
||||
@TableField(exist = false)
|
||||
private BigDecimal abnormalWorkQuantity;
|
||||
}
|
||||
+34
@@ -0,0 +1,34 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo;
|
||||
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @author ZhouGY
|
||||
* @title StockBaseDO
|
||||
* @description: TODO
|
||||
* @date 2024/5/23 20:30
|
||||
**/
|
||||
@Data
|
||||
public class ReservationOutMaterialDetailBaseDO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
}
|
||||
+475
@@ -0,0 +1,475 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
//import com.mhd.wms.domain.outMaterialDetailSerialNumber.repository.todo.ReservationOutMaterialDetailSerialNumberDO;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 物料明细对象 material_detail
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ReservationOutMaterialDetailDO extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("订单物料明细id")
|
||||
private Long materialDetailId;
|
||||
|
||||
@ApiModelProperty("业务唯一id")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long uniqueId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("物料基础信息id")
|
||||
@Excel(name = "物料基础信息id")
|
||||
private Long materialBaseInfoId;
|
||||
|
||||
@ApiModelProperty("物料编码")
|
||||
@Excel(name = "物料编码")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty("物料名称")
|
||||
@Excel(name = "物料名称")
|
||||
private String materialName;
|
||||
|
||||
@ApiModelProperty("物料条形码")
|
||||
@Excel(name = "物料条形码")
|
||||
private String barCode;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("已分配数量")
|
||||
@Excel(name = "已分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
|
||||
@ApiModelProperty("本次分配数量")
|
||||
@Excel(name = "本次分配数量")
|
||||
@TableField(exist = false)
|
||||
private BigDecimal nowAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("包装规格id")
|
||||
@Excel(name = "包装规格id")
|
||||
private Long packId;
|
||||
|
||||
@ApiModelProperty("包装规格编码")
|
||||
@Excel(name = "包装规格编码")
|
||||
private String packCode;
|
||||
|
||||
@ApiModelProperty("包装规格名称")
|
||||
@Excel(name = "包装规格名称")
|
||||
private String packName;
|
||||
|
||||
@ApiModelProperty("包装详情id")
|
||||
@Excel(name = "包装详情id")
|
||||
private Long packDetailId;
|
||||
|
||||
@ApiModelProperty("单位代码:EA IP CS PL OT")
|
||||
@Excel(name = "单位代码:EA IP CS PL OT")
|
||||
private String unitCode;
|
||||
|
||||
@ApiModelProperty("单位名称")
|
||||
@Excel(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty("单位数量")
|
||||
@Excel(name = "单位数量")
|
||||
private BigDecimal unitNumber;
|
||||
|
||||
@ApiModelProperty("物料仓库控制信息id")
|
||||
@Excel(name = "物料仓库控制信息id")
|
||||
private Long materialWarehouseControlId;
|
||||
|
||||
@ApiModelProperty("是否序列号管理: 1-是 2-否")
|
||||
@Excel(name = "是否序列号管理: 1-是 2-否")
|
||||
private Integer serialNumberManage;
|
||||
|
||||
@ApiModelProperty("物料库存id")
|
||||
@Excel(name = "物料库存id")
|
||||
private Long materialInventoryId;
|
||||
|
||||
@ApiModelProperty("批次号")
|
||||
@Excel(name = "批次号")
|
||||
private String batchNumber;
|
||||
|
||||
@ApiModelProperty("物料状态编码")
|
||||
@Excel(name = "物料状态编码")
|
||||
private String materialStatusCode;
|
||||
|
||||
@ApiModelProperty("物料状态名称")
|
||||
@Excel(name = "物料状态名称")
|
||||
private String materialStatusName;
|
||||
|
||||
@ApiModelProperty("容器id")
|
||||
@Excel(name = "容器id")
|
||||
private Long containerId;
|
||||
|
||||
@ApiModelProperty("容器编码")
|
||||
@Excel(name = "容器编码")
|
||||
private String containerCode;
|
||||
|
||||
@ApiModelProperty("容器类型 数据字典")
|
||||
@Excel(name = "容器类型 数据字典")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("容器类型名称 数据字典")
|
||||
@Excel(name = "容器类型名称 数据字典")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("分配时库存数量(仅展示)")
|
||||
private BigDecimal inventoryQuantity;
|
||||
|
||||
@ApiModelProperty("分配仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("分配仓库编码")
|
||||
@Excel(name = "分配仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("分配库区id")
|
||||
@Excel(name = "分配库区id")
|
||||
private Long storageSectionId;
|
||||
|
||||
@ApiModelProperty("分配库区编码")
|
||||
@Excel(name = "分配库区编码")
|
||||
private String storageCode;
|
||||
|
||||
@ApiModelProperty("分配库区名称")
|
||||
@Excel(name = "分配库区名称")
|
||||
private String storageName;
|
||||
|
||||
@ApiModelProperty("分配库位id")
|
||||
@Excel(name = "分配库位id")
|
||||
private Long storageLocationId;
|
||||
|
||||
@ApiModelProperty("分配库位编码")
|
||||
@Excel(name = "分配库位编码")
|
||||
private String storageLocationCode;
|
||||
|
||||
@ApiModelProperty("分配库位名称")
|
||||
@Excel(name = "分配库位名称")
|
||||
private String storageLocationName;
|
||||
|
||||
@ApiModelProperty("层级深度,从一级开始递增")
|
||||
private Integer level;
|
||||
|
||||
@ApiModelProperty("父级唯一Id")
|
||||
private Long parentUniqueId;
|
||||
|
||||
@ApiModelProperty("是否允许修改: 1-是 2-否 分配后 不再支持修改")
|
||||
@Excel(name = "是否允许修改: 1-是 2-否")
|
||||
private Integer allowModify;
|
||||
|
||||
@ApiModelProperty("是否生成拣货单: 1-是 2-否")
|
||||
@Excel(name = "是否生成拣货单: 1-是 2-否")
|
||||
private Integer genPickingOrder;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(name = "组织ID集合")
|
||||
private List<Long> organizationIdList;
|
||||
|
||||
@ApiModelProperty(name = "权限菜单ID")
|
||||
private Long permissionMenuId;
|
||||
|
||||
@ApiModelProperty("物料明细子集")
|
||||
private List<ReservationOutMaterialDetailDO> children;
|
||||
|
||||
// @ApiModelProperty("序列号")
|
||||
// private List<ReservationOutMaterialDetailSerialNumberDO> materialDetailSerialNumberList;
|
||||
|
||||
@ApiModelProperty("出单号集合")
|
||||
@Excel(name = "出单号集合")
|
||||
private List<String> outOrderNumberList;
|
||||
|
||||
@ApiModelProperty("取消分配数量")
|
||||
@Excel(name = "取消分配数量")
|
||||
private BigDecimal cancelAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("订单物料明细id")
|
||||
private List<Long> materialDetailIds;
|
||||
|
||||
@ApiModelProperty("作业数量(例如:分配数量 拣货数量 复核数量)")
|
||||
@Excel(name = "作业数量(例如:分配数量 拣货数量 复核数量)")
|
||||
private BigDecimal actualQuantity;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
/**
|
||||
* 商品SKU码
|
||||
*/
|
||||
@ApiModelProperty("商品SKU码")
|
||||
@Excel(name = "商品SKU码")
|
||||
private String skucode;
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO’s")
|
||||
@Excel(name = "Batch Ref NO’s")
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO’s")
|
||||
@Excel(name = "Sheet Ref NO’s")
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String boxPalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private BigDecimal declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private BigDecimal caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private BigDecimal pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
private BigDecimal outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private BigDecimal totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private BigDecimal totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private BigDecimal totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private BigDecimal totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private BigDecimal totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
@ApiModelProperty("复核总净重(KG)")
|
||||
@Excel(name = "复核总净重(KG)")
|
||||
private BigDecimal checkNetWeight;
|
||||
|
||||
@ApiModelProperty("复核总毛重(KG)")
|
||||
@Excel(name = "复核总毛重(KG)")
|
||||
private BigDecimal checkGrossWeight;
|
||||
|
||||
@ApiModelProperty("复核总体积(CBM)")
|
||||
@Excel(name = "复核总体积(CBM)")
|
||||
private BigDecimal checkVolume;
|
||||
|
||||
@ApiModelProperty("复核总面积(SQM)")
|
||||
@Excel(name = "复核总面积(SQM)")
|
||||
private BigDecimal checkArea;
|
||||
|
||||
@ApiModelProperty("是否已分配")
|
||||
@Excel(name = "是否已分配")
|
||||
private String isAllocated;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty("合同收费")
|
||||
@Excel(name = "合同收费")
|
||||
private BigDecimal contractFee;
|
||||
|
||||
@ApiModelProperty("每月仓租")
|
||||
@Excel(name = "每月仓租")
|
||||
private BigDecimal monthlyWarehouseFee;
|
||||
|
||||
@ApiModelProperty("半月仓租")
|
||||
@Excel(name = "半月仓租")
|
||||
private BigDecimal halfMonthWhFee;
|
||||
|
||||
@ApiModelProperty("折扣(%)")
|
||||
@Excel(name = "折扣(%)")
|
||||
private BigDecimal discountRate;
|
||||
|
||||
@ApiModelProperty("单体积(CBM)")
|
||||
@Excel(name = "单体积(CBM)")
|
||||
private BigDecimal singleVolume;
|
||||
|
||||
@ApiModelProperty("单毛重(KG)")
|
||||
@Excel(name = "单毛重(KG)")
|
||||
private BigDecimal singleGrossWeight;
|
||||
|
||||
@ApiModelProperty("lot编号")
|
||||
@Excel(name = "lot编号")
|
||||
private String lotNo;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("库存单位")
|
||||
@Excel(name = "库存单位")
|
||||
private String stockUnit;
|
||||
|
||||
@ApiModelProperty("库存数量")
|
||||
@Excel(name = "库存数量")
|
||||
private BigDecimal stockQuantity;
|
||||
}
|
||||
+465
@@ -0,0 +1,465 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo;
|
||||
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
//import com.mhd.wms.domain.outMaterialDetail.repository.todo.OutMaterialDetailDO;
|
||||
//import com.mhd.wms.interfaces.dto.outMaterialDetailSerialNumber.OutMaterialDetailSerialNumberDTO;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 物料明细对象 material_detail
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ReservationOutMaterialDetailDTO extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("订单物料明细id")
|
||||
private Long materialDetailId;
|
||||
|
||||
@ApiModelProperty("业务唯一id")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long uniqueId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("物料基础信息id")
|
||||
@Excel(name = "物料基础信息id")
|
||||
private Long materialBaseInfoId;
|
||||
|
||||
@ApiModelProperty("物料编码")
|
||||
@Excel(name = "物料编码")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty("物料名称")
|
||||
@Excel(name = "物料名称")
|
||||
private String materialName;
|
||||
|
||||
@ApiModelProperty("物料条形码")
|
||||
@Excel(name = "物料条形码")
|
||||
private String barCode;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
|
||||
@ApiModelProperty("已分配数量")
|
||||
@Excel(name = "已分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("作业数量(例如:分配数量 拣货数量 复核数量 取消数量)")
|
||||
@Excel(name = "作业数量(例如:分配数量 拣货数量 复核数量 取消数量)")
|
||||
private BigDecimal actualQuantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("包装规格id")
|
||||
@Excel(name = "包装规格id")
|
||||
private Long packId;
|
||||
|
||||
@ApiModelProperty("包装规格编码")
|
||||
@Excel(name = "包装规格编码")
|
||||
private String packCode;
|
||||
|
||||
@ApiModelProperty("包装规格名称")
|
||||
@Excel(name = "包装规格名称")
|
||||
private String packName;
|
||||
|
||||
@ApiModelProperty("包装详情id")
|
||||
@Excel(name = "包装详情id")
|
||||
private Long packDetailId;
|
||||
|
||||
@ApiModelProperty("单位代码:EA IP CS PL OT")
|
||||
@Excel(name = "单位代码:EA IP CS PL OT")
|
||||
private String unitCode;
|
||||
|
||||
@ApiModelProperty("单位名称")
|
||||
@Excel(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty("单位数量")
|
||||
@Excel(name = "单位数量")
|
||||
private BigDecimal unitNumber;
|
||||
|
||||
@ApiModelProperty("物料仓库控制信息id")
|
||||
@Excel(name = "物料仓库控制信息id")
|
||||
private Long materialWarehouseControlId;
|
||||
|
||||
@ApiModelProperty("是否序列号管理: 1-是 2-否")
|
||||
@Excel(name = "是否序列号管理: 1-是 2-否")
|
||||
private Integer serialNumberManage;
|
||||
|
||||
@ApiModelProperty("物料库存id")
|
||||
@Excel(name = "物料库存id")
|
||||
private Long materialInventoryId;
|
||||
|
||||
@ApiModelProperty("批次号")
|
||||
@Excel(name = "批次号")
|
||||
private String batchNumber;
|
||||
|
||||
@ApiModelProperty("物料状态编码")
|
||||
@Excel(name = "物料状态编码")
|
||||
private String materialStatusCode;
|
||||
|
||||
@ApiModelProperty("物料状态名称")
|
||||
@Excel(name = "物料状态名称")
|
||||
private String materialStatusName;
|
||||
|
||||
@ApiModelProperty("物料明细子集")
|
||||
private List<ReservationOutMaterialDetailDO> children;
|
||||
|
||||
@ApiModelProperty("容器id")
|
||||
@Excel(name = "容器id")
|
||||
private Long containerId;
|
||||
|
||||
@ApiModelProperty("容器编码")
|
||||
@Excel(name = "容器编码")
|
||||
private String containerCode;
|
||||
|
||||
@ApiModelProperty("容器类型 数据字典")
|
||||
@Excel(name = "容器类型 数据字典")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("容器类型名称 数据字典")
|
||||
@Excel(name = "容器类型名称 数据字典")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("库存数量(仅展示)")
|
||||
private BigDecimal inventoryQuantity;
|
||||
|
||||
@ApiModelProperty("分配仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("分配仓库编码")
|
||||
@Excel(name = "分配仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("分配库区id")
|
||||
@Excel(name = "分配库区id")
|
||||
private Long storageSectionId;
|
||||
|
||||
@ApiModelProperty("分配库区编码")
|
||||
@Excel(name = "分配库区编码")
|
||||
private String storageCode;
|
||||
|
||||
@ApiModelProperty("分配库区名称")
|
||||
@Excel(name = "分配库区名称")
|
||||
private String storageName;
|
||||
|
||||
@ApiModelProperty("分配库位id")
|
||||
@Excel(name = "分配库位id")
|
||||
private Long storageLocationId;
|
||||
|
||||
@ApiModelProperty("分配库位编码")
|
||||
@Excel(name = "分配库位编码")
|
||||
private String storageLocationCode;
|
||||
|
||||
@ApiModelProperty("分配库位名称")
|
||||
@Excel(name = "分配库位名称")
|
||||
private String storageLocationName;
|
||||
|
||||
@ApiModelProperty("层级深度,从一级开始递增")
|
||||
private Integer level;
|
||||
|
||||
@ApiModelProperty("父级唯一Id")
|
||||
@JsonSerialize(using = ToStringSerializer.class)
|
||||
private Long parentUniqueId;
|
||||
|
||||
@ApiModelProperty("是否允许修改: 1-是 2-否 分配后 不再支持修改")
|
||||
@Excel(name = "是否允许修改: 1-是 2-否")
|
||||
private Integer allowModify;
|
||||
|
||||
@ApiModelProperty("是否生成拣货单: 1-是 2-否")
|
||||
@Excel(name = "是否生成拣货单: 1-是 2-否")
|
||||
private Integer genPickingOrder;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(name = "组织ID集合")
|
||||
private List<Long> organizationIdList;
|
||||
|
||||
@ApiModelProperty(name = "权限菜单ID")
|
||||
private Long permissionMenuId;
|
||||
|
||||
@ApiModelProperty("物料明细子集")
|
||||
private List<ReservationOutMaterialDetailDTO> materialDetailList;
|
||||
|
||||
// @ApiModelProperty("序列号")
|
||||
// private List<OutMaterialDetailSerialNumberDTO> materialDetailSerialNumberList;
|
||||
|
||||
@ApiModelProperty("出单号集合")
|
||||
@Excel(name = "出单号集合")
|
||||
private List<String> outOrderNumberList;
|
||||
|
||||
@ApiModelProperty("取消分配数量")
|
||||
@Excel(name = "取消分配数量")
|
||||
private BigDecimal cancelAllocationQuantity;
|
||||
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
/**
|
||||
* 商品SKU码
|
||||
*/
|
||||
@ApiModelProperty("商品SKU码")
|
||||
@Excel(name = "商品SKU码")
|
||||
private String skucode;
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO’s")
|
||||
@Excel(name = "Batch Ref NO’s")
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO’s")
|
||||
@Excel(name = "Sheet Ref NO’s")
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String boxPalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private BigDecimal declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private BigDecimal caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private BigDecimal pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
private BigDecimal outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private BigDecimal totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private BigDecimal totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private BigDecimal totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private BigDecimal totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private BigDecimal totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
|
||||
@ApiModelProperty("复核总净重(KG)")
|
||||
@Excel(name = "复核总净重(KG)")
|
||||
private BigDecimal checkNetWeight;
|
||||
|
||||
@ApiModelProperty("复核总毛重(KG)")
|
||||
@Excel(name = "复核总毛重(KG)")
|
||||
private BigDecimal checkGrossWeight;
|
||||
|
||||
@ApiModelProperty("复核总体积(CBM)")
|
||||
@Excel(name = "复核总体积(CBM)")
|
||||
private BigDecimal checkVolume;
|
||||
|
||||
@ApiModelProperty("复核总面积(SQM)")
|
||||
@Excel(name = "复核总面积(SQM)")
|
||||
private BigDecimal checkArea;
|
||||
|
||||
@ApiModelProperty("合同收费")
|
||||
@Excel(name = "合同收费")
|
||||
private BigDecimal contractFee;
|
||||
|
||||
@ApiModelProperty("每月仓租")
|
||||
@Excel(name = "每月仓租")
|
||||
private BigDecimal monthlyWarehouseFee;
|
||||
|
||||
@ApiModelProperty("半月仓租")
|
||||
@Excel(name = "半月仓租")
|
||||
private BigDecimal halfMonthWhFee;
|
||||
|
||||
@ApiModelProperty("折扣(%)")
|
||||
@Excel(name = "折扣(%)")
|
||||
private BigDecimal discountRate;
|
||||
|
||||
@ApiModelProperty("单体积(CBM)")
|
||||
@Excel(name = "单体积(CBM)")
|
||||
private BigDecimal singleVolume;
|
||||
|
||||
@ApiModelProperty("单毛重(KG)")
|
||||
@Excel(name = "单毛重(KG)")
|
||||
private BigDecimal singleGrossWeight;
|
||||
|
||||
@ApiModelProperty("lot编号")
|
||||
@Excel(name = "lot编号")
|
||||
private String lotNo;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("库存单位")
|
||||
@Excel(name = "库存单位")
|
||||
private String stockUnit;
|
||||
|
||||
@ApiModelProperty("库存数量")
|
||||
@Excel(name = "库存数量")
|
||||
private BigDecimal stockQuantity;
|
||||
}
|
||||
+67
@@ -0,0 +1,67 @@
|
||||
package com.mhd.oms.domain.reservationOutMaterialDetail.service;
|
||||
|
||||
//import com.mhd.wms.domain.outMaterialDetail.repository.facade.IReservationOutMaterialDetailService;
|
||||
//import com.mhd.wms.domain.outMaterialDetail.repository.po.ReservationOutMaterialDetailPO;
|
||||
//import com.mhd.wms.domain.outMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.facade.IReservationOutMaterialDetailService;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.ReservationOutMaterialDetailPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 物料明细
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class ReservationOutMaterialDetailDomainService {
|
||||
|
||||
@Autowired
|
||||
private IReservationOutMaterialDetailService outMaterialDetailService;
|
||||
|
||||
|
||||
/**
|
||||
* 分页查询物料明细列表
|
||||
*/
|
||||
public List<ReservationOutMaterialDetailPO> queryList(ReservationOutMaterialDetailDO outMaterialDetailDO) {
|
||||
return outMaterialDetailService.queryList(outMaterialDetailDO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增物料明细
|
||||
*/
|
||||
public Boolean insert(ReservationOutMaterialDetailDO outMaterialDetailDO) {
|
||||
|
||||
return outMaterialDetailService.insert(outMaterialDetailDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物料明细
|
||||
*/
|
||||
public Boolean update(ReservationOutMaterialDetailDO outMaterialDetailDO) {
|
||||
return outMaterialDetailService.update(outMaterialDetailDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除物料明细
|
||||
*/
|
||||
public Boolean delete(Long[] materialDetailIds) {
|
||||
return outMaterialDetailService.delete(materialDetailIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物料明细详细信息
|
||||
*/
|
||||
public ReservationOutMaterialDetailPO getInfo(Long materialDetailId)
|
||||
{
|
||||
return outMaterialDetailService.getInfo(materialDetailId);
|
||||
}
|
||||
|
||||
}
|
||||
+27
@@ -352,4 +352,31 @@ public class ReservationStockInOrder extends BaseVOEntity {
|
||||
@ApiModelProperty("订单状态")
|
||||
@Excel(name = "订单状态")
|
||||
private String orderStatus;
|
||||
|
||||
|
||||
@ApiModelProperty( "下发状态 0-无状态 1-未下发 2-已下发 ")
|
||||
private Long issueStatus;
|
||||
|
||||
@ApiModelProperty("下发时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date issueTime;
|
||||
|
||||
@ApiModelProperty("下发人id")
|
||||
private Long issueId;
|
||||
|
||||
@ApiModelProperty("下发人")
|
||||
private String issueName;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private Long reservationAuditId;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private String reservationAuditName;
|
||||
|
||||
@ApiModelProperty("预约审核时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reservationAuditTime;
|
||||
|
||||
}
|
||||
+2
@@ -26,6 +26,8 @@ public interface ReservationStockInOrderMapper extends BaseMapper<ReservationSto
|
||||
|
||||
public MaterialBaseInfoPO getinfo(@Param("id") Long id);
|
||||
|
||||
public List<MaterialBaseInfoPO> getMaterialBaseInfoList(@Param("id") String id);
|
||||
|
||||
public MaterialWarehouseControlPO getInfoByMaterialBaseInfoIds(@Param("id") Long id);
|
||||
|
||||
public MaterialGoodsRulePO getGoodsInfoByMaterialBaseInfoIds(@Param("id") Long id);
|
||||
|
||||
+25
@@ -373,4 +373,29 @@ public class ReservationStockInOrderPO extends BaseVOEntity {
|
||||
@ApiModelProperty("订单状态")
|
||||
@Excel(name = "订单状态")
|
||||
private String orderStatus;
|
||||
|
||||
@ApiModelProperty( "下发状态 0-无状态 1-未下发 2-已下发 ")
|
||||
private Long issueStatus;
|
||||
|
||||
@ApiModelProperty("下发时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date issueTime;
|
||||
|
||||
@ApiModelProperty("下发人id")
|
||||
private Long issueId;
|
||||
|
||||
@ApiModelProperty("下发人")
|
||||
private String issueName;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private Long reservationAuditId;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private String reservationAuditName;
|
||||
|
||||
@ApiModelProperty("预约审核时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reservationAuditTime;
|
||||
}
|
||||
+25
@@ -379,4 +379,29 @@ public class ReservationStockInOrderDO extends BaseVOEntity {
|
||||
|
||||
@ApiModelProperty("入库明细-物料编码,模糊匹配")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty( "下发状态 0-无状态 1-未下发 2-已下发 ")
|
||||
private Long issueStatus;
|
||||
|
||||
@ApiModelProperty("下发时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date issueTime;
|
||||
|
||||
@ApiModelProperty("下发人id")
|
||||
private Long issueId;
|
||||
|
||||
@ApiModelProperty("下发人")
|
||||
private String issueName;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private Long reservationAuditId;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private String reservationAuditName;
|
||||
|
||||
@ApiModelProperty("预约审核时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reservationAuditTime;
|
||||
}
|
||||
+25
@@ -376,4 +376,29 @@ public class ReservationStockInOrderDTO extends ReservationStockInOrderBaseDTO {
|
||||
|
||||
@ApiModelProperty("入库明细-物料编码,模糊匹配,与前端参数 materialCode 一致")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty( "下发状态 0-无状态 1-未下发 2-已下发 ")
|
||||
private Long issueStatus;
|
||||
|
||||
@ApiModelProperty("下发时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date issueTime;
|
||||
|
||||
@ApiModelProperty("下发人id")
|
||||
private Long issueId;
|
||||
|
||||
@ApiModelProperty("下发人")
|
||||
private String issueName;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private Long reservationAuditId;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private String reservationAuditName;
|
||||
|
||||
@ApiModelProperty("预约审核时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reservationAuditTime;
|
||||
}
|
||||
+11
@@ -253,6 +253,17 @@ public class ReservationStockInOrderApplicationService {
|
||||
return stockInOrderDomainService.auditState(stockInOrderDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 下发入库单
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/21 13:53
|
||||
* @param stockInOrderDO
|
||||
* @return Boolean
|
||||
*/
|
||||
public Boolean issueOrder(ReservationStockInOrderDO stockInOrderDO){
|
||||
return stockInOrderDomainService.issueOrder(stockInOrderDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 取消入库单
|
||||
* @author ZhouGY
|
||||
|
||||
+54
-18
@@ -10,6 +10,7 @@ import com.mhd.common.core.utils.StringUtils;
|
||||
import com.mhd.common.core.utils.bean.BeanUtils;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.oms.domain.reservationInMaterialDetail.entity.ReservationInMaterialDetail;
|
||||
import com.mhd.oms.domain.reservationInMaterialDetail.repository.facade.IReservationInMaterialDetailService;
|
||||
import com.mhd.oms.domain.reservationInMaterialDetail.repository.po.ReservationInMaterialDetailPO;
|
||||
import com.mhd.oms.domain.reservationInMaterialDetail.repository.todo.ReservationInMaterialDetailBaseDO;
|
||||
@@ -23,7 +24,10 @@ import com.mhd.oms.domain.reservationStockInOrder.repository.po.MaterialWarehous
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.po.ReservationStockInOrderPO;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.todo.ReservationStockInOrderDO;
|
||||
import com.mhd.system.api.SystemServiceFeign;
|
||||
import com.mhd.system.api.WmsServiceFeign;
|
||||
import com.mhd.system.api.domain.InMaterialDetail;
|
||||
import com.mhd.system.api.domain.PackDetailFeignPO;
|
||||
import com.mhd.system.api.domain.StockInOrder;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
@@ -64,6 +68,8 @@ public class ReservationStockInOrderDomainService {
|
||||
@Autowired
|
||||
private SystemServiceFeign systemServiceFeign;
|
||||
@Autowired
|
||||
private WmsServiceFeign wmsServiceFeign;
|
||||
@Autowired
|
||||
private ReservationStockInOrderMapper reservationStockInOrderMapper;
|
||||
// @Autowired
|
||||
// private IReceiptMaterialDetailService receiptMaterialDetailService;
|
||||
@@ -344,36 +350,66 @@ public class ReservationStockInOrderDomainService {
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean auditState(ReservationStockInOrderDO stockInOrderDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
//统计是否已经审核
|
||||
int count = stockInOrderService.count(new QueryWrapper<ReservationStockInOrder>().lambda()
|
||||
.eq(ReservationStockInOrder::getAuditStatus, 3)
|
||||
.eq(ReservationStockInOrder::getDelFlag, 1)
|
||||
.in(ReservationStockInOrder::getInOrderId, stockInOrderDO.getInOrderIds()));
|
||||
if (count > 0){
|
||||
throw new ServiceException("入库单已审核,请重新选择!");
|
||||
}
|
||||
|
||||
//生成收货单
|
||||
// if (stockInOrderDO.getAuditStatus() == 3){
|
||||
// auditApprove(stockInOrderDO);
|
||||
// }
|
||||
// 获取用户姓名(优先从UserPo获取,如果为空则使用realname,最后使用username作为兜底)
|
||||
String userRealName = loginUser.getUserPo() != null && loginUser.getUserPo().getUserName() != null
|
||||
? loginUser.getUserPo().getUserName()
|
||||
: (loginUser.getRealname() != null ? loginUser.getRealname() : loginUser.getUsername());
|
||||
return stockInOrderService.update(null, new UpdateWrapper<ReservationStockInOrder>().lambda()
|
||||
.set(3 == stockInOrderDO.getAuditStatus(), ReservationStockInOrder::getStatus, 2)
|
||||
.set(ReservationStockInOrder::getAuditStatus, stockInOrderDO.getAuditStatus())
|
||||
.set(ReservationStockInOrder::getAuditRemark, stockInOrderDO.getAuditRemark())
|
||||
.set(ReservationStockInOrder::getAuditBy, loginUser.getUserid())
|
||||
.set(ReservationStockInOrder::getAuditByName, userRealName)
|
||||
.set(ReservationStockInOrder::getAuditTime, new Date())
|
||||
.set(ReservationStockInOrder::getReservationAuditId, loginUser.getUserid())
|
||||
.set(ReservationStockInOrder::getReservationAuditName, userRealName)
|
||||
.set(ReservationStockInOrder::getReservationAuditTime, new Date())
|
||||
.set(ReservationStockInOrder::getUpdateBy, loginUser.getUserid())
|
||||
.set(ReservationStockInOrder::getUpdateByName, userRealName)
|
||||
.set(ReservationStockInOrder::getUpdateTime, new Date())
|
||||
.in(ReservationStockInOrder::getInOrderId, stockInOrderDO.getInOrderIds()));
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 审核入库单
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/21 13:53
|
||||
* @param stockInOrderDO
|
||||
* @return Boolean
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean issueOrder(ReservationStockInOrderDO stockInOrderDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
|
||||
// 获取用户姓名(优先从UserPo获取,如果为空则使用realname,最后使用username作为兜底)
|
||||
String userRealName = loginUser.getUserPo() != null && loginUser.getUserPo().getUserName() != null
|
||||
? loginUser.getUserPo().getUserName()
|
||||
: (loginUser.getRealname() != null ? loginUser.getRealname() : loginUser.getUsername());
|
||||
boolean update = stockInOrderService.update(null, new UpdateWrapper<ReservationStockInOrder>().lambda()
|
||||
.set(ReservationStockInOrder::getIssueId, loginUser.getUserid())
|
||||
.set(ReservationStockInOrder::getIssueName, userRealName)
|
||||
.set(ReservationStockInOrder::getIssueTime, new Date())
|
||||
.set(ReservationStockInOrder::getIssueStatus, 1)
|
||||
.set(ReservationStockInOrder::getUpdateBy, loginUser.getUserid())
|
||||
.set(ReservationStockInOrder::getUpdateByName, userRealName)
|
||||
.set(ReservationStockInOrder::getUpdateTime, new Date())
|
||||
.in(ReservationStockInOrder::getInOrderId, stockInOrderDO.getInOrderIds()));
|
||||
|
||||
//todo下发推送到wms
|
||||
List<Long> inOrderIds = stockInOrderDO.getInOrderIds();
|
||||
for (Long inOrderId : inOrderIds) {
|
||||
ReservationStockInOrder byId = stockInOrderService.getById(inOrderId);
|
||||
StockInOrder stockInOrder = new StockInOrder();
|
||||
BeanUtils.copyProperties(byId, stockInOrder);
|
||||
wmsServiceFeign.omsInOrderAdd(stockInOrder);
|
||||
String inOrderNumber = stockInOrder.getInOrderNumber();
|
||||
List<ReservationInMaterialDetail> materialDetailList = materialDetailService.list(new QueryWrapper<ReservationInMaterialDetail>().lambda().eq(ReservationInMaterialDetail::getInOrderNumber, inOrderNumber));
|
||||
List<InMaterialDetail> inMaterialDetailList = new ArrayList<>();
|
||||
for (ReservationInMaterialDetail reservationInMaterialDetail : materialDetailList) {
|
||||
InMaterialDetail inMaterialDetail = new InMaterialDetail();
|
||||
BeanUtils.copyProperties(reservationInMaterialDetail, inMaterialDetail);
|
||||
inMaterialDetailList.add(inMaterialDetail);
|
||||
}
|
||||
wmsServiceFeign.omsInOrderAddDetail(inMaterialDetailList);
|
||||
}
|
||||
return update;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @description 取消入库单
|
||||
|
||||
+423
@@ -0,0 +1,423 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
|
||||
/**
|
||||
* 出库单对象 reservation_stock_out_order
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ReservationStockOutOrder extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("出库单id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long outOrderId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭 12-已复核")
|
||||
@Excel(name = "出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭 12-已复核")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
@Excel(name = "出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
private Integer auditStatus;
|
||||
|
||||
@ApiModelProperty("出库单审核备注")
|
||||
@Excel(name = "出库单审核备注")
|
||||
private String auditRemark;
|
||||
|
||||
@ApiModelProperty("出库单审核人")
|
||||
@Excel(name = "出库单审核人")
|
||||
private Long auditBy;
|
||||
|
||||
@ApiModelProperty("出库单审核人姓名")
|
||||
@Excel(name = "出库单审核人姓名")
|
||||
private String auditByName;
|
||||
|
||||
@ApiModelProperty("出库单审核时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "出库单审核时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date auditTime;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("出库单类型编码")
|
||||
@Excel(name = "出库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("出库单类型名称")
|
||||
@Excel(name = "出库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("客户id")
|
||||
@Excel(name = "客户id")
|
||||
private Long customerId;
|
||||
|
||||
@ApiModelProperty("客户编码")
|
||||
@Excel(name = "客户编码")
|
||||
private String customerCode;
|
||||
|
||||
@ApiModelProperty("客户名称")
|
||||
@Excel(name = "客户名称")
|
||||
private String customerName;
|
||||
|
||||
@ApiModelProperty("预计出货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计出货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接出库: 1-是 2-否")
|
||||
@Excel(name = "是否直接出库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("是否复核: 1-是 2-否")
|
||||
@Excel(name = "是否复核: 1-是 2-否")
|
||||
private Integer review;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("物料种数")
|
||||
@Excel(name = "物料种数")
|
||||
private Integer materialQuantity;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
|
||||
@ApiModelProperty("已生成拣货单数量")
|
||||
@Excel(name = "已生成拣货单分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("是否取消订单: 1-是 2-否")
|
||||
@Excel(name = "是否取消订单: 1-是 2-否")
|
||||
private Integer cancelOrder;
|
||||
|
||||
@ApiModelProperty("取消订单备注")
|
||||
@Excel(name = "取消订单备注")
|
||||
private String cancelRemark;
|
||||
|
||||
@ApiModelProperty("取消订单人")
|
||||
@Excel(name = "取消订单人")
|
||||
private Long cancelBy;
|
||||
|
||||
@ApiModelProperty("取消订单人姓名")
|
||||
@Excel(name = "取消订单人姓名")
|
||||
private String cancelByName;
|
||||
|
||||
@ApiModelProperty("取消订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "取消订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date cancelTime;
|
||||
|
||||
@ApiModelProperty("是否关闭订单: 1-是 2-否")
|
||||
@Excel(name = "是否关闭订单: 1-是 2-否")
|
||||
private Integer closeOrder;
|
||||
|
||||
@ApiModelProperty("关闭订单备注")
|
||||
@Excel(name = "关闭订单备注")
|
||||
private String closeRemark;
|
||||
|
||||
@ApiModelProperty("关闭订单人")
|
||||
@Excel(name = "关闭订单人")
|
||||
private Long closeBy;
|
||||
|
||||
@ApiModelProperty("关闭订单人姓名")
|
||||
@Excel(name = "关闭订单人姓名")
|
||||
private String closeByName;
|
||||
|
||||
@ApiModelProperty("关闭订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "关闭订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date closeTime;
|
||||
|
||||
@ApiModelProperty("复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
@Excel(name = "复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer checkStatus;
|
||||
|
||||
@ApiModelProperty("复核任务是否下发: 1-是 2-否")
|
||||
@Excel(name = "复核任务是否下发: 1-是 2-否")
|
||||
private Integer checkTaskDistribution;
|
||||
|
||||
@ApiModelProperty("复核任务下发时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "复核任务下发时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date checkTaskDistributionTime;
|
||||
|
||||
@ApiModelProperty("复核作业人用户ID")
|
||||
@Excel(name = "复核作业人用户ID")
|
||||
private Long checkOperatorsBy;
|
||||
|
||||
@ApiModelProperty("复核作业人姓名")
|
||||
@Excel(name = "复核作业人姓名")
|
||||
private String checkOperatorsName;
|
||||
|
||||
@ApiModelProperty("调度单号")
|
||||
@Excel(name = "调度单号")
|
||||
private String mobilizeCode;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("越库单id")
|
||||
private Long overStockId;
|
||||
|
||||
@ApiModelProperty("越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
@Excel(name = "越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
private Integer overStockStatus;
|
||||
|
||||
@ApiModelProperty("越库类型:1-直接越库 2-分拨越库")
|
||||
@Excel(name = "越库类型:1-直接越库 2-分拨越库")
|
||||
private Long overStockType;
|
||||
|
||||
@ApiModelProperty("to")
|
||||
@Excel(name = "to")
|
||||
@TableField(value = "\"TO\"")
|
||||
private String to;
|
||||
|
||||
@ApiModelProperty("联系人")
|
||||
@Excel(name = "联系人")
|
||||
private String contactPerson;
|
||||
|
||||
@ApiModelProperty("车型及车牌")
|
||||
@Excel(name = "车型及车牌")
|
||||
private String vehicleModelPlate;
|
||||
|
||||
@ApiModelProperty("委托编号")
|
||||
@Excel(name = "委托编号")
|
||||
private String entrustNo;
|
||||
|
||||
@ApiModelProperty("Tel")
|
||||
@Excel(name = "Tel")
|
||||
private String tel;
|
||||
|
||||
@ApiModelProperty("司机签名")
|
||||
@Excel(name = "司机签名")
|
||||
private String driverSign;
|
||||
|
||||
@ApiModelProperty("Fax")
|
||||
@Excel(name = "Fax")
|
||||
private String fax;
|
||||
|
||||
@ApiModelProperty("申报地关区")
|
||||
@Excel(name = "申报地关区")
|
||||
private String declareCustoms;
|
||||
|
||||
@ApiModelProperty("生产商")
|
||||
@Excel(name = "生产商")
|
||||
private String manufacturer;
|
||||
|
||||
@ApiModelProperty("报关员姓名及联系方式")
|
||||
@Excel(name = "报关员姓名及联系方式")
|
||||
private String customsDeclarerInfo;
|
||||
|
||||
@ApiModelProperty("送货地址")
|
||||
@Excel(name = "送货地址")
|
||||
private String deliveryAddr;
|
||||
|
||||
@ApiModelProperty("进出境关别")
|
||||
@Excel(name = "进出境关别")
|
||||
private String entryExitCustoms;
|
||||
|
||||
@ApiModelProperty("起运/运抵国(地区)")
|
||||
@Excel(name = "起运/运抵国(地区)")
|
||||
private String departureArrivalCountry;
|
||||
|
||||
@ApiModelProperty("承运商")
|
||||
@Excel(name = "承运商")
|
||||
private String carrier;
|
||||
|
||||
@ApiModelProperty("承运商名称")
|
||||
@Excel(name = "承运商名称")
|
||||
private String carrierName;
|
||||
|
||||
@ApiModelProperty("柜号")
|
||||
@Excel(name = "柜号")
|
||||
private String containerNo;
|
||||
|
||||
@ApiModelProperty("柜")
|
||||
@Excel(name = "柜")
|
||||
private String containerNoName;
|
||||
|
||||
@ApiModelProperty("出仓日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "出仓日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date outboundDate;
|
||||
@ApiModelProperty("完成时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date completeTime;
|
||||
@ApiModelProperty("orderDate")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "orderDate", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date orderDate;
|
||||
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeCode;
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeName;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeCode;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeName;
|
||||
@ApiModelProperty("海关是否查验货物")
|
||||
@Excel(name = "海关是否查验货物")
|
||||
private String customsInspectionFlag;
|
||||
@ApiModelProperty("是否需要报关")
|
||||
@Excel(name = "是否需要报关")
|
||||
private String needDeclareFlag;
|
||||
@ApiModelProperty("是否需要运输")
|
||||
@Excel(name = "是否需要运输")
|
||||
private String needTransportFlag;
|
||||
@ApiModelProperty("app上传的图片")
|
||||
private String pictureApp;
|
||||
|
||||
@ApiModelProperty("业务单号")
|
||||
@Excel(name = "业务单号")
|
||||
private String businessOrderNo;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
@Excel(name = "业务类型")
|
||||
private String businessType;
|
||||
|
||||
@ApiModelProperty("制单人")
|
||||
@Excel(name = "制单人")
|
||||
private String documentCreator;
|
||||
|
||||
@ApiModelProperty("制单人名称")
|
||||
@Excel(name = "制单人名称")
|
||||
private String documentCreatorName;
|
||||
|
||||
@ApiModelProperty("制单日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "制单日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date documentDate;
|
||||
|
||||
@ApiModelProperty( "下发状态 0-无状态 1-未下发 2-已下发 ")
|
||||
private Long issueStatus;
|
||||
|
||||
@ApiModelProperty("下发时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date issueTime;
|
||||
|
||||
@ApiModelProperty("下发人id")
|
||||
private Long issueId;
|
||||
|
||||
@ApiModelProperty("下发人")
|
||||
private String issueName;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private Long reservationAuditId;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private String reservationAuditName;
|
||||
|
||||
@ApiModelProperty("预约审核时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reservationAuditTime;
|
||||
|
||||
}
|
||||
+44
@@ -0,0 +1,44 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.facade;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.entity.ReservationStockOutOrder;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 出库单Service接口
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
public interface IReservationStockOutOrderService extends IService<ReservationStockOutOrder>
|
||||
{
|
||||
/**
|
||||
* 分页查询出库单列表
|
||||
*/
|
||||
public List<ReservationStockOutOrderPO> queryList(ReservationStockOutOrderDO stockOutOrderDO);
|
||||
|
||||
/**
|
||||
* 新增出库单
|
||||
*/
|
||||
public Boolean insert(ReservationStockOutOrderDO stockOutOrderDO);
|
||||
|
||||
/**
|
||||
* 修改出库单
|
||||
*/
|
||||
public Boolean update(ReservationStockOutOrderDO stockOutOrderDO);
|
||||
|
||||
/**
|
||||
* 批量删除出库单
|
||||
*/
|
||||
public Boolean delete(Long[] outOrderIds);
|
||||
|
||||
|
||||
/**
|
||||
* 查询出库单
|
||||
*/
|
||||
public ReservationStockOutOrderPO getInfo(Long outOrderId);
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
//import com.mhd.oms.domain.reservationReservationStockOutOrder.entity.ReservationReservationStockOutOrder;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.entity.ReservationStockOutOrder;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
//import com.mhd.wms.domain.stockOutOrder.entity.ReservationStockOutOrder;
|
||||
//import com.mhd.wms.domain.stockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
//import com.mhd.wms.domain.stockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 出库单Mapper接口
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
public interface ReservationStockOutOrderMapper extends BaseMapper<ReservationStockOutOrder>
|
||||
{
|
||||
/**
|
||||
* 查询出库单列表
|
||||
*/
|
||||
public List<ReservationStockOutOrderPO> queryList(ReservationStockOutOrderDO stockOutOrderDO);
|
||||
|
||||
}
|
||||
+115
@@ -0,0 +1,115 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.persistence;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
//import com.mhd.oms.domain.reservationReservationStockOutOrder.entity.ReservationReservationStockOutOrder;
|
||||
//import com.mhd.oms.domain.reservationReservationStockOutOrder.repository.facade.IReservationReservationStockOutOrderService;
|
||||
//import com.mhd.oms.domain.reservationReservationStockOutOrder.repository.mapper.ReservationReservationStockOutOrderMapper;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.entity.ReservationStockOutOrder;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.facade.IReservationStockOutOrderService;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.mapper.ReservationStockOutOrderMapper;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
//import com.mhd.wms.domain.deliveTask.repository.facade.IDeliveTaskTypeService;
|
||||
//import com.mhd.wms.domain.deliveTask.repository.todo.DeliveTaskDO;
|
||||
//import com.mhd.wms.domain.stockOutOrder.entity.ReservationStockOutOrder;
|
||||
//import com.mhd.wms.domain.stockOutOrder.repository.facade.IReservationStockOutOrderService;
|
||||
//import com.mhd.wms.domain.stockOutOrder.repository.mapper.ReservationStockOutOrderMapper;
|
||||
//import com.mhd.wms.domain.stockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
//import com.mhd.wms.domain.stockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 出库单Service业务层处理
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
@Service
|
||||
public class ReservationStockOutOrderImpl extends ServiceImpl<ReservationStockOutOrderMapper, ReservationStockOutOrder> implements IReservationStockOutOrderService {
|
||||
@Autowired
|
||||
private ReservationStockOutOrderMapper reservationStockOutOrderMapper;
|
||||
|
||||
/**
|
||||
* 查询出库单列表
|
||||
*/
|
||||
@Override
|
||||
public List<ReservationStockOutOrderPO> queryList(ReservationStockOutOrderDO stockOutOrderDO)
|
||||
{
|
||||
return reservationStockOutOrderMapper.queryList(stockOutOrderDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增出库单
|
||||
*/
|
||||
@Override
|
||||
public Boolean insert(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
ReservationStockOutOrder stockOutOrder = new ReservationStockOutOrder();
|
||||
BeanUtils.copyProperties(stockOutOrderDO,stockOutOrder);
|
||||
return this.save(stockOutOrder);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改出库单
|
||||
*/
|
||||
@Override
|
||||
public Boolean update(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
ReservationStockOutOrder stockOutOrder = new ReservationStockOutOrder();
|
||||
BeanUtils.copyProperties(stockOutOrderDO,stockOutOrder);
|
||||
return this.updateById(stockOutOrder);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除出库单
|
||||
*/
|
||||
@Override
|
||||
public Boolean delete(Long[] outOrderIds ) {
|
||||
List<ReservationStockOutOrder> list = new ArrayList<>();
|
||||
for (Long id : outOrderIds) {
|
||||
ReservationStockOutOrder stockOutOrder = new ReservationStockOutOrder();
|
||||
stockOutOrder.setOutOrderId(id);
|
||||
stockOutOrder.setDelFlag(2);
|
||||
list.add(stockOutOrder);
|
||||
}
|
||||
return this.updateBatchById(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改出库单
|
||||
*/
|
||||
@Override
|
||||
public ReservationStockOutOrderPO getInfo(Long outOrderId) {
|
||||
ReservationStockOutOrder stockOutOrder = this.getById(outOrderId);
|
||||
ReservationStockOutOrderPO stockOutOrderPO = new ReservationStockOutOrderPO();
|
||||
BeanUtils.copyProperties(stockOutOrder,stockOutOrderPO);
|
||||
return stockOutOrderPO;
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 更新订单任务下发状态
|
||||
* @author ZhouGY
|
||||
* @date 2024/8/1 13:56
|
||||
* @param deliveTaskDO
|
||||
* @return Boolean
|
||||
*/
|
||||
// @Override
|
||||
// public Boolean handleDeliveTask(DeliveTaskDO deliveTaskDO) {
|
||||
// LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
// //标记收货单任务已下发
|
||||
// return update(null, new UpdateWrapper<ReservationStockOutOrder>().lambda()
|
||||
// .set(ReservationStockOutOrder::getCheckOperatorsBy, deliveTaskDO.getOperatorsBy())
|
||||
// .set(ReservationStockOutOrder::getCheckOperatorsName, deliveTaskDO.getOperatorsName())
|
||||
// .set(ReservationStockOutOrder::getUpdateBy, loginUser.getUserid())
|
||||
// .set(ReservationStockOutOrder::getUpdateByName, loginUser.getUsername())
|
||||
// .set(ReservationStockOutOrder::getUpdateTime, new Date())
|
||||
// .eq(ReservationStockOutOrder::getOutOrderNumber, deliveTaskDO.getTrackingNumber()));
|
||||
// }
|
||||
}
|
||||
+103
@@ -0,0 +1,103 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.po;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @author ZhouGY
|
||||
* @title StockInOrderBasePO
|
||||
* @description: TODO
|
||||
* @date 2024/5/22 11:50
|
||||
**/
|
||||
@Data
|
||||
public class ReservationStockOutOrderBasePO extends BaseVOEntity {
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("出库单类型编码")
|
||||
@Excel(name = "出库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("出库单类型名称")
|
||||
@Excel(name = "出库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("客户id")
|
||||
@Excel(name = "客户id")
|
||||
private Long customerId;
|
||||
|
||||
@ApiModelProperty("客户编码")
|
||||
@Excel(name = "客户编码")
|
||||
private String customerCode;
|
||||
|
||||
@ApiModelProperty("客户名称")
|
||||
@Excel(name = "客户名称")
|
||||
private String customerName;
|
||||
|
||||
@ApiModelProperty("预计出货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计出货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接出库: 1-是 2-否")
|
||||
@Excel(name = "是否直接出库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("是否复核: 1-是 2-否")
|
||||
@Excel(name = "是否复核: 1-是 2-否")
|
||||
private Integer review;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
}
|
||||
+434
@@ -0,0 +1,434 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.po;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.ReservationOutMaterialDetailPO;
|
||||
//import com.mhd.wms.domain.outMaterialDetail.repository.po.OutMaterialCheckPO;
|
||||
//import com.mhd.wms.domain.outMaterialDetail.repository.po.OutMaterialDetailPO;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 出库单对象 stock_out_order
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
|
||||
@Data
|
||||
@ApiModel(value = "出库单对象", description = "出库单响应对象")
|
||||
public class ReservationStockOutOrderPO extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("出库单id")
|
||||
private Long outOrderId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭")
|
||||
@Excel(name = "出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
@Excel(name = "出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
private Integer auditStatus;
|
||||
|
||||
@ApiModelProperty("出库单审核备注")
|
||||
@Excel(name = "出库单审核备注")
|
||||
private String auditRemark;
|
||||
|
||||
@ApiModelProperty("出库单审核人")
|
||||
@Excel(name = "出库单审核人")
|
||||
private Long auditBy;
|
||||
|
||||
@ApiModelProperty("出库单审核人姓名")
|
||||
@Excel(name = "出库单审核人姓名")
|
||||
private String auditByName;
|
||||
|
||||
@ApiModelProperty("出库单审核时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "出库单审核时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date auditTime;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("出库单类型编码")
|
||||
@Excel(name = "出库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("出库单类型名称")
|
||||
@Excel(name = "出库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("客户id")
|
||||
@Excel(name = "客户id")
|
||||
private Long customerId;
|
||||
|
||||
@ApiModelProperty("客户编码")
|
||||
@Excel(name = "客户编码")
|
||||
private String customerCode;
|
||||
|
||||
@ApiModelProperty("客户名称")
|
||||
@Excel(name = "客户名称")
|
||||
private String customerName;
|
||||
|
||||
@ApiModelProperty("预计出货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计出货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接出库: 1-是 2-否")
|
||||
@Excel(name = "是否直接出库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("是否复核: 1-是 2-否")
|
||||
@Excel(name = "是否复核: 1-是 2-否")
|
||||
private Integer review;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("物料种数")
|
||||
@Excel(name = "物料种数")
|
||||
private Integer materialQuantity;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
|
||||
@ApiModelProperty("已生成拣货单数量")
|
||||
@Excel(name = "已生成拣货单分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("是否取消订单: 1-是 2-否")
|
||||
@Excel(name = "是否取消订单: 1-是 2-否")
|
||||
private Integer cancelOrder;
|
||||
|
||||
@ApiModelProperty("取消订单备注")
|
||||
@Excel(name = "取消订单备注")
|
||||
private String cancelRemark;
|
||||
|
||||
@ApiModelProperty("取消订单人")
|
||||
@Excel(name = "取消订单人")
|
||||
private Long cancelBy;
|
||||
|
||||
@ApiModelProperty("取消订单人姓名")
|
||||
@Excel(name = "取消订单人姓名")
|
||||
private String cancelByName;
|
||||
|
||||
@ApiModelProperty("取消订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "取消订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date cancelTime;
|
||||
|
||||
@ApiModelProperty("是否关闭订单: 1-是 2-否")
|
||||
@Excel(name = "是否关闭订单: 1-是 2-否")
|
||||
private Integer closeOrder;
|
||||
|
||||
@ApiModelProperty("关闭订单备注")
|
||||
@Excel(name = "关闭订单备注")
|
||||
private String closeRemark;
|
||||
|
||||
@ApiModelProperty("关闭订单人")
|
||||
@Excel(name = "关闭订单人")
|
||||
private Long closeBy;
|
||||
|
||||
@ApiModelProperty("关闭订单人姓名")
|
||||
@Excel(name = "关闭订单人姓名")
|
||||
private String closeByName;
|
||||
|
||||
@ApiModelProperty("关闭订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "关闭订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date closeTime;
|
||||
|
||||
@ApiModelProperty("复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
@Excel(name = "复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer checkStatus;
|
||||
|
||||
@ApiModelProperty("复核任务是否下发: 1-是 2-否")
|
||||
@Excel(name = "复核任务是否下发: 1-是 2-否")
|
||||
private Integer checkTaskDistribution;
|
||||
|
||||
@ApiModelProperty("复核任务下发时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "复核任务下发时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date checkTaskDistributionTime;
|
||||
|
||||
@ApiModelProperty("复核作业人用户ID")
|
||||
@Excel(name = "复核作业人用户ID")
|
||||
private Long checkOperatorsBy;
|
||||
|
||||
@ApiModelProperty("复核作业人姓名")
|
||||
@Excel(name = "复核作业人姓名")
|
||||
private String checkOperatorsName;
|
||||
|
||||
@ApiModelProperty("调度单号")
|
||||
@Excel(name = "调度单号")
|
||||
private String mobilizeCode;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("物料明细")
|
||||
private List<ReservationOutMaterialDetailPO> materialDetailList;
|
||||
//
|
||||
// @ApiModelProperty("出库单复核统计")
|
||||
// private ReservationOutMaterialCheckPO outMaterialCheckPO;
|
||||
|
||||
@ApiModelProperty("越库单id")
|
||||
private Long overStockId;
|
||||
|
||||
@ApiModelProperty("越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
@Excel(name = "越库单状态 0:无状态 1:处理中 2:越库完成")
|
||||
private Integer overStockStatus;
|
||||
|
||||
@ApiModelProperty("越库类型:1-直接越库 2-分拨越库")
|
||||
@Excel(name = "越库类型:1-直接越库 2-分拨越库")
|
||||
private Long overStockType;
|
||||
|
||||
|
||||
@ApiModelProperty("to")
|
||||
@Excel(name = "to")
|
||||
private String to;
|
||||
|
||||
@ApiModelProperty("联系人")
|
||||
@Excel(name = "联系人")
|
||||
private String contactPerson;
|
||||
|
||||
@ApiModelProperty("车型及车牌")
|
||||
@Excel(name = "车型及车牌")
|
||||
private String vehicleModelPlate;
|
||||
|
||||
@ApiModelProperty("委托编号")
|
||||
@Excel(name = "委托编号")
|
||||
private String entrustNo;
|
||||
|
||||
@ApiModelProperty("Tel")
|
||||
@Excel(name = "Tel")
|
||||
private String tel;
|
||||
|
||||
@ApiModelProperty("司机签名")
|
||||
@Excel(name = "司机签名")
|
||||
private String driverSign;
|
||||
|
||||
@ApiModelProperty("Fax")
|
||||
@Excel(name = "Fax")
|
||||
private String fax;
|
||||
|
||||
@ApiModelProperty("申报地关区")
|
||||
@Excel(name = "申报地关区")
|
||||
private String declareCustoms;
|
||||
|
||||
@ApiModelProperty("生产商")
|
||||
@Excel(name = "生产商")
|
||||
private String manufacturer;
|
||||
|
||||
@ApiModelProperty("报关员姓名及联系方式")
|
||||
@Excel(name = "报关员姓名及联系方式")
|
||||
private String customsDeclarerInfo;
|
||||
|
||||
@ApiModelProperty("送货地址")
|
||||
@Excel(name = "送货地址")
|
||||
private String deliveryAddr;
|
||||
|
||||
@ApiModelProperty("进出境关别")
|
||||
@Excel(name = "进出境关别")
|
||||
private String entryExitCustoms;
|
||||
|
||||
@ApiModelProperty("起运/运抵国(地区)")
|
||||
@Excel(name = "起运/运抵国(地区)")
|
||||
private String departureArrivalCountry;
|
||||
|
||||
@ApiModelProperty("承运商")
|
||||
@Excel(name = "承运商")
|
||||
private String carrier;
|
||||
|
||||
@ApiModelProperty("柜号")
|
||||
@Excel(name = "柜号")
|
||||
private String containerNo;
|
||||
|
||||
@ApiModelProperty("柜")
|
||||
@Excel(name = "柜")
|
||||
private String containerNoName;
|
||||
|
||||
@ApiModelProperty("出仓日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "出仓日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date outboundDate;
|
||||
@ApiModelProperty("完成时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date completeTime;
|
||||
@ApiModelProperty("orderDate")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "orderDate", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date orderDate;
|
||||
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeCode;
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeName;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeCode;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeName;
|
||||
@ApiModelProperty("海关是否查验货物")
|
||||
@Excel(name = "海关是否查验货物")
|
||||
private String customsInspectionFlag;
|
||||
@ApiModelProperty("是否需要报关")
|
||||
@Excel(name = "是否需要报关")
|
||||
private String needDeclareFlag;
|
||||
@ApiModelProperty("是否需要运输")
|
||||
@Excel(name = "是否需要运输")
|
||||
private String needTransportFlag;
|
||||
|
||||
@ApiModelProperty("出库交接图片,PDA出库交接时上传的照片,多张图片以逗号隔开")
|
||||
private String pictureApp;
|
||||
|
||||
@ApiModelProperty("出库总数量")
|
||||
private BigDecimal totalOutboundQuantity;
|
||||
|
||||
|
||||
@ApiModelProperty("业务单号")
|
||||
@Excel(name = "业务单号")
|
||||
private String businessOrderNo;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
@Excel(name = "业务类型")
|
||||
private String businessType;
|
||||
|
||||
@ApiModelProperty("制单人")
|
||||
@Excel(name = "制单人")
|
||||
private String documentCreator;
|
||||
|
||||
@ApiModelProperty("制单人名称")
|
||||
@Excel(name = "制单人名称")
|
||||
private String documentCreatorName;
|
||||
|
||||
@ApiModelProperty("制单日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "制单日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date documentDate;
|
||||
@ApiModelProperty("承运商名称")
|
||||
@Excel(name = "承运商名称")
|
||||
private String carrierName;
|
||||
|
||||
@ApiModelProperty( "下发状态 0-无状态 1-未下发 2-已下发 ")
|
||||
private Long issueStatus;
|
||||
|
||||
@ApiModelProperty("下发时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date issueTime;
|
||||
|
||||
@ApiModelProperty("下发人id")
|
||||
private Long issueId;
|
||||
|
||||
@ApiModelProperty("下发人")
|
||||
private String issueName;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private Long reservationAuditId;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private String reservationAuditName;
|
||||
|
||||
@ApiModelProperty("预约审核时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reservationAuditTime;
|
||||
}
|
||||
+73
@@ -0,0 +1,73 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.todo;
|
||||
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* @author ZhouGY
|
||||
* @title AllocationSowingWallDO
|
||||
* @description: 播种分货
|
||||
* @date 2024/6/5 14:29
|
||||
**/
|
||||
@Data
|
||||
public class AllocationByOrderDO implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("物料编码/物料条码/序列号")
|
||||
@Excel(name = "物料编码/物料条码/序列号")
|
||||
private String materialNumber;
|
||||
|
||||
@ApiModelProperty("是否单件扫描:1-是 2-否")
|
||||
@Excel(name = "是否单件扫描:1-是 2-否")
|
||||
private Integer singleScan;
|
||||
|
||||
@ApiModelProperty("数量EA")
|
||||
@Excel(name = "数量EA")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("集货仓库id")
|
||||
@Excel(name = "集货仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("集货仓库编码")
|
||||
@Excel(name = "集货仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("集货仓库名称")
|
||||
@Excel(name = "集货仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("集货库区id")
|
||||
@Excel(name = "集货库区id")
|
||||
private Long storageSectionId;
|
||||
|
||||
@ApiModelProperty("集货库区编码")
|
||||
@Excel(name = "集货库区编码")
|
||||
private String storageCode;
|
||||
|
||||
@ApiModelProperty("集货库区名称")
|
||||
@Excel(name = "集货库区名称")
|
||||
private String storageName;
|
||||
|
||||
@ApiModelProperty("集货库位id")
|
||||
@Excel(name = "集货库位id")
|
||||
private Long storageLocationId;
|
||||
|
||||
@ApiModelProperty("集货库位编码")
|
||||
@Excel(name = "集货库位编码")
|
||||
private String storageLocationCode;
|
||||
|
||||
@ApiModelProperty("集货库位名称")
|
||||
@Excel(name = "集货库位名称")
|
||||
private String storageLocationName;
|
||||
|
||||
}
|
||||
+109
@@ -0,0 +1,109 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.todo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
//import com.mhd.wms.domain.outMaterialDetail.repository.todo.OutMaterialDetailDO;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author ZhouGY
|
||||
* @title StockInOrderBasePO
|
||||
* @description: TODO
|
||||
* @date 2024/5/22 11:50
|
||||
**/
|
||||
@Data
|
||||
public class ReservationStockOutOrderBaseDO extends BaseVOEntity {
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("入库单类型编码")
|
||||
@Excel(name = "入库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("入库单类型名称")
|
||||
@Excel(name = "入库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("供应商id")
|
||||
@Excel(name = "供应商id")
|
||||
private Long supplierId;
|
||||
|
||||
@ApiModelProperty("供应商编码")
|
||||
@Excel(name = "供应商编码")
|
||||
private String supplierCode;
|
||||
|
||||
@ApiModelProperty("供应商名称")
|
||||
@Excel(name = "供应商名称")
|
||||
private String supplierName;
|
||||
|
||||
@ApiModelProperty("预计到货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计到货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接入库: 1-是 2-否")
|
||||
@Excel(name = "是否直接入库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("物料明细")
|
||||
private List<ReservationOutMaterialDetailDO> materialDetailList;
|
||||
}
|
||||
+103
@@ -0,0 +1,103 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.todo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @author ZhouGY
|
||||
* @title StockInOrderBasePO
|
||||
* @description: TODO
|
||||
* @date 2024/5/22 11:50
|
||||
**/
|
||||
@Data
|
||||
public class ReservationStockOutOrderBaseDTO extends BaseVOEntity {
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("入库单号")
|
||||
@Excel(name = "入库单号")
|
||||
private String inOrderNumber;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("入库单类型编码")
|
||||
@Excel(name = "入库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("入库单类型名称")
|
||||
@Excel(name = "入库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("供应商id")
|
||||
@Excel(name = "供应商id")
|
||||
private Long supplierId;
|
||||
|
||||
@ApiModelProperty("供应商编码")
|
||||
@Excel(name = "供应商编码")
|
||||
private String supplierCode;
|
||||
|
||||
@ApiModelProperty("供应商名称")
|
||||
@Excel(name = "供应商名称")
|
||||
private String supplierName;
|
||||
|
||||
@ApiModelProperty("预计到货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计到货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接入库: 1-是 2-否")
|
||||
@Excel(name = "是否直接入库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
}
|
||||
+470
@@ -0,0 +1,470 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.todo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
//import com.mhd.wms.domain.outMaterialDetail.repository.todo.OutMaterialDetailDO;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 出库单对象 stock_out_order
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ReservationStockOutOrderDO extends BaseVOEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("出库单id")
|
||||
private Long outOrderId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭")
|
||||
@Excel(name = "出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
@Excel(name = "出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
private Integer auditStatus;
|
||||
|
||||
@ApiModelProperty("出库单审核备注")
|
||||
@Excel(name = "出库单审核备注")
|
||||
private String auditRemark;
|
||||
|
||||
@ApiModelProperty("出库单审核人")
|
||||
@Excel(name = "出库单审核人")
|
||||
private Long auditBy;
|
||||
|
||||
@ApiModelProperty("出库单审核人姓名")
|
||||
@Excel(name = "出库单审核人姓名")
|
||||
private String auditByName;
|
||||
|
||||
@ApiModelProperty("出库单审核时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "出库单审核时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date auditTime;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("出库单类型编码")
|
||||
@Excel(name = "出库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("出库单类型名称")
|
||||
@Excel(name = "出库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("客户id")
|
||||
@Excel(name = "客户id")
|
||||
private Long customerId;
|
||||
|
||||
@ApiModelProperty("客户编码")
|
||||
@Excel(name = "客户编码")
|
||||
private String customerCode;
|
||||
|
||||
@ApiModelProperty("客户名称")
|
||||
@Excel(name = "客户名称")
|
||||
private String customerName;
|
||||
|
||||
@ApiModelProperty("预计出货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计出货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接出库: 1-是 2-否")
|
||||
@Excel(name = "是否直接出库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("是否复核: 1-是 2-否")
|
||||
@Excel(name = "是否复核: 1-是 2-否")
|
||||
private Integer review;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("物料种数")
|
||||
@Excel(name = "物料种数")
|
||||
private Integer materialQuantity;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
|
||||
@ApiModelProperty("已生成拣货单数量")
|
||||
@Excel(name = "已生成拣货单分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("是否取消订单: 1-是 2-否")
|
||||
@Excel(name = "是否取消订单: 1-是 2-否")
|
||||
private Integer cancelOrder;
|
||||
|
||||
@ApiModelProperty("取消订单备注")
|
||||
@Excel(name = "取消订单备注")
|
||||
private String cancelRemark;
|
||||
|
||||
@ApiModelProperty("取消订单人")
|
||||
@Excel(name = "取消订单人")
|
||||
private Long cancelBy;
|
||||
|
||||
@ApiModelProperty("取消订单人姓名")
|
||||
@Excel(name = "取消订单人姓名")
|
||||
private String cancelByName;
|
||||
|
||||
@ApiModelProperty("取消订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "取消订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date cancelTime;
|
||||
|
||||
@ApiModelProperty("是否关闭订单: 1-是 2-否")
|
||||
@Excel(name = "是否关闭订单: 1-是 2-否")
|
||||
private Integer closeOrder;
|
||||
|
||||
@ApiModelProperty("关闭订单备注")
|
||||
@Excel(name = "关闭订单备注")
|
||||
private String closeRemark;
|
||||
|
||||
@ApiModelProperty("关闭订单人")
|
||||
@Excel(name = "关闭订单人")
|
||||
private Long closeBy;
|
||||
|
||||
@ApiModelProperty("关闭订单人姓名")
|
||||
@Excel(name = "关闭订单人姓名")
|
||||
private String closeByName;
|
||||
|
||||
@ApiModelProperty("关闭订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "关闭订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date closeTime;
|
||||
|
||||
@ApiModelProperty("复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
@Excel(name = "复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer checkStatus;
|
||||
|
||||
@ApiModelProperty("复核任务是否下发: 1-是 2-否")
|
||||
@Excel(name = "复核任务是否下发: 1-是 2-否")
|
||||
private Integer checkTaskDistribution;
|
||||
|
||||
@ApiModelProperty("复核任务下发时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "复核任务下发时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date checkTaskDistributionTime;
|
||||
|
||||
@ApiModelProperty("复核作业人用户ID")
|
||||
@Excel(name = "复核作业人用户ID")
|
||||
private Long checkOperatorsBy;
|
||||
|
||||
@ApiModelProperty("复核作业人姓名")
|
||||
@Excel(name = "复核作业人姓名")
|
||||
private String checkOperatorsName;
|
||||
|
||||
@ApiModelProperty("调度单号")
|
||||
@Excel(name = "调度单号")
|
||||
private String mobilizeCode;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(name = "组织ID集合")
|
||||
private List<Long> organizationIdList;
|
||||
|
||||
@ApiModelProperty(name = "权限菜单ID")
|
||||
private Long permissionMenuId;
|
||||
|
||||
@ApiModelProperty("出库单id集合")
|
||||
private List<Long> outOrderIds;
|
||||
|
||||
@ApiModelProperty("物料明细")
|
||||
private List<ReservationOutMaterialDetailDO> materialDetailList;
|
||||
|
||||
@ApiModelProperty("物料条形码")
|
||||
@Excel(name = "物料条形码")
|
||||
private String barCode;
|
||||
|
||||
@ApiModelProperty("序列号")
|
||||
@Excel(name = "序列号")
|
||||
private String serialNumber;
|
||||
|
||||
@ApiModelProperty("物料审核数量")
|
||||
@Excel(name = "物料审核数量")
|
||||
private BigDecimal actualQuantity;
|
||||
|
||||
@ApiModelProperty("波次类型编码")
|
||||
private String waveOrderTypeCode;
|
||||
|
||||
@ApiModelProperty("出库状态大于某个状态")
|
||||
private Integer gtStatus;
|
||||
|
||||
@ApiModelProperty("出库状态小于某个状态")
|
||||
private Integer ltStatus;
|
||||
|
||||
@ApiModelProperty("大于复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer gtCheckStatus;
|
||||
|
||||
@ApiModelProperty("小于复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer ltCheckStatus;
|
||||
|
||||
@ApiModelProperty("PDA复核查询tab: 1-列表(待复核) 2-历史记录(已复核)")
|
||||
private Integer tabType;
|
||||
|
||||
@ApiModelProperty("to")
|
||||
@Excel(name = "to")
|
||||
private String to;
|
||||
|
||||
@ApiModelProperty("联系人")
|
||||
@Excel(name = "联系人")
|
||||
private String contactPerson;
|
||||
|
||||
@ApiModelProperty("车型及车牌")
|
||||
@Excel(name = "车型及车牌")
|
||||
private String vehicleModelPlate;
|
||||
|
||||
@ApiModelProperty("委托编号")
|
||||
@Excel(name = "委托编号")
|
||||
private String entrustNo;
|
||||
|
||||
@ApiModelProperty("Tel")
|
||||
@Excel(name = "Tel")
|
||||
private String tel;
|
||||
|
||||
@ApiModelProperty("司机签名")
|
||||
@Excel(name = "司机签名")
|
||||
private String driverSign;
|
||||
|
||||
@ApiModelProperty("Fax")
|
||||
@Excel(name = "Fax")
|
||||
private String fax;
|
||||
|
||||
@ApiModelProperty("申报地关区")
|
||||
@Excel(name = "申报地关区")
|
||||
private String declareCustoms;
|
||||
|
||||
@ApiModelProperty("生产商")
|
||||
@Excel(name = "生产商")
|
||||
private String manufacturer;
|
||||
|
||||
@ApiModelProperty("报关员姓名及联系方式")
|
||||
@Excel(name = "报关员姓名及联系方式")
|
||||
private String customsDeclarerInfo;
|
||||
|
||||
@ApiModelProperty("送货地址")
|
||||
@Excel(name = "送货地址")
|
||||
private String deliveryAddr;
|
||||
|
||||
@ApiModelProperty("进出境关别")
|
||||
@Excel(name = "进出境关别")
|
||||
private String entryExitCustoms;
|
||||
|
||||
@ApiModelProperty("起运/运抵国(地区)")
|
||||
@Excel(name = "起运/运抵国(地区)")
|
||||
private String departureArrivalCountry;
|
||||
|
||||
@ApiModelProperty("承运商")
|
||||
@Excel(name = "承运商")
|
||||
private String carrier;
|
||||
|
||||
@ApiModelProperty("柜号")
|
||||
@Excel(name = "柜号")
|
||||
private String containerNo;
|
||||
|
||||
@ApiModelProperty("柜")
|
||||
@Excel(name = "柜")
|
||||
private String containerNoName;
|
||||
|
||||
@ApiModelProperty("出仓日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "出仓日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date outboundDate;
|
||||
@ApiModelProperty("完成时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date completeTime;
|
||||
@ApiModelProperty("orderDate")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "orderDate", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date orderDate;
|
||||
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeCode;
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeName;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeCode;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeName;
|
||||
@ApiModelProperty("海关是否查验货物")
|
||||
@Excel(name = "海关是否查验货物")
|
||||
private String customsInspectionFlag;
|
||||
@ApiModelProperty("是否需要报关")
|
||||
@Excel(name = "是否需要报关")
|
||||
private String needDeclareFlag;
|
||||
@ApiModelProperty("是否需要运输")
|
||||
@Excel(name = "是否需要运输")
|
||||
private String needTransportFlag;
|
||||
|
||||
@ApiModelProperty(name = "创建时间查询条件开始日期")
|
||||
private String createTimeStart;
|
||||
|
||||
@ApiModelProperty(name = "创建时间查询条件结束日期")
|
||||
private String createTimeEnd;
|
||||
|
||||
@ApiModelProperty(name = "审核时间查询条件开始日期")
|
||||
private String auditTimeStart;
|
||||
|
||||
@ApiModelProperty(name = "审核时间查询条件结束日期")
|
||||
private String auditTimeEnd;
|
||||
|
||||
@ApiModelProperty("出库明细-物料名称(商品名称),模糊匹配")
|
||||
private String materialName;
|
||||
|
||||
@ApiModelProperty("出库明细-物料编码,模糊匹配")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty(name = "已分配数量总数量")
|
||||
private BigDecimal alreadyAllocationQuantityAll;
|
||||
|
||||
|
||||
@ApiModelProperty("业务单号")
|
||||
@Excel(name = "业务单号")
|
||||
private String businessOrderNo;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
@Excel(name = "业务类型")
|
||||
private String businessType;
|
||||
|
||||
@ApiModelProperty("制单人")
|
||||
@Excel(name = "制单人")
|
||||
private String documentCreator;
|
||||
|
||||
@ApiModelProperty("制单人名称")
|
||||
@Excel(name = "制单人名称")
|
||||
private String documentCreatorName;
|
||||
|
||||
@ApiModelProperty("制单日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "制单日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date documentDate;
|
||||
@ApiModelProperty("承运商名称")
|
||||
@Excel(name = "承运商名称")
|
||||
private String carrierName;
|
||||
|
||||
@ApiModelProperty( "下发状态 0-无状态 1-未下发 2-已下发 ")
|
||||
private Long issueStatus;
|
||||
|
||||
@ApiModelProperty("下发时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date issueTime;
|
||||
|
||||
@ApiModelProperty("下发人id")
|
||||
private Long issueId;
|
||||
|
||||
@ApiModelProperty("下发人")
|
||||
private String issueName;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private Long reservationAuditId;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private String reservationAuditName;
|
||||
|
||||
@ApiModelProperty("预约审核时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reservationAuditTime;
|
||||
}
|
||||
+459
@@ -0,0 +1,459 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.repository.todo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonAlias;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
//import com.mhd.wms.interfaces.dto.outMaterialDetail.OutMaterialDetailDTO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDTO;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 出库单对象 stock_out_order
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ReservationStockOutOrderDTO extends ReservationStockOutOrderBaseDTO {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("出库单id")
|
||||
private Long outOrderId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("通知单号")
|
||||
@Excel(name = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty("出库单号")
|
||||
@Excel(name = "出库单号")
|
||||
private String outOrderNumber;
|
||||
|
||||
@ApiModelProperty("出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭")
|
||||
@Excel(name = "出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-波次中 6-拣货中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭")
|
||||
private Integer status;
|
||||
|
||||
@ApiModelProperty("出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
@Excel(name = "出库单审核状态: 1-未审核 2-审核不通过 3-审核通过")
|
||||
private Integer auditStatus;
|
||||
|
||||
@ApiModelProperty("出库单审核备注")
|
||||
@Excel(name = "出库单审核备注")
|
||||
private String auditRemark;
|
||||
|
||||
@ApiModelProperty("出库单审核人")
|
||||
@Excel(name = "出库单审核人")
|
||||
private Long auditBy;
|
||||
|
||||
@ApiModelProperty("出库单审核人姓名")
|
||||
@Excel(name = "出库单审核人姓名")
|
||||
private String auditByName;
|
||||
|
||||
@ApiModelProperty("出库单审核时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "出库单审核时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date auditTime;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
@Excel(name = "货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主编码")
|
||||
@Excel(name = "货主编码")
|
||||
private String shipperCode;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
@Excel(name = "货主名称")
|
||||
private String shipperName;
|
||||
|
||||
@ApiModelProperty("出库单类型编码")
|
||||
@Excel(name = "出库单类型编码")
|
||||
private String orderTypeCode;
|
||||
|
||||
@ApiModelProperty("出库单类型名称")
|
||||
@Excel(name = "出库单类型名称")
|
||||
private String orderTypeName;
|
||||
|
||||
@ApiModelProperty("客户id")
|
||||
@Excel(name = "客户id")
|
||||
private Long customerId;
|
||||
|
||||
@ApiModelProperty("客户编码")
|
||||
@Excel(name = "客户编码")
|
||||
private String customerCode;
|
||||
|
||||
@ApiModelProperty("客户名称")
|
||||
@Excel(name = "客户名称")
|
||||
private String customerName;
|
||||
|
||||
@ApiModelProperty("预计出货时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "预计出货时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date expectTime;
|
||||
|
||||
@ApiModelProperty("供应链订单号")
|
||||
@Excel(name = "供应链订单号")
|
||||
private String supplyChainNumber;
|
||||
|
||||
@ApiModelProperty("优先级别编码")
|
||||
@Excel(name = "优先级别编码")
|
||||
private String priorityLevelCode;
|
||||
|
||||
@ApiModelProperty("优先级别名称")
|
||||
@Excel(name = "优先级别名称")
|
||||
private String priorityLevelName;
|
||||
|
||||
@ApiModelProperty("是否直接出库: 1-是 2-否")
|
||||
@Excel(name = "是否直接出库: 1-是 2-否")
|
||||
private Integer directWarehouse;
|
||||
|
||||
@ApiModelProperty("是否复核: 1-是 2-否")
|
||||
@Excel(name = "是否复核: 1-是 2-否")
|
||||
private Integer review;
|
||||
|
||||
@ApiModelProperty("附件url")
|
||||
@Excel(name = "附件url")
|
||||
private String annexUrl;
|
||||
|
||||
@ApiModelProperty("物料种数")
|
||||
@Excel(name = "物料种数")
|
||||
private Integer materialQuantity;
|
||||
|
||||
@ApiModelProperty("计划数量")
|
||||
@Excel(name = "计划数量")
|
||||
private BigDecimal quantity;
|
||||
|
||||
@ApiModelProperty("净重 单位:千克")
|
||||
@Excel(name = "净重 单位:千克")
|
||||
private BigDecimal weightLimit;
|
||||
|
||||
@ApiModelProperty("体积 单位:立方米")
|
||||
@Excel(name = "体积 单位:立方米")
|
||||
private BigDecimal volumeLimit;
|
||||
|
||||
@ApiModelProperty("分配数量")
|
||||
@Excel(name = "分配数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
|
||||
@ApiModelProperty("已生成拣货单数量")
|
||||
@Excel(name = "已生成拣货单分配数量")
|
||||
private BigDecimal alreadyAllocationQuantity;
|
||||
|
||||
@ApiModelProperty("拣货数量")
|
||||
@Excel(name = "拣货数量")
|
||||
private BigDecimal pickingQuantity;
|
||||
|
||||
@ApiModelProperty("复核数量")
|
||||
@Excel(name = "复核数量")
|
||||
private BigDecimal checkQuantity;
|
||||
|
||||
@ApiModelProperty("是否取消订单: 1-是 2-否")
|
||||
@Excel(name = "是否取消订单: 1-是 2-否")
|
||||
private Integer cancelOrder;
|
||||
|
||||
@ApiModelProperty("取消订单备注")
|
||||
@Excel(name = "取消订单备注")
|
||||
private String cancelRemark;
|
||||
|
||||
@ApiModelProperty("取消订单人")
|
||||
@Excel(name = "取消订单人")
|
||||
private Long cancelBy;
|
||||
|
||||
@ApiModelProperty("取消订单人姓名")
|
||||
@Excel(name = "取消订单人姓名")
|
||||
private String cancelByName;
|
||||
|
||||
@ApiModelProperty("取消订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "取消订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date cancelTime;
|
||||
|
||||
@ApiModelProperty("是否关闭订单: 1-是 2-否")
|
||||
@Excel(name = "是否关闭订单: 1-是 2-否")
|
||||
private Integer closeOrder;
|
||||
|
||||
@ApiModelProperty("关闭订单备注")
|
||||
@Excel(name = "关闭订单备注")
|
||||
private String closeRemark;
|
||||
|
||||
@ApiModelProperty("关闭订单人")
|
||||
@Excel(name = "关闭订单人")
|
||||
private Long closeBy;
|
||||
|
||||
@ApiModelProperty("关闭订单人姓名")
|
||||
@Excel(name = "关闭订单人姓名")
|
||||
private String closeByName;
|
||||
|
||||
@ApiModelProperty("关闭订单时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "关闭订单时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date closeTime;
|
||||
|
||||
@ApiModelProperty("复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
@Excel(name = "复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer checkStatus;
|
||||
|
||||
@ApiModelProperty("复核任务是否下发: 1-是 2-否")
|
||||
@Excel(name = "复核任务是否下发: 1-是 2-否")
|
||||
private Integer checkTaskDistribution;
|
||||
|
||||
@ApiModelProperty("复核任务下发时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "复核任务下发时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date checkTaskDistributionTime;
|
||||
|
||||
@ApiModelProperty("复核作业人用户ID")
|
||||
@Excel(name = "复核作业人用户ID")
|
||||
@JsonAlias({"checkOperatorId", "operatorId"})
|
||||
private Long checkOperatorsBy;
|
||||
|
||||
@ApiModelProperty("复核作业人姓名")
|
||||
@Excel(name = "复核作业人姓名")
|
||||
private String checkOperatorsName;
|
||||
|
||||
@ApiModelProperty("调度单号")
|
||||
@Excel(name = "调度单号")
|
||||
private String mobilizeCode;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
|
||||
@ApiModelProperty(name = "组织ID集合")
|
||||
private List<Long> organizationIdList;
|
||||
|
||||
@ApiModelProperty(name = "权限菜单ID")
|
||||
private Long permissionMenuId;
|
||||
|
||||
@ApiModelProperty("出库单id集合")
|
||||
private List<Long> outOrderIds;
|
||||
|
||||
@ApiModelProperty("物料明细")
|
||||
private List<ReservationOutMaterialDetailDTO> materialDetailList;
|
||||
|
||||
@ApiModelProperty("物料条形码")
|
||||
@Excel(name = "物料条形码")
|
||||
private String barCode;
|
||||
|
||||
@ApiModelProperty("物料审核数量")
|
||||
@Excel(name = "物料审核数量")
|
||||
private BigDecimal actualQuantity;
|
||||
|
||||
@ApiModelProperty("波次类型编码")
|
||||
private String waveOrderTypeCode;
|
||||
|
||||
@ApiModelProperty("大于复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer gtCheckStatus;
|
||||
|
||||
@ApiModelProperty("小于复核状态: 1-未复核 2-复核中 3-已复核")
|
||||
private Integer ltCheckStatus;
|
||||
|
||||
@ApiModelProperty("PDA复核查询tab: 1-列表(待复核) 2-历史记录(已复核)")
|
||||
private Integer tabType;
|
||||
|
||||
@ApiModelProperty("to")
|
||||
@Excel(name = "to")
|
||||
private String to;
|
||||
|
||||
@ApiModelProperty("联系人")
|
||||
@Excel(name = "联系人")
|
||||
private String contactPerson;
|
||||
|
||||
@ApiModelProperty("车型及车牌")
|
||||
@Excel(name = "车型及车牌")
|
||||
private String vehicleModelPlate;
|
||||
|
||||
@ApiModelProperty("委托编号")
|
||||
@Excel(name = "委托编号")
|
||||
private String entrustNo;
|
||||
|
||||
@ApiModelProperty("Tel")
|
||||
@Excel(name = "Tel")
|
||||
private String tel;
|
||||
|
||||
@ApiModelProperty("司机签名")
|
||||
@Excel(name = "司机签名")
|
||||
private String driverSign;
|
||||
|
||||
@ApiModelProperty("Fax")
|
||||
@Excel(name = "Fax")
|
||||
private String fax;
|
||||
|
||||
@ApiModelProperty("申报地关区")
|
||||
@Excel(name = "申报地关区")
|
||||
private String declareCustoms;
|
||||
|
||||
@ApiModelProperty("生产商")
|
||||
@Excel(name = "生产商")
|
||||
private String manufacturer;
|
||||
|
||||
@ApiModelProperty("报关员姓名及联系方式")
|
||||
@Excel(name = "报关员姓名及联系方式")
|
||||
private String customsDeclarerInfo;
|
||||
|
||||
@ApiModelProperty("送货地址")
|
||||
@Excel(name = "送货地址")
|
||||
private String deliveryAddr;
|
||||
|
||||
@ApiModelProperty("进出境关别")
|
||||
@Excel(name = "进出境关别")
|
||||
private String entryExitCustoms;
|
||||
|
||||
@ApiModelProperty("起运/运抵国(地区)")
|
||||
@Excel(name = "起运/运抵国(地区)")
|
||||
private String departureArrivalCountry;
|
||||
|
||||
@ApiModelProperty("承运商")
|
||||
@Excel(name = "承运商")
|
||||
private String carrier;
|
||||
|
||||
@ApiModelProperty("柜号")
|
||||
@Excel(name = "柜号")
|
||||
private String containerNo;
|
||||
|
||||
@ApiModelProperty("柜")
|
||||
@Excel(name = "柜")
|
||||
private String containerNoName;
|
||||
|
||||
@ApiModelProperty("出仓日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "出仓日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date outboundDate;
|
||||
@ApiModelProperty("完成时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date completeTime;
|
||||
@ApiModelProperty("orderDate")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Excel(name = "orderDate", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date orderDate;
|
||||
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeCode;
|
||||
@ApiModelProperty("运输方式")
|
||||
@Excel(name = "运输方式")
|
||||
private String transportModeName;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeCode;
|
||||
@ApiModelProperty("监管方式")
|
||||
@Excel(name = "监管方式")
|
||||
private String supervisionModeName;
|
||||
@ApiModelProperty("海关是否查验货物")
|
||||
@Excel(name = "海关是否查验货物")
|
||||
private String customsInspectionFlag;
|
||||
@ApiModelProperty("是否需要报关")
|
||||
@Excel(name = "是否需要报关")
|
||||
private String needDeclareFlag;
|
||||
@ApiModelProperty("是否需要运输")
|
||||
@Excel(name = "是否需要运输")
|
||||
private String needTransportFlag;
|
||||
|
||||
@ApiModelProperty(name = "创建时间查询条件开始日期")
|
||||
private String createTimeStart;
|
||||
|
||||
@ApiModelProperty(name = "创建时间查询条件结束日期")
|
||||
private String createTimeEnd;
|
||||
|
||||
@ApiModelProperty(name = "审核时间查询条件开始日期")
|
||||
private String auditTimeStart;
|
||||
|
||||
@ApiModelProperty(name = "审核时间查询条件结束日期")
|
||||
private String auditTimeEnd;
|
||||
|
||||
@ApiModelProperty("出库明细-物料名称(商品名称),模糊匹配,与前端参数 materialName 一致")
|
||||
private String materialName;
|
||||
|
||||
@ApiModelProperty("出库明细-物料编码,模糊匹配,与前端参数 materialCode 一致")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty("出库交接图片,PDA出库交接时上传的照片,多张图片以逗号隔开")
|
||||
private String pictureApp;
|
||||
|
||||
@ApiModelProperty("业务单号")
|
||||
@Excel(name = "业务单号")
|
||||
private String businessOrderNo;
|
||||
|
||||
@ApiModelProperty("业务类型")
|
||||
@Excel(name = "业务类型")
|
||||
private String businessType;
|
||||
|
||||
@ApiModelProperty("制单人")
|
||||
@Excel(name = "制单人")
|
||||
private String documentCreator;
|
||||
|
||||
@ApiModelProperty("制单人名称")
|
||||
@Excel(name = "制单人名称")
|
||||
private String documentCreatorName;
|
||||
|
||||
@ApiModelProperty("制单日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "制单日期", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date documentDate;
|
||||
@ApiModelProperty("承运商名称")
|
||||
@Excel(name = "承运商名称")
|
||||
private String carrierName;
|
||||
|
||||
@ApiModelProperty( "下发状态 0-无状态 1-未下发 2-已下发 ")
|
||||
private Long issueStatus;
|
||||
|
||||
@ApiModelProperty("下发时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date issueTime;
|
||||
|
||||
@ApiModelProperty("下发人id")
|
||||
private Long issueId;
|
||||
|
||||
@ApiModelProperty("下发人")
|
||||
private String issueName;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private Long reservationAuditId;
|
||||
|
||||
@ApiModelProperty("预约审核人id")
|
||||
private String reservationAuditName;
|
||||
|
||||
@ApiModelProperty("预约审核时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reservationAuditTime;
|
||||
}
|
||||
+987
@@ -0,0 +1,987 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.service;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.mhd.common.core.constant.SnowFlakeConstants;
|
||||
import com.mhd.common.core.domain.po.UserPo;
|
||||
import com.mhd.common.core.enums.DictCode;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.utils.IgnoreNullUtil;
|
||||
import com.mhd.common.core.utils.StringUtils;
|
||||
import com.mhd.common.core.utils.bean.BeanUtils;
|
||||
import com.mhd.common.core.utils.uuid.IdGenerator;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.entity.ReservationOutMaterialDetail;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.facade.IReservationOutMaterialDetailService;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.ReservationOutMaterialDetailPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.OutMaterialCheckPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.service.ReservationOutMaterialDetailDomainService;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.todo.ReservationStockInOrderDO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.entity.ReservationStockOutOrder;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.facade.IReservationStockOutOrderService;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
import com.mhd.system.api.SystemServiceFeign;
|
||||
import com.mhd.system.api.UserServiceFeign;
|
||||
import com.mhd.system.api.domain.*;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
import java.math.BigDecimal;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.*;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 出库单ApplicationService
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class ReservationStockOutOrderApplicationService {
|
||||
@Autowired
|
||||
private ReservationStockOutOrderDomainService stockOutOrderDomainService;
|
||||
// @Autowired
|
||||
// private ReservationOutMaterialDetailDomainService outMaterialDetailDomainService;
|
||||
// @Autowired
|
||||
// private MaterialInventoryDomainService materialInventoryDomainService;
|
||||
// @Autowired
|
||||
// private MaterialInventoryMapper materialInventoryMapper;
|
||||
@Autowired
|
||||
private UserServiceFeign userServiceFeign;
|
||||
@Autowired
|
||||
private SystemServiceFeign systemServiceFeign;
|
||||
@Autowired
|
||||
private IdGenerator idGenerator;
|
||||
@Autowired
|
||||
private IReservationStockOutOrderService stockOutOrderService;
|
||||
@Autowired
|
||||
private IReservationOutMaterialDetailService outMaterialDetailService;
|
||||
// @Autowired
|
||||
// private IPickingMaterialDetailService pickingMaterialDetailService;
|
||||
|
||||
|
||||
/**
|
||||
* 分页查询出库单列表
|
||||
*/
|
||||
|
||||
public List<ReservationStockOutOrderPO> queryList(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
Long userOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
Long frontendOrganizationId = stockOutOrderDO.getOrganizationId(); // 前端传递的 organizationId
|
||||
|
||||
// 数据权限:根据 organizationId 来设置查询权限
|
||||
// 当前登录用户的 organizationId 为 2827 时,可查全部组织数据;其他组织只能查自己
|
||||
if (userOrganizationId != null && userOrganizationId == 2827L) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据
|
||||
// 如果前端传递了 organizationId(包括2827或其他组织),使用前端传递的值进行过滤
|
||||
// 如果前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
if (frontendOrganizationId != null) {
|
||||
// 前端传递了 organizationId(包括2827或其他组织),使用前端传递的值进行过滤
|
||||
stockOutOrderDO.setOrganizationId(frontendOrganizationId);
|
||||
stockOutOrderDO.setTopOrganizationId(null); // 明确设置为 null,避免使用 topOrganizationId 条件
|
||||
} else {
|
||||
// 前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
stockOutOrderDO.setOrganizationId(null);
|
||||
stockOutOrderDO.setTopOrganizationId(null);
|
||||
}
|
||||
} else {
|
||||
// 其他组织:设置organizationId,只查询当前组织的数据
|
||||
// 如果前端传递了 organizationId,验证是否与当前登录用户的组织ID一致
|
||||
if (frontendOrganizationId != null && userOrganizationId != null) {
|
||||
// 前端传递了 organizationId,验证是否与当前登录用户的组织ID一致
|
||||
if (!frontendOrganizationId.equals(userOrganizationId)) {
|
||||
// 前端传递了其他组织的 organizationId,强制使用当前登录用户的组织ID,防止越权查询
|
||||
stockOutOrderDO.setOrganizationId(userOrganizationId);
|
||||
}
|
||||
// 如果前端传递的 organizationId 与当前登录用户的组织ID一致,使用前端传递的值
|
||||
} else {
|
||||
// 前端没有传递 organizationId,使用当前登录用户的组织ID
|
||||
if (userOrganizationId != null) {
|
||||
stockOutOrderDO.setOrganizationId(userOrganizationId);
|
||||
}
|
||||
}
|
||||
// 只有当 organizationId 为 null 时,才使用 topOrganizationId 作为查询条件
|
||||
// 如果 organizationId 不为 null,则优先使用 organizationId,不使用 topOrganizationId
|
||||
if (stockOutOrderDO.getOrganizationId() == null) {
|
||||
Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
if (topOrganizationId != null && topOrganizationId != 1) {
|
||||
stockOutOrderDO.setTopOrganizationId(topOrganizationId);
|
||||
}
|
||||
} else {
|
||||
// 对于非2827组织,必须设置 topOrganizationId=2827
|
||||
stockOutOrderDO.setTopOrganizationId(2827L);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 库管角色过滤:不展示已创建(status=1)的出库单
|
||||
// 出库状态: 1-已创建 ...
|
||||
if (loginUser != null) {
|
||||
String targetRoleCode = "KGY-001";
|
||||
boolean isKuGuan = false;
|
||||
|
||||
String roleCode = loginUser.getUserPo() != null ? loginUser.getUserPo().getRoleCode() : null;
|
||||
if (StringUtils.isNotBlank(roleCode) && roleCode.contains(targetRoleCode)) {
|
||||
isKuGuan = true;
|
||||
}
|
||||
|
||||
if (!isKuGuan && loginUser.getRoleList() != null) {
|
||||
isKuGuan = loginUser.getRoleList().stream()
|
||||
.anyMatch(rc -> StringUtils.isNotBlank(rc) && rc.contains(targetRoleCode));
|
||||
}
|
||||
|
||||
if (!isKuGuan && loginUser.getRoles() != null) {
|
||||
isKuGuan = loginUser.getRoles().stream()
|
||||
.anyMatch(rc -> StringUtils.isNotBlank(rc) && rc.contains(targetRoleCode));
|
||||
}
|
||||
|
||||
if (isKuGuan) {
|
||||
Integer currentGtStatus = stockOutOrderDO.getGtStatus();
|
||||
if (currentGtStatus == null || currentGtStatus < 1) {
|
||||
stockOutOrderDO.setGtStatus(1); // status > 1
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
List<ReservationStockOutOrderPO> stockOutOrderPOS = stockOutOrderDomainService.queryList(stockOutOrderDO);
|
||||
// for (ReservationStockOutOrderPO stockOutOrderPO : stockOutOrderPOS) {
|
||||
// ReservationStockOutOrderPO stockOutOrderPO1 = stockOutOrderDomainService.getInfoChildren(stockOutOrderPO.getOutOrderId());
|
||||
// List<ReservationOutMaterialDetailPO> materialDetailList = stockOutOrderPO1 != null ? stockOutOrderPO1.getMaterialDetailList() : null;
|
||||
// if (materialDetailList == null) {
|
||||
// materialDetailList = Collections.emptyList();
|
||||
// }
|
||||
// BigDecimal reduce = materialDetailList.stream().map(ReservationOutMaterialDetailPO::getOutboundQuantity).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
// stockOutOrderPO.setTotalOutboundQuantity(reduce);
|
||||
// stockOutOrderPO.setAllocationQuantity(stockOutOrderPO1 != null ? stockOutOrderPO1.getAllocationQuantity() : null);
|
||||
// String outOrderNumber = stockOutOrderPO.getOutOrderNumber();
|
||||
// // PDA复核物料总数量:使用实际下发时的拣货完成数量(picking_material_detail),拣货多少显示多少
|
||||
// // PDA端物料总数量取quantity字段、复核总数量取checkQuantity字段,需同时设置quantity和pickingQuantity
|
||||
// BigDecimal actualPickingQty = pickingMaterialDetailService.sumPickingQuantityByOutOrderNumber(outOrderNumber);
|
||||
// BigDecimal displayPickingQty = actualPickingQty.compareTo(BigDecimal.ZERO) > 0 ? actualPickingQty : (stockOutOrderPO1 != null ? stockOutOrderPO1.getPickingQuantity() : BigDecimal.ZERO);
|
||||
// stockOutOrderPO.setPickingQuantity(displayPickingQty);
|
||||
// stockOutOrderPO.setQuantity(displayPickingQty);
|
||||
// // 物料种类:优先从picking_material_detail统计,为0时从out_material_detail按料号去重
|
||||
// Integer materialTypeCount = pickingMaterialDetailService.countMaterialTypesByOutOrderNumber(outOrderNumber);
|
||||
// if (materialTypeCount != null && materialTypeCount > 0) {
|
||||
// stockOutOrderPO.setMaterialQuantity(materialTypeCount);
|
||||
// } else {
|
||||
// long count = materialDetailList.stream()
|
||||
// .map(d -> d.getMaterialBaseInfoId() != null ? String.valueOf(d.getMaterialBaseInfoId()) : d.getMaterialCode())
|
||||
// .filter(Objects::nonNull)
|
||||
// .distinct()
|
||||
// .count();
|
||||
// stockOutOrderPO.setMaterialQuantity((int) count);
|
||||
// }
|
||||
// // 复核总数量:从out_material_detail汇总check_quantity
|
||||
// BigDecimal checkSum = materialDetailList.stream().map(ReservationOutMaterialDetailPO::getCheckQuantity).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
// stockOutOrderPO.setCheckQuantity(checkSum);
|
||||
// }
|
||||
return stockOutOrderPOS;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增出库单
|
||||
*/
|
||||
public Boolean insert(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
//设置仓库
|
||||
//setWarehouseInfo(stockOutOrderDO);
|
||||
//设置货主信息
|
||||
shipperParam(stockOutOrderDO);
|
||||
//设置客户信息
|
||||
customerParam(stockOutOrderDO);
|
||||
stockOutOrderDO.setOrderTypeCode("pu_tong_chu_ku");
|
||||
stockOutOrderDO.setOrderTypeName("普通出库");
|
||||
//设置数据字典键值
|
||||
//setDataDict(stockOutOrderDO);
|
||||
return stockOutOrderDomainService.insert(stockOutOrderDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改出库单
|
||||
*/
|
||||
public Boolean update(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
return stockOutOrderDomainService.update(stockOutOrderDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改出库单
|
||||
*/
|
||||
public Boolean close(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
return stockOutOrderDomainService.close(stockOutOrderDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除出库单
|
||||
*/
|
||||
public boolean delete(Long[] outOrderIds) {
|
||||
return stockOutOrderDomainService.delete(outOrderIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取出库单详细信息(带批次属性)
|
||||
*/
|
||||
public ReservationStockOutOrderPO getInfoChildren(Long outOrderId)
|
||||
{
|
||||
ReservationStockOutOrderPO stockOutOrderPO = stockOutOrderDomainService.getInfoChildren(outOrderId);
|
||||
|
||||
if (stockOutOrderPO == null || CollectionUtils.isEmpty(stockOutOrderPO.getMaterialDetailList())) {
|
||||
return stockOutOrderPO;
|
||||
}
|
||||
|
||||
List<ReservationOutMaterialDetailPO> detailList = stockOutOrderPO.getMaterialDetailList();
|
||||
|
||||
// 性能优化:批量获取批次属性,避免N+1查询问题
|
||||
// 1. 收集所有唯一的materialBaseInfoId
|
||||
Set<Long> materialBaseInfoIdSet = detailList.stream()
|
||||
.map(ReservationOutMaterialDetailPO::getMaterialBaseInfoId)
|
||||
.filter(Objects::nonNull)
|
||||
.collect(Collectors.toSet());
|
||||
|
||||
// 2. 批量查询批次属性(使用Map缓存,避免重复查询相同的materialBaseInfoId)
|
||||
Map<Long, List<BatchDetailFeignPO>> batchDetailMap = new HashMap<>();
|
||||
for (Long materialBaseInfoId : materialBaseInfoIdSet) {
|
||||
try {
|
||||
AjaxResult ajaxResult = systemServiceFeign.getBatchDetailListByMaterialBaseInfoId(materialBaseInfoId);
|
||||
if (ajaxResult != null && "200".equals(String.valueOf(ajaxResult.get("code")))) {
|
||||
List<BatchDetailFeignPO> batchDetailFeignPOList = JSON.parseArray(
|
||||
JSONObject.toJSONString(ajaxResult.get("data")), BatchDetailFeignPO.class);
|
||||
if (!CollectionUtils.isEmpty(batchDetailFeignPOList)) {
|
||||
// 过滤isDisplay=1的属性
|
||||
List<BatchDetailFeignPO> filteredList = batchDetailFeignPOList.stream()
|
||||
.filter(batchDetail -> batchDetail.getIsDisplay() != null && batchDetail.getIsDisplay() == 1)
|
||||
.collect(Collectors.toList());
|
||||
batchDetailMap.put(materialBaseInfoId, filteredList);
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.warn("获取物料批次属性失败,物料基础信息ID:{},错误:{}", materialBaseInfoId, e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
// 3. 为每个物料明细设置更多属性(从物料明细表中获取值),递归处理所有层级
|
||||
//setMaterialMoreDetailListRecursively(detailList, batchDetailMap);
|
||||
|
||||
// 4. 为每个物料明细设置分配按钮显示类型,递归处理所有层级
|
||||
setAllocationButtonTypeRecursively(detailList);
|
||||
|
||||
// 5. 出库交接场景(已出库/已复核):过滤 pickingQuantity 为 0 的明细,与交接详情一致
|
||||
// if (stockOutOrderPO.getStatus() != null && (stockOutOrderPO.getStatus() == 9 || stockOutOrderPO.getStatus() == 12)) {
|
||||
// filterMaterialDetailByPickingQuantity(detailList, stockOutOrderPO.getReview(), stockOutOrderPO.getOutOrderNumber());
|
||||
// }
|
||||
|
||||
return stockOutOrderPO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 出库交接场景:递归过滤 pickingQuantity 为 0 的明细(与交接详情一致)
|
||||
* @param detailList 物料明细树
|
||||
* @param review 是否需要复核 1-是 2-否
|
||||
* @param outOrderNumber 出库单号(review=1 时用于 picking_material_detail 查询)
|
||||
*/
|
||||
// private void filterMaterialDetailByPickingQuantity(List<ReservationOutMaterialDetailPO> detailList, Integer review, String outOrderNumber) {
|
||||
// if (CollectionUtils.isEmpty(detailList)) {
|
||||
// return;
|
||||
// }
|
||||
// for (int i = detailList.size() - 1; i >= 0; i--) {
|
||||
// ReservationOutMaterialDetailPO d = detailList.get(i);
|
||||
// List<ReservationOutMaterialDetailPO> children = d.getChildren();
|
||||
// if (!CollectionUtils.isEmpty(children)) {
|
||||
// filterMaterialDetailByPickingQuantity(children, review, outOrderNumber);
|
||||
// }
|
||||
// BigDecimal pickQty;
|
||||
// if (Integer.valueOf(1).equals(review) && d.getUniqueId() != null) {
|
||||
// PickingMaterialDetailPO pickingSummary = pickingMaterialDetailService.queryTotalsByOutNumberAndBaseId(d.getUniqueId());
|
||||
// pickQty = (pickingSummary != null && pickingSummary.getPickingQuantity() != null) ? pickingSummary.getPickingQuantity() : BigDecimal.ZERO;
|
||||
// } else {
|
||||
// pickQty = d.getPickingQuantity() != null ? d.getPickingQuantity() : BigDecimal.ZERO;
|
||||
// }
|
||||
// if (pickQty.compareTo(BigDecimal.ZERO) <= 0) {
|
||||
// detailList.remove(i);
|
||||
// } else if (Integer.valueOf(1).equals(review) && d.getUniqueId() != null) {
|
||||
// // 需要复核时:用 picking_material_detail 的拣货数量覆盖展示,保证已拣货数量正确
|
||||
// d.setPickingQuantity(pickQty);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
/**
|
||||
* 递归为出库物料明细设置更多属性
|
||||
* 如果已分配库存(materialInventoryId不为空),则从库存表中获取批次属性值
|
||||
* 否则从物料明细表中获取值
|
||||
* @param outMaterialDetailPOList 出库物料明细列表
|
||||
* @param batchDetailMap 批次属性Map
|
||||
*/
|
||||
// private void setMaterialMoreDetailListRecursively(List<ReservationOutMaterialDetailPO> outMaterialDetailPOList,
|
||||
// Map<Long, List<BatchDetailFeignPO>> batchDetailMap) {
|
||||
// if (CollectionUtils.isEmpty(outMaterialDetailPOList)) {
|
||||
// return;
|
||||
// }
|
||||
//
|
||||
// outMaterialDetailPOList.forEach(outMaterialDetailPO -> {
|
||||
// Long materialBaseInfoId = outMaterialDetailPO.getMaterialBaseInfoId();
|
||||
// Long materialInventoryId = outMaterialDetailPO.getMaterialInventoryId();
|
||||
//
|
||||
// // 创建新的materialMoreDetailList,只包含isDisplay=1的属性
|
||||
// List<MaterialMoreDetailPO> materialMoreDetailList = new ArrayList<>();
|
||||
//
|
||||
// // 创建batchDetailId到MaterialMoreDetailPO的映射,用于快速查找已有的属性值
|
||||
// Map<Long, MaterialMoreDetailPO> batchDetailIdToMaterialMoreDetailMap = new HashMap<>();
|
||||
// List<MaterialMoreDetailPO> existingList = outMaterialDetailPO.getMaterialMoreDetailList();
|
||||
// if (!CollectionUtils.isEmpty(existingList)) {
|
||||
// for (MaterialMoreDetailPO existing : existingList) {
|
||||
// if (existing.getBatchDetailId() != null) {
|
||||
// batchDetailIdToMaterialMoreDetailMap.put(existing.getBatchDetailId(), existing);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// // 如果已分配库存,从库存表中获取批次属性值
|
||||
// MaterialInventoryPO inventoryPO = null;
|
||||
// if (materialInventoryId != null && materialInventoryId > 0) {
|
||||
// try {
|
||||
// inventoryPO = materialInventoryMapper.selectByIdWithBatchAttributes(materialInventoryId);
|
||||
// log.info("从库存表获取批次属性,materialInventoryId={}", materialInventoryId);
|
||||
// } catch (Exception e) {
|
||||
// log.warn("从库存表获取批次属性失败,materialInventoryId={},错误:{}", materialInventoryId, e.getMessage());
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// // 只保留isDisplay=1的批次属性(从batchDetailMap中获取,已经过滤过了)
|
||||
// if (materialBaseInfoId != null && batchDetailMap.containsKey(materialBaseInfoId)) {
|
||||
// List<BatchDetailFeignPO> batchDetailFeignPOList = batchDetailMap.get(materialBaseInfoId);
|
||||
// // 用于跟踪已添加到列表中的batchDetailId
|
||||
// Set<Long> addedBatchDetailIds = new HashSet<>();
|
||||
//
|
||||
// for (BatchDetailFeignPO batchDetailFeignPO : batchDetailFeignPOList) {
|
||||
// MaterialMoreDetailPO materialMoreDetailPO = batchDetailIdToMaterialMoreDetailMap.get(batchDetailFeignPO.getBatchDetailId());
|
||||
//
|
||||
// // 如果不存在,创建新的
|
||||
// if (materialMoreDetailPO == null) {
|
||||
// materialMoreDetailPO = new MaterialMoreDetailPO();
|
||||
// materialMoreDetailPO.setBatchId(batchDetailFeignPO.getBatchId());
|
||||
// materialMoreDetailPO.setBatchDetailId(batchDetailFeignPO.getBatchDetailId());
|
||||
// materialMoreDetailPO.setBatchLabels(batchDetailFeignPO.getBatchLabels());
|
||||
// materialMoreDetailPO.setInputControl(batchDetailFeignPO.getInputControl());
|
||||
// materialMoreDetailPO.setAttributeFormat(batchDetailFeignPO.getAttributeFormat());
|
||||
// materialMoreDetailPO.setAttributeOption(batchDetailFeignPO.getAttributeOption());
|
||||
// materialMoreDetailPO.setRemark(batchDetailFeignPO.getRemark());
|
||||
// } else {
|
||||
// // 如果已存在,更新属性(保留已有的attributeValue)
|
||||
// materialMoreDetailPO.setBatchId(batchDetailFeignPO.getBatchId());
|
||||
// materialMoreDetailPO.setBatchLabels(batchDetailFeignPO.getBatchLabels());
|
||||
// materialMoreDetailPO.setInputControl(batchDetailFeignPO.getInputControl());
|
||||
// materialMoreDetailPO.setAttributeFormat(batchDetailFeignPO.getAttributeFormat());
|
||||
// materialMoreDetailPO.setAttributeOption(batchDetailFeignPO.getAttributeOption());
|
||||
// materialMoreDetailPO.setRemark(batchDetailFeignPO.getRemark());
|
||||
// }
|
||||
//
|
||||
// // 确保添加到列表中(使用batchDetailId来避免重复)
|
||||
// Long batchDetailId = batchDetailFeignPO.getBatchDetailId();
|
||||
// if (batchDetailId != null && !addedBatchDetailIds.contains(batchDetailId)) {
|
||||
// materialMoreDetailList.add(materialMoreDetailPO);
|
||||
// addedBatchDetailIds.add(batchDetailId);
|
||||
// }
|
||||
//
|
||||
// // 根据fieldName或batchLabels获取对应的字段值
|
||||
// String fieldValue = null;
|
||||
// String usedFieldName = null;
|
||||
//
|
||||
// // 只有在已分配库存时,才从库存表获取值并设置到attributeValue
|
||||
// if (inventoryPO != null) {
|
||||
// // 优先使用fieldName(如果存在)
|
||||
// if (StringUtils.isNotBlank(batchDetailFeignPO.getFieldName())) {
|
||||
// usedFieldName = batchDetailFeignPO.getFieldName();
|
||||
// fieldValue = getFieldValueByFieldName(inventoryPO, usedFieldName);
|
||||
// log.info("批次属性 batchDetailId={}, fieldName={}, 从库存表获取到的值={}",
|
||||
// batchDetailFeignPO.getBatchDetailId(), usedFieldName, fieldValue);
|
||||
// }
|
||||
// // 如果fieldName为空,尝试根据batchLabels映射到字段名
|
||||
// else if (StringUtils.isNotBlank(batchDetailFeignPO.getBatchLabels())) {
|
||||
// String fieldNameByLabel = getFieldNameByBatchLabel(batchDetailFeignPO.getBatchLabels());
|
||||
// if (StringUtils.isNotBlank(fieldNameByLabel)) {
|
||||
// usedFieldName = fieldNameByLabel;
|
||||
// fieldValue = getFieldValueByFieldName(inventoryPO, usedFieldName);
|
||||
// log.info("批次属性 batchDetailId={}, batchLabels={}, 映射字段名={}, 从库存表获取到的值={}",
|
||||
// batchDetailFeignPO.getBatchDetailId(), batchDetailFeignPO.getBatchLabels(),
|
||||
// usedFieldName, fieldValue);
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// // 只有当获取到值时才更新attributeValue(已分配库存时)
|
||||
// if (fieldValue != null) {
|
||||
// materialMoreDetailPO.setAttributeValue(fieldValue);
|
||||
// log.info("设置更多属性:batchDetailId={}, batchLabels={}, attributeValue={}",
|
||||
// materialMoreDetailPO.getBatchDetailId(), materialMoreDetailPO.getBatchLabels(),
|
||||
// materialMoreDetailPO.getAttributeValue());
|
||||
// }
|
||||
// } else {
|
||||
// // 未分配库存时,attributeValue保持为空(不设置值)
|
||||
// log.info("批次属性未分配库存,batchDetailId={}, batchLabels={}, attributeValue为空",
|
||||
// materialMoreDetailPO.getBatchDetailId(), materialMoreDetailPO.getBatchLabels());
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// outMaterialDetailPO.setMaterialMoreDetailList(materialMoreDetailList);
|
||||
// log.info("出库物料明细 uniqueId={}, materialBaseInfoId={}, materialInventoryId={}, materialMoreDetailList大小={}",
|
||||
// outMaterialDetailPO.getUniqueId(), outMaterialDetailPO.getMaterialBaseInfoId(),
|
||||
// outMaterialDetailPO.getMaterialInventoryId(),
|
||||
// materialMoreDetailList != null ? materialMoreDetailList.size() : 0);
|
||||
//
|
||||
// // 递归处理子集
|
||||
// if (!CollectionUtils.isEmpty(outMaterialDetailPO.getChildren())) {
|
||||
// setMaterialMoreDetailListRecursively(outMaterialDetailPO.getChildren(), batchDetailMap);
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
/**
|
||||
* 根据批次标签(batchLabels)映射到字段名
|
||||
* @param batchLabel 批次标签
|
||||
* @return 字段名,如果找不到映射则返回null
|
||||
*/
|
||||
private String getFieldNameByBatchLabel(String batchLabel) {
|
||||
if (StringUtils.isBlank(batchLabel)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// 批次标签到字段名的映射关系
|
||||
Map<String, String> labelToFieldNameMap = new HashMap<>();
|
||||
labelToFieldNameMap.put("Invoice No.", "invoiceNo");
|
||||
labelToFieldNameMap.put("Invoice No", "invoiceNo");
|
||||
labelToFieldNameMap.put("发票号", "invoiceNo");
|
||||
labelToFieldNameMap.put("Batch Ref NO's", "batchRefNo");
|
||||
labelToFieldNameMap.put("Batch Ref NO", "batchRefNo");
|
||||
labelToFieldNameMap.put("批次参考号", "batchRefNo");
|
||||
labelToFieldNameMap.put("Sheet Ref NO's", "sheetRefNo");
|
||||
labelToFieldNameMap.put("Sheet Ref NO", "sheetRefNo");
|
||||
labelToFieldNameMap.put("单据参考号", "sheetRefNo");
|
||||
labelToFieldNameMap.put("箱号/卡板号", "boxPalletNo");
|
||||
labelToFieldNameMap.put("箱号", "boxPalletNo");
|
||||
labelToFieldNameMap.put("卡板号", "boxPalletNo");
|
||||
labelToFieldNameMap.put("申报数量", "declareQuantity");
|
||||
labelToFieldNameMap.put("申报单位", "declareUnit");
|
||||
labelToFieldNameMap.put("原产国", "countryOfOrigin");
|
||||
labelToFieldNameMap.put("币制", "currency");
|
||||
labelToFieldNameMap.put("单位", "unit");
|
||||
labelToFieldNameMap.put("升", "liter");
|
||||
labelToFieldNameMap.put("尺寸", "size");
|
||||
labelToFieldNameMap.put("箱数", "caseCount");
|
||||
labelToFieldNameMap.put("件数", "pieceCount");
|
||||
labelToFieldNameMap.put("出库数量", "outboundQuantity");
|
||||
labelToFieldNameMap.put("总净重", "totalNetWeight");
|
||||
labelToFieldNameMap.put("总毛重", "totalGrossWeight");
|
||||
labelToFieldNameMap.put("总体积", "totalVolume");
|
||||
labelToFieldNameMap.put("总面积", "totalArea");
|
||||
labelToFieldNameMap.put("总价", "totalAmount");
|
||||
|
||||
// 精确匹配
|
||||
String fieldName = labelToFieldNameMap.get(batchLabel.trim());
|
||||
if (StringUtils.isNotBlank(fieldName)) {
|
||||
return fieldName;
|
||||
}
|
||||
|
||||
// 模糊匹配(包含关系)
|
||||
for (Map.Entry<String, String> entry : labelToFieldNameMap.entrySet()) {
|
||||
if (batchLabel.contains(entry.getKey()) || entry.getKey().contains(batchLabel)) {
|
||||
return entry.getValue();
|
||||
}
|
||||
}
|
||||
|
||||
// 如果找不到映射,尝试将批次标签转换为驼峰命名(简单处理)
|
||||
return convertLabelToFieldName(batchLabel);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将批次标签转换为字段名(驼峰命名)
|
||||
* @param label 批次标签
|
||||
* @return 字段名
|
||||
*/
|
||||
private String convertLabelToFieldName(String label) {
|
||||
if (StringUtils.isBlank(label)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// 移除特殊字符,转换为小写,用空格或特殊字符分割
|
||||
String cleaned = label.replaceAll("[^a-zA-Z0-9\\u4e00-\\u9fa5\\s]", " ")
|
||||
.trim()
|
||||
.toLowerCase();
|
||||
|
||||
// 如果是中文,无法自动转换,返回null
|
||||
if (cleaned.matches(".*[\\u4e00-\\u9fa5].*")) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// 将空格分割的单词转换为驼峰命名
|
||||
String[] words = cleaned.split("\\s+");
|
||||
if (words.length == 0) {
|
||||
return null;
|
||||
}
|
||||
|
||||
StringBuilder fieldName = new StringBuilder(words[0]);
|
||||
for (int i = 1; i < words.length; i++) {
|
||||
if (words[i].length() > 0) {
|
||||
fieldName.append(words[i].substring(0, 1).toUpperCase())
|
||||
.append(words[i].substring(1));
|
||||
}
|
||||
}
|
||||
|
||||
return fieldName.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据字段名从对象中获取字段值(使用反射)
|
||||
* @param obj 对象
|
||||
* @param fieldName 字段名
|
||||
* @return 字段值(转换为字符串)
|
||||
*/
|
||||
private String getFieldValueByFieldName(Object obj, String fieldName) {
|
||||
if (obj == null || StringUtils.isBlank(fieldName)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
try {
|
||||
// 兼容:如果传的是下划线命名(数据库列名风格),先转成驼峰字段名再取
|
||||
String normalizedFieldName = fieldName;
|
||||
if (normalizedFieldName.contains("_")) {
|
||||
normalizedFieldName = snakeToCamel(normalizedFieldName);
|
||||
}
|
||||
|
||||
// 获取对象的Class
|
||||
Class<?> clazz = obj.getClass();
|
||||
|
||||
// 尝试获取字段(包括父类字段)
|
||||
Field field = null;
|
||||
Class<?> currentClass = clazz;
|
||||
while (currentClass != null && field == null) {
|
||||
try {
|
||||
field = currentClass.getDeclaredField(normalizedFieldName);
|
||||
} catch (NoSuchFieldException e) {
|
||||
currentClass = currentClass.getSuperclass();
|
||||
}
|
||||
}
|
||||
|
||||
if (field == null) {
|
||||
log.warn("字段不存在:{}(normalized:{}),对象类型:{}", fieldName, normalizedFieldName, clazz.getName());
|
||||
return null;
|
||||
}
|
||||
|
||||
// 设置可访问
|
||||
field.setAccessible(true);
|
||||
|
||||
// 获取字段值
|
||||
Object value = field.get(obj);
|
||||
|
||||
// 转换为字符串
|
||||
if (value == null) {
|
||||
log.info("字段 {} 的值为 null,对象类型:{}", normalizedFieldName, clazz.getName());
|
||||
return null;
|
||||
}
|
||||
|
||||
String result;
|
||||
// 处理日期类型字段
|
||||
if (value instanceof Date) {
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
result = sdf.format((Date) value);
|
||||
} else {
|
||||
result = value.toString();
|
||||
}
|
||||
|
||||
log.info("通过反射获取字段值成功,字段名:{}(原始:{}),值:{},对象类型:{}",
|
||||
normalizedFieldName, fieldName, result, clazz.getName());
|
||||
return result;
|
||||
} catch (Exception e) {
|
||||
log.warn("通过反射获取字段值失败,字段名:{},对象类型:{},错误:{}", fieldName, obj.getClass().getName(), e.getMessage());
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
private String snakeToCamel(String snake) {
|
||||
if (StringUtils.isBlank(snake)) {
|
||||
return null;
|
||||
}
|
||||
String s = snake.trim().toLowerCase();
|
||||
StringBuilder sb = new StringBuilder();
|
||||
boolean upperNext = false;
|
||||
for (int i = 0; i < s.length(); i++) {
|
||||
char c = s.charAt(i);
|
||||
if (c == '_') {
|
||||
upperNext = true;
|
||||
continue;
|
||||
}
|
||||
if (upperNext) {
|
||||
sb.append(Character.toUpperCase(c));
|
||||
upperNext = false;
|
||||
} else {
|
||||
sb.append(c);
|
||||
}
|
||||
}
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取出库单详细信息(PDA复核页面:含批次属性、净重、毛重、面积、体积)
|
||||
*/
|
||||
// public ReservationStockOutOrderPO getInfoByApp(Long outOrderId) {
|
||||
// ReservationStockOutOrderPO stockOutOrderPO = stockOutOrderDomainService.getInfoByApp(outOrderId);
|
||||
// enrichReservationStockOutOrderForPdaCheck(stockOutOrderPO);
|
||||
// return stockOutOrderPO;
|
||||
// }
|
||||
|
||||
/**
|
||||
* 为PDA复核页面填充批次属性(根据物料批次标签动态显示,有值显示)及净重、毛重、面积、体积
|
||||
*/
|
||||
// private void enrichReservationStockOutOrderForPdaCheck(ReservationStockOutOrderPO stockOutOrderPO) {
|
||||
// if (stockOutOrderPO == null || CollectionUtils.isEmpty(stockOutOrderPO.getMaterialDetailList())) {
|
||||
// return;
|
||||
// }
|
||||
// List<ReservationOutMaterialDetailPO> detailList = stockOutOrderPO.getMaterialDetailList();
|
||||
// Set<Long> materialBaseInfoIdSet = detailList.stream()
|
||||
// .map(ReservationOutMaterialDetailPO::getMaterialBaseInfoId)
|
||||
// .filter(Objects::nonNull)
|
||||
// .collect(Collectors.toSet());
|
||||
// Map<Long, List<BatchDetailFeignPO>> batchDetailMap = new HashMap<>();
|
||||
// for (Long materialBaseInfoId : materialBaseInfoIdSet) {
|
||||
// try {
|
||||
// AjaxResult ajaxResult = systemServiceFeign.getBatchDetailListByMaterialBaseInfoId(materialBaseInfoId);
|
||||
// if (ajaxResult != null && "200".equals(String.valueOf(ajaxResult.get("code")))) {
|
||||
// List<BatchDetailFeignPO> batchDetailFeignPOList = JSON.parseArray(
|
||||
// JSONObject.toJSONString(ajaxResult.get("data")), BatchDetailFeignPO.class);
|
||||
// if (!CollectionUtils.isEmpty(batchDetailFeignPOList)) {
|
||||
// List<BatchDetailFeignPO> filteredList = batchDetailFeignPOList.stream()
|
||||
// .filter(b -> b.getIsDisplay() != null && b.getIsDisplay() == 1)
|
||||
// .collect(Collectors.toList());
|
||||
// batchDetailMap.put(materialBaseInfoId, filteredList);
|
||||
// }
|
||||
// }
|
||||
// } catch (Exception e) {
|
||||
// log.warn("获取物料批次属性失败,物料基础信息ID:{},错误:{}", materialBaseInfoId, e.getMessage());
|
||||
// }
|
||||
// }
|
||||
// setMaterialMoreDetailListRecursivelyForCheck(detailList, batchDetailMap);
|
||||
// }
|
||||
|
||||
/**
|
||||
* 递归为PDA复核物料明细设置批次属性(有值显示),优先从库存取,否则从出库明细取
|
||||
*/
|
||||
// private void setMaterialMoreDetailListRecursivelyForCheck(List<ReservationOutMaterialDetailPO> outMaterialDetailPOList,
|
||||
// Map<Long, List<BatchDetailFeignPO>> batchDetailMap) {
|
||||
// if (CollectionUtils.isEmpty(outMaterialDetailPOList)) {
|
||||
// return;
|
||||
// }
|
||||
// outMaterialDetailPOList.forEach(outMaterialDetailPO -> {
|
||||
// Long materialBaseInfoId = outMaterialDetailPO.getMaterialBaseInfoId();
|
||||
// Long materialInventoryId = outMaterialDetailPO.getMaterialInventoryId();
|
||||
// List<MaterialMoreDetailPO> materialMoreDetailList = new ArrayList<>();
|
||||
// MaterialInventoryPO inventoryPO = null;
|
||||
// if (materialInventoryId != null && materialInventoryId > 0) {
|
||||
// try {
|
||||
// inventoryPO = materialInventoryMapper.selectByIdWithBatchAttributes(materialInventoryId);
|
||||
// } catch (Exception e) {
|
||||
// log.warn("从库存表获取批次属性失败,materialInventoryId={},错误:{}", materialInventoryId, e.getMessage());
|
||||
// }
|
||||
// }
|
||||
// Object sourceObj = inventoryPO != null ? inventoryPO : outMaterialDetailPO;
|
||||
// if (materialBaseInfoId != null && batchDetailMap.containsKey(materialBaseInfoId)) {
|
||||
// for (BatchDetailFeignPO batchDetailFeignPO : batchDetailMap.get(materialBaseInfoId)) {
|
||||
// MaterialMoreDetailPO materialMoreDetailPO = new MaterialMoreDetailPO();
|
||||
// materialMoreDetailPO.setBatchId(batchDetailFeignPO.getBatchId());
|
||||
// materialMoreDetailPO.setBatchDetailId(batchDetailFeignPO.getBatchDetailId());
|
||||
// materialMoreDetailPO.setBatchLabels(batchDetailFeignPO.getBatchLabels());
|
||||
// materialMoreDetailPO.setInputControl(batchDetailFeignPO.getInputControl());
|
||||
// materialMoreDetailPO.setAttributeFormat(batchDetailFeignPO.getAttributeFormat());
|
||||
// materialMoreDetailPO.setAttributeOption(batchDetailFeignPO.getAttributeOption());
|
||||
// materialMoreDetailPO.setRemark(batchDetailFeignPO.getRemark());
|
||||
// String fieldValue = null;
|
||||
// if (StringUtils.isNotBlank(batchDetailFeignPO.getFieldName())) {
|
||||
// fieldValue = getFieldValueByFieldName(sourceObj, batchDetailFeignPO.getFieldName());
|
||||
// } else if (StringUtils.isNotBlank(batchDetailFeignPO.getBatchLabels())) {
|
||||
// String fieldNameByLabel = getFieldNameByBatchLabel(batchDetailFeignPO.getBatchLabels());
|
||||
// if (StringUtils.isNotBlank(fieldNameByLabel)) {
|
||||
// fieldValue = getFieldValueByFieldName(sourceObj, fieldNameByLabel);
|
||||
// }
|
||||
// }
|
||||
// if (fieldValue != null) {
|
||||
// materialMoreDetailPO.setAttributeValue(fieldValue);
|
||||
// materialMoreDetailList.add(materialMoreDetailPO);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// outMaterialDetailPO.setMaterialMoreDetailList(materialMoreDetailList);
|
||||
// if (!CollectionUtils.isEmpty(outMaterialDetailPO.getChildren())) {
|
||||
// setMaterialMoreDetailListRecursivelyForCheck(outMaterialDetailPO.getChildren(), batchDetailMap);
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
/**
|
||||
* @description 审核出库单
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/21 13:53
|
||||
* @param stockOutOrderDO
|
||||
* @return Boolean
|
||||
*/
|
||||
// public Boolean auditState(ReservationStockOutOrderDO stockOutOrderDO){
|
||||
// return stockOutOrderDomainService.auditState(stockOutOrderDO);
|
||||
// }
|
||||
|
||||
/**
|
||||
* @description 审核入库单
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/21 13:53
|
||||
* @param stockInOrderDO
|
||||
* @return Boolean
|
||||
*/
|
||||
public Boolean auditState(ReservationStockOutOrderDO stockOutOrderDO){
|
||||
return stockOutOrderDomainService.auditState(stockOutOrderDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 下发入库单
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/21 13:53
|
||||
* @param stockInOrderDO
|
||||
* @return Boolean
|
||||
*/
|
||||
public Boolean issueOrder(ReservationStockOutOrderDO stockOutOrderDO){
|
||||
return stockOutOrderDomainService.issueOrder(stockOutOrderDO);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 获取出库单复核详细信息
|
||||
*/
|
||||
// public ReservationStockOutOrderPO getCheckInfo(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
// return stockOutOrderDomainService.getCheckInfo(stockOutOrderDO);
|
||||
// }
|
||||
|
||||
/**
|
||||
* @description 设置仓库信息
|
||||
* @author ZhouGY
|
||||
* @date 2024/4/7 10:01
|
||||
* @param stockOutOrderDO
|
||||
*/
|
||||
private void setWarehouseInfo(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
if (stockOutOrderDO.getWarehouseId() == null) {
|
||||
throw new ServiceException("仓库ID不能为空");
|
||||
}
|
||||
AjaxResult ajaxResult = systemServiceFeign.getWarehouseInfoByWarehouseId(stockOutOrderDO.getWarehouseId());
|
||||
if(!"200".equals(String.valueOf(ajaxResult.get("code")))){
|
||||
throw new ServiceException("获取仓库信息失败");
|
||||
}
|
||||
WarehouseFeignPO warehouseFeignPO = JSON.parseObject(JSONObject.toJSONString(ajaxResult.get("data")), WarehouseFeignPO.class);
|
||||
stockOutOrderDO.setWarehouseCode(warehouseFeignPO.getWarehouseCode());
|
||||
stockOutOrderDO.setWarehouseName(warehouseFeignPO.getWarehouseName());
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 封装货主信息
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/9 20:43
|
||||
* @param stockOutOrderDO
|
||||
*/
|
||||
private void shipperParam(ReservationStockOutOrderDO stockOutOrderDO){
|
||||
String customerName = stockOutOrderDO.getCustomerName();
|
||||
if (customerName == null || !customerName.matches("\\d+")) {
|
||||
AjaxResult ajaxResult = userServiceFeign.getInfoByName(customerName);
|
||||
if(!"200".equals(String.valueOf(ajaxResult.get("code")))){
|
||||
throw new ServiceException("获取客户信息失败");
|
||||
}
|
||||
UserPo userPo = JSON.parseObject(JSONObject.toJSONString(ajaxResult.get("data")), UserPo.class);
|
||||
stockOutOrderDO.setShipperId(userPo.getUserId());
|
||||
stockOutOrderDO.setShipperCode(userPo.getUserMemberCode());
|
||||
stockOutOrderDO.setShipperName(userPo.getUserName());
|
||||
} else {
|
||||
AjaxResult ajaxResult = userServiceFeign.getInfo(Long.valueOf(customerName));
|
||||
if(!"200".equals(String.valueOf(ajaxResult.get("code")))){
|
||||
throw new ServiceException("获取货主信息失败");
|
||||
}
|
||||
UserPo userPo = JSON.parseObject(JSONObject.toJSONString(ajaxResult.get("data")), UserPo.class);
|
||||
stockOutOrderDO.setShipperId(userPo.getUserId());
|
||||
stockOutOrderDO.setShipperCode(userPo.getUserMemberCode());
|
||||
stockOutOrderDO.setShipperName(userPo.getUserName());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 封装客户信息
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/9 20:43
|
||||
* @param stockOutOrderDO
|
||||
*/
|
||||
private void customerParam(ReservationStockOutOrderDO stockOutOrderDO){
|
||||
String customerName = stockOutOrderDO.getCustomerName();
|
||||
if (customerName == null || !customerName.matches("\\d+")) {
|
||||
AjaxResult ajaxResult = userServiceFeign.getInfoByName(customerName);
|
||||
if(!"200".equals(String.valueOf(ajaxResult.get("code")))){
|
||||
throw new ServiceException("获取客户信息失败");
|
||||
}
|
||||
UserPo userPo = JSON.parseObject(JSONObject.toJSONString(ajaxResult.get("data")), UserPo.class);
|
||||
stockOutOrderDO.setCustomerId(userPo.getUserId());
|
||||
stockOutOrderDO.setCustomerCode(userPo.getUserMemberCode());
|
||||
stockOutOrderDO.setCustomerName(userPo.getUserName());
|
||||
} else {
|
||||
AjaxResult ajaxResult = userServiceFeign.getInfo(Long.valueOf(customerName));
|
||||
if(!"200".equals(String.valueOf(ajaxResult.get("code")))){
|
||||
throw new ServiceException("获取客户信息失败");
|
||||
}
|
||||
UserPo userPo = JSON.parseObject(JSONObject.toJSONString(ajaxResult.get("data")), UserPo.class);
|
||||
stockOutOrderDO.setCustomerId(userPo.getUserId());
|
||||
stockOutOrderDO.setCustomerCode(userPo.getUserMemberCode());
|
||||
stockOutOrderDO.setCustomerName(userPo.getUserName());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 设置数据字典键值
|
||||
* @author ZhouGY
|
||||
* @date 2024/4/7 14:33
|
||||
* @param stockOutOrderDO
|
||||
*/
|
||||
private void setDataDict(ReservationStockOutOrderDO stockOutOrderDO){
|
||||
//翻译单据类型
|
||||
AjaxResult documentTypeResult = systemServiceFeign.selectListByDictType(DictCode.OUT_DOCUMENT_TYPE.getCode());
|
||||
if (!"200".equals(String.valueOf(documentTypeResult.get("code")))) {
|
||||
throw new ServiceException("单据类型数据字典不存在");
|
||||
}
|
||||
List<SysDictData> documentTypeDataList = JSON.parseArray(JSONUtil.toJsonStr(documentTypeResult.get("data")), SysDictData.class);
|
||||
|
||||
SysDictData documentTypeData = documentTypeDataList.stream().filter(info -> ObjectUtil.equal(info.getDictValue(), stockOutOrderDO.getOrderTypeCode())).findAny().orElse(null);
|
||||
if (null == documentTypeData) {
|
||||
throw new ServiceException("单据类型【" + stockOutOrderDO.getOrderTypeCode() + "】数据字典不存在 请联系管理员");
|
||||
}
|
||||
stockOutOrderDO.setOrderTypeName(documentTypeData.getDictLabel());
|
||||
|
||||
if (StringUtils.isNotBlank(stockOutOrderDO.getPriorityLevelCode())){
|
||||
//翻译优先级别类型
|
||||
AjaxResult priorityLevelResult = systemServiceFeign.selectListByDictType(DictCode.PRIORITY_LEVEL.getCode());
|
||||
if (!"200".equals(String.valueOf(priorityLevelResult.get("code")))) {
|
||||
throw new ServiceException("优先级别类型数据字典不存在");
|
||||
}
|
||||
List<SysDictData> priorityLevelDataList = JSON.parseArray(JSONUtil.toJsonStr(priorityLevelResult.get("data")), SysDictData.class);
|
||||
|
||||
SysDictData priorityLevelData = priorityLevelDataList.stream().filter(info -> ObjectUtil.equal(info.getDictValue(), stockOutOrderDO.getPriorityLevelCode())).findAny().orElse(null);
|
||||
if (null == priorityLevelData) {
|
||||
throw new ServiceException("优先级别类型【" + stockOutOrderDO.getPriorityLevelCode() + "】数据字典不存在 请联系管理员");
|
||||
}
|
||||
stockOutOrderDO.setPriorityLevelName(priorityLevelData.getDictLabel());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 设置上架库位信息
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/23 14:03
|
||||
* @param outMaterialDetailDO
|
||||
*/
|
||||
private void setStorageLocationInfo(ReservationOutMaterialDetailDO outMaterialDetailDO){
|
||||
AjaxResult storageLocationResult = systemServiceFeign.getStorageLocationInfoByStorageLocationId(outMaterialDetailDO.getStorageLocationId());
|
||||
if(!"200".equals(String.valueOf(storageLocationResult.get("code")))){
|
||||
throw new ServiceException("获取上架库位信息失败");
|
||||
}
|
||||
StorageLocationFeignPO storageLocationFeignPO = JSON.parseObject(JSONObject.toJSONString(storageLocationResult.get("data")), StorageLocationFeignPO.class);
|
||||
outMaterialDetailDO.setWarehouseId(storageLocationFeignPO.getWarehouseId());
|
||||
outMaterialDetailDO.setWarehouseCode(storageLocationFeignPO.getWarehouseCode());
|
||||
outMaterialDetailDO.setWarehouseName(storageLocationFeignPO.getWarehouseName());
|
||||
outMaterialDetailDO.setStorageSectionId(storageLocationFeignPO.getStorageSectionId());
|
||||
outMaterialDetailDO.setStorageCode(storageLocationFeignPO.getStorageCode());
|
||||
outMaterialDetailDO.setStorageName(storageLocationFeignPO.getStorageName());
|
||||
outMaterialDetailDO.setStorageLocationId(storageLocationFeignPO.getStorageLocationId());
|
||||
outMaterialDetailDO.setStorageLocationCode(storageLocationFeignPO.getStorageLocationCode());
|
||||
outMaterialDetailDO.setStorageLocationName(storageLocationFeignPO.getStorageLocationName());
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 封装作业人员信息
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/9 20:43
|
||||
* @param stockOutOrderDO
|
||||
*/
|
||||
private void checkOperatorsParam(ReservationStockOutOrderDO stockOutOrderDO){
|
||||
AjaxResult ajaxResult = userServiceFeign.getInfo(stockOutOrderDO.getCheckOperatorsBy());
|
||||
if(!"200".equals(String.valueOf(ajaxResult.get("code")))){
|
||||
throw new ServiceException("获取作业人员信息失败");
|
||||
}
|
||||
UserPo userPo = JSON.parseObject(JSONObject.toJSONString(ajaxResult.get("data")), UserPo.class);
|
||||
stockOutOrderDO.setCheckOperatorsName(userPo.getUserName());
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 设置库存信息
|
||||
* @author ZhouGY
|
||||
* @date 2024/7/19 20:17
|
||||
* @param outMaterialDetailDO
|
||||
*/
|
||||
// private void setMaterialInventory(ReservationOutMaterialDetailDO outMaterialDetailDO){
|
||||
// if (ObjectUtil.isNull(outMaterialDetailDO.getMaterialInventoryId()) || outMaterialDetailDO.getMaterialInventoryId() == 0){
|
||||
// return;
|
||||
// }
|
||||
// MaterialInventoryPO materialInventoryPO = materialInventoryDomainService.getInfo(outMaterialDetailDO.getMaterialInventoryId());
|
||||
// if (materialInventoryPO == null){
|
||||
// throw new ServiceException("物料库存信息不存在");
|
||||
// }
|
||||
// outMaterialDetailDO.setBatchNumber(materialInventoryPO.getBatchNumber());
|
||||
// outMaterialDetailDO.setMaterialStatusCode(materialInventoryPO.getMaterialStatusCode());
|
||||
// outMaterialDetailDO.setMaterialStatusName(materialInventoryPO.getMaterialStatusName());
|
||||
// outMaterialDetailDO.setContainerId(materialInventoryPO.getContainerId());
|
||||
// outMaterialDetailDO.setContainerCode(materialInventoryPO.getContainerCode());
|
||||
// outMaterialDetailDO.setContainerType(materialInventoryPO.getContainerType());
|
||||
// outMaterialDetailDO.setContainerTypeName(materialInventoryPO.getContainerTypeName());
|
||||
// // 库存数量,仅用于前端展示
|
||||
// outMaterialDetailDO.setInventoryQuantity(materialInventoryPO.getInventoryQuantity());
|
||||
// }
|
||||
|
||||
/**
|
||||
* 递归为出库物料明细设置分配按钮显示类型
|
||||
* @param outMaterialDetailPOList 出库物料明细列表
|
||||
*/
|
||||
private void setAllocationButtonTypeRecursively(List<ReservationOutMaterialDetailPO> outMaterialDetailPOList) {
|
||||
if (CollectionUtils.isEmpty(outMaterialDetailPOList)) {
|
||||
return;
|
||||
}
|
||||
|
||||
outMaterialDetailPOList.forEach(outMaterialDetailPO -> {
|
||||
BigDecimal quantity = outMaterialDetailPO.getQuantity(); // 计划数量
|
||||
BigDecimal alreadyAllocationQuantity = outMaterialDetailPO.getAlreadyAllocationQuantity(); // 已分配数量
|
||||
|
||||
// 判断按钮显示类型
|
||||
// 已分配数量 = 0:显示"库存分配"按钮(类型1)
|
||||
// 已分配数量 = 计划数量:显示"取消分配"按钮(类型2)
|
||||
if (alreadyAllocationQuantity == null || alreadyAllocationQuantity.compareTo(BigDecimal.ZERO) == 0) {
|
||||
// 已分配数量为0或null,显示"库存分配"按钮
|
||||
outMaterialDetailPO.setAllocationButtonType(1);
|
||||
} else if (quantity != null && alreadyAllocationQuantity.compareTo(quantity) == 0) {
|
||||
// 已分配数量等于计划数量,显示"取消分配"按钮
|
||||
outMaterialDetailPO.setAllocationButtonType(2);
|
||||
} else {
|
||||
// 其他情况(已分配数量 > 0 但 < 计划数量),不显示按钮或显示其他状态
|
||||
outMaterialDetailPO.setAllocationButtonType(0);
|
||||
}
|
||||
|
||||
// 递归处理子级
|
||||
List<ReservationOutMaterialDetailPO> children = outMaterialDetailPO.getChildren();
|
||||
if (!CollectionUtils.isEmpty(children)) {
|
||||
setAllocationButtonTypeRecursively(children);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
+113
@@ -0,0 +1,113 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.service;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import com.mhd.common.core.exception.digitalLogisticsException.DigitalLogisticsException;
|
||||
import com.mhd.common.core.exception.digitalLogisticsException.UserError;
|
||||
import com.mhd.common.core.utils.IgnoreNullUtil;
|
||||
import com.mhd.common.core.utils.bean.BeanUtils;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDTO;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 出库单Assembler
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
@Component
|
||||
public class ReservationStockOutOrderAssembler {
|
||||
|
||||
/**
|
||||
* 转换实体
|
||||
*/
|
||||
public ReservationStockOutOrderDO toDO(ReservationStockOutOrderDTO stockOutOrderDTO) {
|
||||
ReservationStockOutOrderDO stockOutOrderDO = new ReservationStockOutOrderDO();
|
||||
// 拷贝
|
||||
BeanUtils.copyProperties(stockOutOrderDTO, stockOutOrderDO, IgnoreNullUtil.getNullPropertyNames(stockOutOrderDTO));
|
||||
// 确保查询条件字段被正确传递(查询条件字段需要明确传递,避免被IgnoreNullUtil忽略)
|
||||
stockOutOrderDO.setCreateTimeStart(stockOutOrderDTO.getCreateTimeStart());
|
||||
stockOutOrderDO.setCreateTimeEnd(stockOutOrderDTO.getCreateTimeEnd());
|
||||
stockOutOrderDO.setAuditTimeStart(stockOutOrderDTO.getAuditTimeStart());
|
||||
stockOutOrderDO.setAuditTimeEnd(stockOutOrderDTO.getAuditTimeEnd());
|
||||
stockOutOrderDO.setTabType(stockOutOrderDTO.getTabType());
|
||||
// 列表筛选:前端常传「名称 (编码)」展示串,库内多为纯名称,去掉末尾括号段再 LIKE
|
||||
if (stockOutOrderDTO.getMaterialName() != null && !stockOutOrderDTO.getMaterialName().isEmpty()) {
|
||||
String normalized = normalizeDetailMaterialNameForQuery(stockOutOrderDTO.getMaterialName());
|
||||
stockOutOrderDO.setMaterialName(normalized.isEmpty()
|
||||
? stockOutOrderDTO.getMaterialName().trim()
|
||||
: normalized);
|
||||
}
|
||||
return stockOutOrderDO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换实体
|
||||
*/
|
||||
public ReservationStockOutOrderDO toDOByEdit(ReservationStockOutOrderDTO stockOutOrderDTO) {
|
||||
ReservationStockOutOrderDO stockOutOrderDO = JSONUtil.toBean(JSONUtil.toJsonStr(stockOutOrderDTO), ReservationStockOutOrderDO.class);
|
||||
// 拷贝
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (ObjectUtil.isNull(loginUser)) {
|
||||
throw new DigitalLogisticsException(UserError.TIMEOUT);
|
||||
}
|
||||
// 获取登录人id
|
||||
Long userId = loginUser.getUserid();
|
||||
// 获取用户姓名(优先从UserPo获取,如果为空则使用realname,最后使用username作为兜底)
|
||||
String userRealName = null;
|
||||
if (loginUser.getUserPo() != null && loginUser.getUserPo().getUserName() != null
|
||||
&& !loginUser.getUserPo().getUserName().trim().isEmpty()) {
|
||||
// 优先使用UserPo中的userName(用户真实姓名)
|
||||
userRealName = loginUser.getUserPo().getUserName();
|
||||
} else if (loginUser.getRealname() != null && !loginUser.getRealname().trim().isEmpty()) {
|
||||
// 其次使用realname
|
||||
userRealName = loginUser.getRealname();
|
||||
} else {
|
||||
// 最后使用username(账号)作为兜底
|
||||
userRealName = loginUser.getUsername();
|
||||
}
|
||||
if(stockOutOrderDTO.getOutOrderId() != null){
|
||||
stockOutOrderDO.setUpdateBy(userId);
|
||||
stockOutOrderDO.setUpdateByName(userRealName);
|
||||
stockOutOrderDO.setUpdateTime(new Date());
|
||||
}else {
|
||||
stockOutOrderDO.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
stockOutOrderDO.setOrganizationName(loginUser.getUserPo().getOrganizationName());
|
||||
stockOutOrderDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
stockOutOrderDO.setCreateBy(userId);
|
||||
stockOutOrderDO.setCreateByName(userRealName);
|
||||
stockOutOrderDO.setCreateTime(new Date());
|
||||
stockOutOrderDO.setUpdateBy(userId);
|
||||
stockOutOrderDO.setUpdateByName(userRealName);
|
||||
stockOutOrderDO.setUpdateTime(new Date());
|
||||
stockOutOrderDO.setDelFlag(1);
|
||||
}
|
||||
return stockOutOrderDO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 去掉物料展示名末尾的「 (xxx) / (xxx)」等,便于与库内 material_name 模糊匹配。
|
||||
*/
|
||||
private static String normalizeDetailMaterialNameForQuery(String raw) {
|
||||
if (raw == null) {
|
||||
return null;
|
||||
}
|
||||
String s = raw.trim();
|
||||
// 循环去掉末尾多组括号(兼容「名称 (编码)」或重复后缀)
|
||||
String next;
|
||||
do {
|
||||
next = s.replaceFirst("[\\s\\u3000]*[((][^))]*[))]\\s*$", "").trim();
|
||||
if (next.equals(s)) {
|
||||
break;
|
||||
}
|
||||
s = next;
|
||||
} while (!s.isEmpty());
|
||||
return s;
|
||||
}
|
||||
|
||||
}
|
||||
+652
@@ -0,0 +1,652 @@
|
||||
package com.mhd.oms.domain.reservationStockOutOrder.service;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.utils.OrderSequence;
|
||||
import com.mhd.common.core.utils.StringUtils;
|
||||
import com.mhd.common.core.utils.bean.BeanUtils;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.oms.domain.reservationInMaterialDetail.entity.ReservationInMaterialDetail;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.entity.ReservationOutMaterialDetail;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.facade.IReservationOutMaterialDetailService;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.OutMaterialCheckPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.ReservationOutMaterialDetailPO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailBaseDO;
|
||||
import com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO;
|
||||
//import com.mhd.oms.domain.reservationReservationOutMaterialDetail.repository.po.OutMaterialCheckPO;
|
||||
//import com.mhd.oms.domain.reservationReservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailBaseDO;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.entity.ReservationStockInOrder;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.facade.IReservationStockInOrderService;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.mapper.ReservationStockInOrderMapper;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.po.MaterialBaseInfoPO;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.todo.ReservationStockInOrderDO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.entity.ReservationStockOutOrder;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.facade.IReservationStockOutOrderService;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
import com.mhd.system.api.SystemServiceFeign;
|
||||
import com.mhd.system.api.WmsServiceFeign;
|
||||
import com.mhd.system.api.domain.*;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 出库单
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class ReservationStockOutOrderDomainService {
|
||||
|
||||
@Autowired
|
||||
private IReservationStockOutOrderService stockOutOrderService;
|
||||
@Autowired
|
||||
private IReservationOutMaterialDetailService outMaterialDetailService;
|
||||
@Autowired
|
||||
private IReservationStockInOrderService reservationStockInOrderService;
|
||||
// @Autowired
|
||||
// private IHandoverTaskOrderService handoverTaskOrderService;
|
||||
// @Autowired
|
||||
// private IOutOrderAbnormalService outOrderAbnormalService;
|
||||
// @Autowired
|
||||
// private PickingOrderDomainService pickingOrderDomainService;
|
||||
// @Autowired
|
||||
// private ReplenishmentNoticeDomainService replenishmentNoticeDomainService;
|
||||
// @Autowired
|
||||
// private IMobilizeManageService iMobilizeManageService;
|
||||
// @Autowired
|
||||
// private IMobilizeManageDetailService iMobilizeManageDetailService;
|
||||
// @Autowired
|
||||
// private StockInOrderDomainService stockInOrderDomainService;
|
||||
// @Autowired
|
||||
// private IInventoryStandingDetailService inventoryStandingDetailService;
|
||||
// @Autowired
|
||||
// private IDeliveTaskService deliveTaskService;
|
||||
// @Autowired
|
||||
// private WaveOrderServiceFactory waveOrderServiceFactory;
|
||||
// @Autowired
|
||||
// private IMaterialBaseInfoService materialBaseInfoService;
|
||||
@Autowired
|
||||
private ReservationStockInOrderMapper reservationStockInOrderMapper;
|
||||
// @Autowired
|
||||
// private IMaterialWarehouseControlService materialWarehouseControlService;
|
||||
// @Autowired
|
||||
// private IMaterialInventoryService materialInventoryService;
|
||||
@Resource
|
||||
private SystemServiceFeign systemServiceFeign;
|
||||
@Resource
|
||||
private WmsServiceFeign wmsServiceFeign;
|
||||
// @Autowired
|
||||
// private PushSyncBmsDomainService pushSyncBmsDomainService;
|
||||
// @Autowired
|
||||
// private MaterialBaseInfoMapper materialBaseInfoMapper;
|
||||
// @Autowired
|
||||
// private MaterialInventoryMapper materialInventoryMapper;
|
||||
// @Autowired
|
||||
// private IPickingMaterialDetailService pickingMaterialDetailService;
|
||||
|
||||
/**
|
||||
* 分页查询出库单列表
|
||||
*/
|
||||
public List<ReservationStockOutOrderPO> queryList(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
return stockOutOrderService.queryList(stockOutOrderDO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增出库单
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean insert(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
stockOutOrderDO.setOutOrderNumber(OrderSequence.getOrderCode("CK"));
|
||||
//统计总数量
|
||||
BigDecimal quantity = stockOutOrderDO.getMaterialDetailList().stream().map(ReservationOutMaterialDetailDO::getOutboundQuantity).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
stockOutOrderDO.setQuantity(quantity);
|
||||
// 复核下发状态默认为否(2)
|
||||
if (stockOutOrderDO.getCheckTaskDistribution() == null) {
|
||||
stockOutOrderDO.setCheckTaskDistribution(2);
|
||||
}
|
||||
stockOutOrderService.insert(stockOutOrderDO);
|
||||
return outMaterialDetailService.batchInsert(stockOutOrderDO.getOutOrderNumber(), stockOutOrderDO.getMaterialDetailList());
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量新增出库单
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean batchInsert(List<ReservationStockOutOrderDO> stockOutOrderDOList) {
|
||||
for (ReservationStockOutOrderDO stockOutOrderDO : stockOutOrderDOList){
|
||||
if (StringUtils.isBlank(stockOutOrderDO.getOutOrderNumber())){
|
||||
stockOutOrderDO.setOutOrderNumber(OrderSequence.getOrderCode("CK"));
|
||||
}
|
||||
//设置物料信息
|
||||
setMaterialDetailInfo(stockOutOrderDO);
|
||||
//统计种类
|
||||
stockOutOrderDO.setMaterialQuantity(stockOutOrderDO.getMaterialDetailList().size());
|
||||
//统计总数量
|
||||
BigDecimal quantity = stockOutOrderDO.getMaterialDetailList().stream().map(ReservationOutMaterialDetailDO::getQuantity).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
stockOutOrderDO.setQuantity(quantity);
|
||||
//统计总重量
|
||||
BigDecimal weightLimit = stockOutOrderDO.getMaterialDetailList().stream().map(ReservationOutMaterialDetailDO::getWeightLimit).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
stockOutOrderDO.setWeightLimit(weightLimit);
|
||||
//统计总体积
|
||||
BigDecimal volumeLimit = stockOutOrderDO.getMaterialDetailList().stream().map(ReservationOutMaterialDetailDO::getVolumeLimit).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
stockOutOrderDO.setVolumeLimit(volumeLimit);
|
||||
// 复核下发状态默认为否(2)
|
||||
if (stockOutOrderDO.getCheckTaskDistribution() == null) {
|
||||
stockOutOrderDO.setCheckTaskDistribution(2);
|
||||
}
|
||||
stockOutOrderService.insert(stockOutOrderDO);
|
||||
outMaterialDetailService.batchInsert(stockOutOrderDO.getOutOrderNumber(), stockOutOrderDO.getMaterialDetailList());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改出库单
|
||||
*/
|
||||
public Boolean update(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
ReservationStockOutOrderPO stockInOrderPO = stockOutOrderService.getInfo(stockOutOrderDO.getOutOrderId());
|
||||
if (stockInOrderPO == null){
|
||||
throw new ServiceException("出库单信息不存在");
|
||||
}
|
||||
//设置物料信息
|
||||
setMaterialDetailInfo(stockOutOrderDO);
|
||||
//统计种类
|
||||
stockOutOrderDO.setMaterialQuantity(stockOutOrderDO.getMaterialDetailList().size());
|
||||
//统计总数量
|
||||
BigDecimal quantity = stockOutOrderDO.getMaterialDetailList().stream().map(ReservationOutMaterialDetailDO::getQuantity).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
stockOutOrderDO.setQuantity(quantity);
|
||||
//统计总重量
|
||||
BigDecimal weightLimit = stockOutOrderDO.getMaterialDetailList().stream().map(ReservationOutMaterialDetailDO::getWeightLimit).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
stockOutOrderDO.setWeightLimit(weightLimit);
|
||||
//统计总体积
|
||||
BigDecimal volumeLimit = stockOutOrderDO.getMaterialDetailList().stream().map(ReservationOutMaterialDetailDO::getVolumeLimit).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
stockOutOrderDO.setVolumeLimit(volumeLimit);
|
||||
stockOutOrderService.update(stockOutOrderDO);
|
||||
ReservationOutMaterialDetailBaseDO outMaterialDetailBaseDO = new ReservationOutMaterialDetailBaseDO();
|
||||
BeanUtils.copyProperties(stockOutOrderDO, outMaterialDetailBaseDO);
|
||||
outMaterialDetailBaseDO.setOutOrderNumber(stockInOrderPO.getOutOrderNumber());
|
||||
return outMaterialDetailService.batchUpdate(stockOutOrderDO.getMaterialDetailList(), outMaterialDetailBaseDO);
|
||||
}
|
||||
|
||||
public Boolean close(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
ReservationStockOutOrderPO stockInOrderPO = stockOutOrderService.getInfo(stockOutOrderDO.getOutOrderId());
|
||||
if (stockInOrderPO == null){
|
||||
throw new ServiceException("出库单信息不存在");
|
||||
}
|
||||
|
||||
if (stockInOrderPO.getStatus() != 1){
|
||||
throw new ServiceException("只有已创建状态下能允许关闭出库单");
|
||||
}
|
||||
stockOutOrderDO.setStatus(11);
|
||||
return stockOutOrderService.update(stockOutOrderDO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @description 审核出库单
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/21 13:53
|
||||
|
||||
* @return Boolean
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean auditState(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
|
||||
// 获取用户姓名(优先从UserPo获取,如果为空则使用realname,最后使用username作为兜底)
|
||||
String userRealName = loginUser.getUserPo() != null && loginUser.getUserPo().getUserName() != null
|
||||
? loginUser.getUserPo().getUserName()
|
||||
: (loginUser.getRealname() != null ? loginUser.getRealname() : loginUser.getUsername());
|
||||
return stockOutOrderService.update(null, new UpdateWrapper<ReservationStockOutOrder>().lambda()
|
||||
.set(ReservationStockOutOrder::getReservationAuditId, loginUser.getUserid())
|
||||
.set(ReservationStockOutOrder::getReservationAuditName, userRealName)
|
||||
.set(ReservationStockOutOrder::getReservationAuditTime, new Date())
|
||||
.set(ReservationStockOutOrder::getUpdateBy, loginUser.getUserid())
|
||||
.set(ReservationStockOutOrder::getUpdateByName, userRealName)
|
||||
.set(ReservationStockOutOrder::getUpdateTime, new Date())
|
||||
.in(ReservationStockOutOrder::getOutOrderId, stockOutOrderDO.getOutOrderIds()));
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 审核出库单
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/21 13:53
|
||||
* @param stockOutOrderDO
|
||||
* @return Boolean
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean issueOrder(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
|
||||
// 获取用户姓名(优先从UserPo获取,如果为空则使用realname,最后使用username作为兜底)
|
||||
String userRealName = loginUser.getUserPo() != null && loginUser.getUserPo().getUserName() != null
|
||||
? loginUser.getUserPo().getUserName()
|
||||
: (loginUser.getRealname() != null ? loginUser.getRealname() : loginUser.getUsername());
|
||||
boolean update = stockOutOrderService.update(null, new UpdateWrapper<ReservationStockOutOrder>().lambda()
|
||||
.set(ReservationStockOutOrder::getIssueId, loginUser.getUserid())
|
||||
.set(ReservationStockOutOrder::getIssueName, userRealName)
|
||||
.set(ReservationStockOutOrder::getIssueTime, new Date())
|
||||
.set(ReservationStockOutOrder::getIssueStatus, 1)
|
||||
.set(ReservationStockOutOrder::getUpdateBy, loginUser.getUserid())
|
||||
.set(ReservationStockOutOrder::getUpdateByName, userRealName)
|
||||
.set(ReservationStockOutOrder::getUpdateTime, new Date())
|
||||
.in(ReservationStockOutOrder::getOutOrderId, stockOutOrderDO.getOutOrderIds()));
|
||||
|
||||
//todo下发推送到wms
|
||||
List<Long> inOrderIds = stockOutOrderDO.getOutOrderIds();
|
||||
for (Long inOrderId : inOrderIds) {
|
||||
ReservationStockOutOrder byId = stockOutOrderService.getById(inOrderId);
|
||||
StockOutOrder stockOutOrder = new StockOutOrder();
|
||||
BeanUtils.copyProperties(byId, stockOutOrder);
|
||||
wmsServiceFeign.omsOutOrderAdd(stockOutOrder);
|
||||
String inOrderNumber = stockOutOrder.getOutOrderNumber();
|
||||
List<ReservationOutMaterialDetail> materialDetailList = outMaterialDetailService.list(new QueryWrapper<ReservationOutMaterialDetail>().lambda().eq(ReservationOutMaterialDetail::getOutOrderNumber, inOrderNumber));
|
||||
List<OutMaterialDetail> outMaterialDetailList = new ArrayList<>();
|
||||
for (ReservationOutMaterialDetail reservationOutMaterialDetail : materialDetailList) {
|
||||
OutMaterialDetail outMaterialDetail = new OutMaterialDetail();
|
||||
BeanUtils.copyProperties(reservationOutMaterialDetail, outMaterialDetail);
|
||||
outMaterialDetailList.add(outMaterialDetail);
|
||||
}
|
||||
wmsServiceFeign.omsOutOrderAddDetail(outMaterialDetailList);
|
||||
}
|
||||
return update;
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 修改出库单
|
||||
* @author ZhouGY
|
||||
* @date 2024/8/8 16:18
|
||||
* @param stockOutOrderDb
|
||||
* @param stockOutOrderPO
|
||||
* @return Boolean
|
||||
*/
|
||||
// public Boolean updateReservationStockOutOrderByAllocation(ReservationStockOutOrder stockOutOrderDb, ReservationStockOutOrderPO stockOutOrderPO, Integer type) {
|
||||
// LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
// int status = judgeAllocationQuantityByManualAssign(stockOutOrderPO.getAllocationQuantity(), stockOutOrderDb.getQuantity(),type);
|
||||
// BigDecimal allocationQuantity = stockOutOrderDb.getAllocationQuantity();
|
||||
// BigDecimal alreadyAllocationQuantity = stockOutOrderDb.getAlreadyAllocationQuantity() != null
|
||||
// ? stockOutOrderDb.getAlreadyAllocationQuantity()
|
||||
// : BigDecimal.ZERO;
|
||||
// if (type == 2){
|
||||
// //取消分配:stockOutOrderPO.getAllocationQuantity() 和 stockOutOrderPO.getAlreadyAllocationQuantity() 都是要取消的数量
|
||||
// //物料明细层面的验证已经在 batchCancelAssignUpdate 中完成,这里直接使用即可
|
||||
// BigDecimal cancelQuantity = stockOutOrderPO.getAllocationQuantity();
|
||||
// stockOutOrderService.update(null,new UpdateWrapper<ReservationStockOutOrder>().lambda()
|
||||
// .setSql("allocation_quantity = allocation_quantity - " + cancelQuantity)//取消分配减数量
|
||||
// .eq(ReservationStockOutOrder::getOutOrderId, stockOutOrderDb.getOutOrderId())
|
||||
// );
|
||||
// BigDecimal cancelAlreadyAllocationQuantity = stockOutOrderPO.getAlreadyAllocationQuantity() != null
|
||||
// ? stockOutOrderPO.getAlreadyAllocationQuantity()
|
||||
// : BigDecimal.ZERO;
|
||||
//
|
||||
// // 取消分配:减少已分配数量
|
||||
// // 注意:如果出库单的 alreadyAllocationQuantity 数据不一致(可能为0),使用 cancelAlreadyAllocationQuantity 作为参考
|
||||
// // 但为了数据一致性,我们仍然从当前值中减去取消的数量
|
||||
// if (alreadyAllocationQuantity.compareTo(cancelAlreadyAllocationQuantity) < 0) {
|
||||
// // 如果出库单的已分配数量小于要取消的数量,说明数据不一致,使用要取消的数量作为基准
|
||||
// alreadyAllocationQuantity = cancelAlreadyAllocationQuantity;
|
||||
// }
|
||||
// alreadyAllocationQuantity = alreadyAllocationQuantity.subtract(cancelQuantity);
|
||||
// // 确保不会变成负数
|
||||
// if (alreadyAllocationQuantity.compareTo(BigDecimal.ZERO) < 0) {
|
||||
// alreadyAllocationQuantity = BigDecimal.ZERO;
|
||||
// }
|
||||
// BigDecimal subtract = stockOutOrderPO.getAlreadyAllocationQuantity().subtract(alreadyAllocationQuantity);
|
||||
// if (subtract.compareTo(BigDecimal.ZERO) == 0) {
|
||||
// status = 2;
|
||||
// } else {
|
||||
// status = 3;
|
||||
// }
|
||||
//// status = judgeAllocationQuantityByManualAssign(stockOutOrderPO.getAllocationQuantity(), stockOutOrderPO.getAlreadyAllocationQuantity(),type);
|
||||
//
|
||||
// }else {
|
||||
// allocationQuantity = stockOutOrderPO.getAllocationQuantity();//直接使用返回的分配数量
|
||||
// alreadyAllocationQuantity = alreadyAllocationQuantity.add(stockOutOrderPO.getAlreadyAllocationQuantity() != null
|
||||
// ? stockOutOrderPO.getAlreadyAllocationQuantity()
|
||||
// : BigDecimal.ZERO);
|
||||
// }
|
||||
// LambdaUpdateWrapper<ReservationStockOutOrder> wrapper = new UpdateWrapper<ReservationStockOutOrder>().lambda()
|
||||
// .set(ReservationStockOutOrder::getStatus, status)
|
||||
// .set(ReservationStockOutOrder::getAlreadyAllocationQuantity, alreadyAllocationQuantity)
|
||||
// .set(ReservationStockOutOrder::getUpdateBy, loginUser.getUserid())
|
||||
// .set(ReservationStockOutOrder::getUpdateByName, loginUser.getUsername())
|
||||
// .set(ReservationStockOutOrder::getUpdateTime, new Date())
|
||||
// .eq(ReservationStockOutOrder::getOutOrderId, stockOutOrderDb.getOutOrderId());
|
||||
// if (type != 2){
|
||||
// wrapper.set(ReservationStockOutOrder::getAllocationQuantity, allocationQuantity);
|
||||
// }
|
||||
// return stockOutOrderService.update(null, wrapper);
|
||||
// }
|
||||
|
||||
|
||||
/**
|
||||
* 批量删除出库单
|
||||
*/
|
||||
public Boolean delete(Long[] outOrderIds) {
|
||||
return stockOutOrderService.delete(outOrderIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取出库单详细信息
|
||||
*/
|
||||
public ReservationStockOutOrderPO getInfo(Long outOrderId) {
|
||||
return stockOutOrderService.getInfo(outOrderId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取出库单详细信息
|
||||
*/
|
||||
public ReservationStockOutOrderPO getInfoChildren(Long outOrderId) {
|
||||
ReservationStockOutOrderPO stockOutOrderPO = stockOutOrderService.getInfo(outOrderId);
|
||||
ReservationOutMaterialDetailDO outMaterialDetailDO = new ReservationOutMaterialDetailDO();
|
||||
outMaterialDetailDO.setOutOrderNumber(stockOutOrderPO.getOutOrderNumber());
|
||||
List<ReservationOutMaterialDetailPO> materialDetailPOList = outMaterialDetailService.queryListChildren(outMaterialDetailDO);
|
||||
// for (ReservationOutMaterialDetailPO outMaterialDetailPO : materialDetailPOList) {
|
||||
// String materialNo = outMaterialDetailPO.getMaterialNo();
|
||||
// List<MaterialBaseInfoPO> materialBaseInfos = materialBaseInfoMapper.selectList(new QueryWrapper<MaterialBaseInfoPO>().lambda().eq(MaterialBaseInfoPO::getMaterialCode, materialNo));
|
||||
// if (!CollectionUtils.isEmpty(materialBaseInfos) && materialBaseInfos.size() > 0) {
|
||||
// outMaterialDetailPO.setCommodityName(materialBaseInfos.get(0).getMaterialNamePO());
|
||||
// outMaterialDetailPO.setMaterialCode(materialBaseInfos.get(0).getMaterialCodePO());
|
||||
// outMaterialDetailPO.setMaterialName(materialBaseInfos.get(0).getMaterialNamePO());
|
||||
// }
|
||||
// }
|
||||
stockOutOrderPO.setMaterialDetailList(materialDetailPOList);
|
||||
return stockOutOrderPO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取出库单详细信息(PDA复核管理查询详情)
|
||||
* 复核场景下与PC端getCheckInfo保持一致,返回拣货下发时的完整数据(树形结构、拣货汇总、批次属性等)
|
||||
*/
|
||||
// public ReservationStockOutOrderPO getInfoByApp(Long outOrderId) {
|
||||
// ReservationStockOutOrder stockOutOrder = stockOutOrderService.getById(outOrderId);
|
||||
// if (stockOutOrder == null) {
|
||||
// throw new ServiceException("出库单不存在");
|
||||
// }
|
||||
// // 复核场景:与PC端getCheckInfo保持一致,返回拣货下发的完整数据(含历史记录 status=9 已出库,与列表详情一致)
|
||||
// if (stockOutOrder.getReview() != null && stockOutOrder.getReview() == 1
|
||||
// && stockOutOrder.getStatus() != null && (stockOutOrder.getStatus() == 7 || stockOutOrder.getStatus() == 8 || stockOutOrder.getStatus() == 9)) {
|
||||
// ReservationStockOutOrderDO stockOutOrderDO = new ReservationStockOutOrderDO();
|
||||
// stockOutOrderDO.setOutOrderNumber(stockOutOrder.getOutOrderNumber());
|
||||
// ReservationStockOutOrderPO stockOutOrderPO = getCheckInfo(stockOutOrderDO);
|
||||
// // PDA端需扁平化树形结构,与PC端展开后的展示条数一致(父项+子项全部展开为独立行)
|
||||
// List<ReservationOutMaterialDetailPO> flattenedList = flattenMaterialDetailTree(stockOutOrderPO.getMaterialDetailList());
|
||||
// stockOutOrderPO.setMaterialDetailList(flattenedList);
|
||||
// if (stockOutOrderPO.getOutMaterialCheckPO() != null) {
|
||||
// stockOutOrderPO.getOutMaterialCheckPO().setCount(flattenedList.size());
|
||||
// }
|
||||
// return stockOutOrderPO;
|
||||
// }
|
||||
// // 非复核场景:保持原有逻辑
|
||||
// ReservationStockOutOrderPO stockOutOrderPO = stockOutOrderService.getInfo(outOrderId);
|
||||
// ReservationOutMaterialDetailDO outMaterialDetailDO = new ReservationOutMaterialDetailDO();
|
||||
// outMaterialDetailDO.setOutOrderNumber(stockOutOrderPO.getOutOrderNumber());
|
||||
// List<ReservationOutMaterialDetailPO> materialDetailPOList = outMaterialDetailService.queryList(outMaterialDetailDO);
|
||||
// materialDetailPOList.forEach(d -> {
|
||||
// if (d.getWaitCheckQuantity() != null) d.setActualQuantity(d.getWaitCheckQuantity());
|
||||
// });
|
||||
// stockOutOrderPO.setMaterialDetailList(materialDetailPOList);
|
||||
// return stockOutOrderPO;
|
||||
// }
|
||||
|
||||
// @Autowired
|
||||
// private IMaterialBarCodeService materialBarCodeService;
|
||||
|
||||
/**
|
||||
* 获取出库单复核详细信息
|
||||
*/
|
||||
// public ReservationStockOutOrderPO getCheckInfo(ReservationStockOutOrderDO stockOutOrderDO) {
|
||||
// String outOrderNumber = stockOutOrderDO.getOutOrderNumber();
|
||||
// ReservationStockOutOrder stockOutOrder = stockOutOrderService.getOne(new QueryWrapper<ReservationStockOutOrder>().lambda()
|
||||
// .eq(ReservationStockOutOrder::getDelFlag, 1)
|
||||
// .eq(ReservationStockOutOrder::getOutOrderNumber, stockOutOrderDO.getOutOrderNumber()));
|
||||
// if (stockOutOrder == null){
|
||||
// throw new ServiceException("出库单【" + stockOutOrderDO.getOutOrderNumber() + "】不存在");
|
||||
// }
|
||||
// if (stockOutOrder.getReview() != 1){
|
||||
// throw new ServiceException("出库单【" + stockOutOrderDO.getOutOrderNumber() + "】不需要复核");
|
||||
// }
|
||||
// if (stockOutOrder.getStatus() != 7 && stockOutOrder.getStatus() != 8){
|
||||
// throw new ServiceException("出库单【" + stockOutOrderDO.getOutOrderNumber() + "】状态不是拣货完成或复核中");
|
||||
// }
|
||||
// ReservationStockOutOrderPO stockOutOrderPO = new ReservationStockOutOrderPO();
|
||||
// BeanUtils.copyProperties(stockOutOrder, stockOutOrderPO);
|
||||
// ReservationOutMaterialDetailDO outMaterialDetailDO = new ReservationOutMaterialDetailDO();
|
||||
// outMaterialDetailDO.setOutOrderNumber(stockOutOrderPO.getOutOrderNumber());
|
||||
// List<ReservationOutMaterialDetailPO> outMaterialDetailPOList = outMaterialDetailService.queryListChildren(outMaterialDetailDO);
|
||||
// for (ReservationOutMaterialDetailPO outMaterialDetailPO : outMaterialDetailPOList) {//获取物料条形码
|
||||
// List<MaterialBarCodePO> materialBarCodePOList = materialBarCodeService.getInfoByMaterialBaseInfoIds(outMaterialDetailPO.getMaterialBaseInfoId());
|
||||
// if (materialBarCodePOList != null && !materialBarCodePOList.isEmpty()) {
|
||||
// Map<Long, MaterialBarCodePO> collect = materialBarCodePOList.stream()
|
||||
// .collect(Collectors.toMap(
|
||||
// MaterialBarCodePO::getMaterialBaseInfoId,
|
||||
// po -> po,
|
||||
// (existing, replacement) -> existing
|
||||
// ));
|
||||
// MaterialBarCodePO materialBarCodePO = collect.get(outMaterialDetailPO.getMaterialBaseInfoId());
|
||||
// if (materialBarCodePO != null && materialBarCodePO.getBarCode() != null) {
|
||||
// outMaterialDetailPO.setBarCode(materialBarCodePO.getBarCode());
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// for (ReservationOutMaterialDetailPO outMaterialDetailPO : outMaterialDetailPOList) {
|
||||
// outMaterialDetailPO.setMaterialCode(outMaterialDetailPO.getMaterialNo());
|
||||
// outMaterialDetailPO.setMaterialName(outMaterialDetailPO.getCommodityName());
|
||||
// Long uniqueId = outMaterialDetailPO.getUniqueId();
|
||||
// PickingMaterialDetailPO pickingMaterialDetailPO = pickingMaterialDetailService.queryTotalsByOutNumberAndBaseId(uniqueId);
|
||||
// if (ObjectUtils.isNotEmpty(pickingMaterialDetailPO)) {
|
||||
// outMaterialDetailPO.setTotalArea(pickingMaterialDetailPO.getTotalArea());
|
||||
// outMaterialDetailPO.setTotalVolume(pickingMaterialDetailPO.getTotalVolume());
|
||||
// outMaterialDetailPO.setTotalNetWeight(pickingMaterialDetailPO.getTotalNetWeight());
|
||||
// outMaterialDetailPO.setTotalGrossWeight(pickingMaterialDetailPO.getTotalGrossWeight());
|
||||
// outMaterialDetailPO.setCheckArea(pickingMaterialDetailPO.getTotalArea());
|
||||
// outMaterialDetailPO.setCheckVolume(pickingMaterialDetailPO.getTotalVolume());
|
||||
// outMaterialDetailPO.setCheckNetWeight(pickingMaterialDetailPO.getTotalNetWeight());
|
||||
// outMaterialDetailPO.setCheckGrossWeight(pickingMaterialDetailPO.getTotalGrossWeight());
|
||||
// // 拣货数量:优先 picking_material_detail,否则 out_material_detail
|
||||
// BigDecimal pickQty = (pickingMaterialDetailPO.getPickingQuantity() != null && pickingMaterialDetailPO.getPickingQuantity().compareTo(BigDecimal.ZERO) > 0)
|
||||
// ? pickingMaterialDetailPO.getPickingQuantity() : outMaterialDetailPO.getPickingQuantity();
|
||||
// BigDecimal checkQty = outMaterialDetailPO.getCheckQuantity() != null ? outMaterialDetailPO.getCheckQuantity() : BigDecimal.ZERO;
|
||||
// // 待复核数量 = 拣货数量 - 已复核数量(复核提交后应减少)
|
||||
// BigDecimal waitQty = (pickQty != null ? pickQty : BigDecimal.ZERO).subtract(checkQty);
|
||||
// if (waitQty.compareTo(BigDecimal.ZERO) < 0) {
|
||||
// waitQty = BigDecimal.ZERO;
|
||||
// }
|
||||
// outMaterialDetailPO.setWaitCheckQuantity(waitQty);
|
||||
// // quantity=PC下发时的拣货数量,actualQuantity:已复核则取checkQuantity,否则取待复核数量
|
||||
// if (pickQty != null) {
|
||||
// outMaterialDetailPO.setQuantity(pickQty);
|
||||
// }
|
||||
// outMaterialDetailPO.setActualQuantity(checkQty.compareTo(BigDecimal.ZERO) > 0 ? checkQty : waitQty);
|
||||
// }
|
||||
// List<ReservationOutMaterialDetailPO> children = outMaterialDetailPO.getChildren();
|
||||
// if (!CollectionUtils.isEmpty(children)) {
|
||||
// for (ReservationOutMaterialDetailPO outMaterialDetailPOChild : children) {
|
||||
// outMaterialDetailPOChild.setMaterialCode(outMaterialDetailPOChild.getMaterialNo());
|
||||
// outMaterialDetailPOChild.setMaterialName(outMaterialDetailPOChild.getCommodityName());
|
||||
// Long uniqueIdChild = outMaterialDetailPOChild.getUniqueId();
|
||||
// PickingMaterialDetailPO pickingMaterialDetailPO1 = pickingMaterialDetailService.queryTotalsByOutNumberAndBaseId(uniqueIdChild);
|
||||
// if (ObjectUtils.isNotEmpty(pickingMaterialDetailPO1)) {
|
||||
// outMaterialDetailPOChild.setTotalArea(pickingMaterialDetailPO1.getTotalArea());
|
||||
// outMaterialDetailPOChild.setTotalVolume(pickingMaterialDetailPO1.getTotalVolume());
|
||||
// outMaterialDetailPOChild.setTotalNetWeight(pickingMaterialDetailPO1.getTotalNetWeight());
|
||||
// outMaterialDetailPOChild.setTotalGrossWeight(pickingMaterialDetailPO1.getTotalGrossWeight());
|
||||
// outMaterialDetailPOChild.setCheckArea(pickingMaterialDetailPO1.getTotalArea());
|
||||
// outMaterialDetailPOChild.setCheckVolume(pickingMaterialDetailPO1.getTotalVolume());
|
||||
// outMaterialDetailPOChild.setCheckNetWeight(pickingMaterialDetailPO1.getTotalNetWeight());
|
||||
// outMaterialDetailPOChild.setCheckGrossWeight(pickingMaterialDetailPO1.getTotalGrossWeight());
|
||||
// // 拣货数量:优先 picking_material_detail,否则 out_material_detail
|
||||
// BigDecimal pickQtyChild = (pickingMaterialDetailPO1.getPickingQuantity() != null && pickingMaterialDetailPO1.getPickingQuantity().compareTo(BigDecimal.ZERO) > 0)
|
||||
// ? pickingMaterialDetailPO1.getPickingQuantity() : outMaterialDetailPOChild.getPickingQuantity();
|
||||
// BigDecimal checkQtyChild = outMaterialDetailPOChild.getCheckQuantity() != null ? outMaterialDetailPOChild.getCheckQuantity() : BigDecimal.ZERO;
|
||||
// // 待复核数量 = 拣货数量 - 已复核数量(复核提交后应减少)
|
||||
// BigDecimal waitQtyChild = (pickQtyChild != null ? pickQtyChild : BigDecimal.ZERO).subtract(checkQtyChild);
|
||||
// if (waitQtyChild.compareTo(BigDecimal.ZERO) < 0) {
|
||||
// waitQtyChild = BigDecimal.ZERO;
|
||||
// }
|
||||
// outMaterialDetailPOChild.setWaitCheckQuantity(waitQtyChild);
|
||||
// // quantity=PC下发时的拣货数量,actualQuantity:已复核则取checkQuantity,否则取待复核数量
|
||||
// if (pickQtyChild != null) {
|
||||
// outMaterialDetailPOChild.setQuantity(pickQtyChild);
|
||||
// }
|
||||
// outMaterialDetailPOChild.setActualQuantity(checkQtyChild.compareTo(BigDecimal.ZERO) > 0 ? checkQtyChild : waitQtyChild);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// stockOutOrderPO.setMaterialDetailList(outMaterialDetailPOList);
|
||||
// BigDecimal weightLimit = BigDecimal.ZERO;
|
||||
// BigDecimal volumeLimit = BigDecimal.ZERO;
|
||||
// BigDecimal wantNumber = BigDecimal.ZERO;
|
||||
// BigDecimal alreadyNumber = BigDecimal.ZERO;
|
||||
// for (ReservationOutMaterialDetailPO outMaterialDetailPO : outMaterialDetailPOList){
|
||||
// weightLimit = weightLimit.add(outMaterialDetailPO.getWeightLimit());
|
||||
// volumeLimit = volumeLimit.add(outMaterialDetailPO.getVolumeLimit());
|
||||
// // wantNumber=拣货数量总和,alreadyNumber=已复核总和,notHaveNumber=剩余待复核
|
||||
// BigDecimal pickQty = (outMaterialDetailPO.getQuantity() != null ? outMaterialDetailPO.getQuantity() : outMaterialDetailPO.getPickingQuantity());
|
||||
// wantNumber = wantNumber.add(pickQty != null ? pickQty : BigDecimal.ZERO);
|
||||
// alreadyNumber = alreadyNumber.add(outMaterialDetailPO.getCheckQuantity() != null ? outMaterialDetailPO.getCheckQuantity() : BigDecimal.ZERO);
|
||||
// }
|
||||
// OutMaterialCheckPO outMaterialCheckPO = new OutMaterialCheckPO();
|
||||
// outMaterialCheckPO.setCount(outMaterialDetailPOList.size());
|
||||
// outMaterialCheckPO.setWeightLimit(weightLimit);
|
||||
// outMaterialCheckPO.setVolumeLimit(volumeLimit);
|
||||
// outMaterialCheckPO.setAlreadyNumber(alreadyNumber);
|
||||
// outMaterialCheckPO.setNotHaveNumber(wantNumber.subtract(alreadyNumber));
|
||||
// stockOutOrderPO.setOutMaterialCheckPO(outMaterialCheckPO);
|
||||
//
|
||||
// List<ReservationOutMaterialDetailPO> materialDetailList = stockOutOrderPO.getMaterialDetailList();
|
||||
// // 性能优化:批量获取批次属性,避免N+1查询问题
|
||||
// // 1. 收集所有唯一的materialBaseInfoId
|
||||
// Set<Long> materialBaseInfoIdSet = materialDetailList.stream()
|
||||
// .map(ReservationOutMaterialDetailPO::getMaterialBaseInfoId)
|
||||
// .filter(Objects::nonNull)
|
||||
// .collect(Collectors.toSet());
|
||||
//
|
||||
// // 2. 批量查询批次属性(使用Map缓存,避免重复查询相同的materialBaseInfoId)
|
||||
// Map<Long, List<BatchDetailFeignPO>> batchDetailMap = new HashMap<>();
|
||||
// for (Long materialBaseInfoId : materialBaseInfoIdSet) {
|
||||
// try {
|
||||
// AjaxResult ajaxResult = systemServiceFeign.getBatchDetailListByMaterialBaseInfoId(materialBaseInfoId);
|
||||
// if (ajaxResult != null && "200".equals(String.valueOf(ajaxResult.get("code")))) {
|
||||
// List<BatchDetailFeignPO> batchDetailFeignPOList = JSON.parseArray(
|
||||
// JSONObject.toJSONString(ajaxResult.get("data")), BatchDetailFeignPO.class);
|
||||
// if (!CollectionUtils.isEmpty(batchDetailFeignPOList)) {
|
||||
// // 过滤isDisplay=1的属性
|
||||
// List<BatchDetailFeignPO> filteredList = batchDetailFeignPOList.stream()
|
||||
// .filter(batchDetail -> batchDetail.getIsDisplay() != null && batchDetail.getIsDisplay() == 1)
|
||||
// .collect(Collectors.toList());
|
||||
// batchDetailMap.put(materialBaseInfoId, filteredList);
|
||||
// }
|
||||
// }
|
||||
// } catch (Exception e) {
|
||||
// log.warn("获取物料批次属性失败,物料基础信息ID:{},错误:{}", materialBaseInfoId, e.getMessage());
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// // 3. 为每个物料明细设置更多属性(从库存表中获取值)
|
||||
// setMaterialMoreDetailListFromInventory(materialDetailList, batchDetailMap);
|
||||
// // 过滤无拣货数量的明细:pickingQuantity 或 waitCheckQuantity 任一 >= 1 则保留(waitCheckQuantity 来自 picking_material_detail 已拣货数量)
|
||||
// materialDetailList.removeIf(detail -> {
|
||||
// BigDecimal pickQty = detail.getPickingQuantity() != null ? detail.getPickingQuantity() : BigDecimal.ZERO;
|
||||
// BigDecimal waitQty = detail.getWaitCheckQuantity() != null ? detail.getWaitCheckQuantity() : BigDecimal.ZERO;
|
||||
// return pickQty.compareTo(BigDecimal.ONE) < 0 && waitQty.compareTo(BigDecimal.ONE) < 0;
|
||||
// });
|
||||
// stockOutOrderPO.setMaterialDetailList(materialDetailList);
|
||||
// return stockOutOrderPO;
|
||||
// }
|
||||
|
||||
|
||||
/**
|
||||
* 将物料明细树形结构扁平化,PDA端展示与PC端条数一致(父项+子项全部展开为独立行)
|
||||
*/
|
||||
private List<ReservationOutMaterialDetailPO> flattenMaterialDetailTree(List<ReservationOutMaterialDetailPO> treeList) {
|
||||
if (CollectionUtils.isEmpty(treeList)) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<ReservationOutMaterialDetailPO> result = new ArrayList<>();
|
||||
for (ReservationOutMaterialDetailPO item : treeList) {
|
||||
result.add(item);
|
||||
List<ReservationOutMaterialDetailPO> children = item.getChildren();
|
||||
if (!CollectionUtils.isEmpty(children)) {
|
||||
List<ReservationOutMaterialDetailPO> flattenedChildren = flattenMaterialDetailTree(children);
|
||||
result.addAll(flattenedChildren);
|
||||
item.setChildren(null);
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 修改出库单数据
|
||||
* @author ZhouGY
|
||||
* @date 2024/7/19 22:52
|
||||
* @param stockOutOrderPO
|
||||
* @param stockOutOrderDb
|
||||
* @param type 1-分配 2-取消分配
|
||||
* @return Boolean
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean updateReservationStockOutOrder(ReservationStockOutOrderPO stockOutOrderPO, ReservationStockOutOrder stockOutOrderDb, Integer type){
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
ReservationStockOutOrder stockOutOrder = new ReservationStockOutOrder();
|
||||
stockOutOrder.setOutOrderId(stockOutOrderDb.getOutOrderId());
|
||||
stockOutOrder.setStatus(8);
|
||||
stockOutOrder.setCheckStatus(2);
|
||||
if (type == 1){
|
||||
stockOutOrder.setCheckQuantity(stockOutOrderDb.getCheckQuantity().add(stockOutOrderPO.getCheckQuantity()));
|
||||
}else {
|
||||
stockOutOrder.setCheckQuantity(stockOutOrderDb.getCheckQuantity().subtract(stockOutOrderPO.getCheckQuantity()));
|
||||
}
|
||||
stockOutOrder.setUpdateBy(loginUser.getUserid());
|
||||
stockOutOrder.setUpdateByName(loginUser.getUsername());
|
||||
stockOutOrder.setUpdateTime(new Date());
|
||||
return stockOutOrderService.updateById(stockOutOrder);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @description 设置物料信息
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/23 14:03
|
||||
* @param stockOutOrderDO
|
||||
*/
|
||||
private void setMaterialDetailInfo(ReservationStockOutOrderDO stockOutOrderDO){
|
||||
List<ReservationOutMaterialDetailDO> outMaterialDetailDOList = stockOutOrderDO.getMaterialDetailList();
|
||||
outMaterialDetailDOList.forEach(outMaterialDetailDO -> {
|
||||
// Long materialBaseInfoId = outMaterialDetailDO.getMaterialBaseInfoId();
|
||||
MaterialBaseInfoPO materialBaseInfoPO = reservationStockInOrderMapper.getinfo(outMaterialDetailDO.getMaterialBaseInfoId());
|
||||
if (materialBaseInfoPO == null){
|
||||
throw new ServiceException("物料基础信息不存在");
|
||||
}
|
||||
outMaterialDetailDO.setMaterialCode(materialBaseInfoPO.getMaterialCode());
|
||||
outMaterialDetailDO.setMaterialName(materialBaseInfoPO.getMaterialName());
|
||||
outMaterialDetailDO.setBarCode(materialBaseInfoPO.getBarCode());
|
||||
outMaterialDetailDO.setPackId(materialBaseInfoPO.getPackId());
|
||||
outMaterialDetailDO.setPackCode(materialBaseInfoPO.getPackCode());
|
||||
outMaterialDetailDO.setPackName(materialBaseInfoPO.getPackName());
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,63 @@
|
||||
package com.mhd.oms.domain.sysTableConfig.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* @author: brb
|
||||
* @description:
|
||||
* @create: 2026-03-04 14:30
|
||||
*/
|
||||
@Data
|
||||
@TableName("sys_table_config")
|
||||
public class SysTableConfig extends BaseVOEntity {
|
||||
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
/*
|
||||
* 仓库id
|
||||
* */
|
||||
@ApiModelProperty("仓库ID")
|
||||
@Excel(name = "仓库ID")
|
||||
private Long warehouseId;
|
||||
/**组织ID*/
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
@Excel(name = "组织ID", width = 15)
|
||||
private Long organizationId;
|
||||
/**一级组织ID*/
|
||||
@ApiModelProperty(value = "一级组织ID")
|
||||
@Excel(name = "一级组织ID", width = 15)
|
||||
private Long topOrganizationId;
|
||||
/**组织名称*/
|
||||
@ApiModelProperty(value = "组织名称")
|
||||
@Excel(name = "组织名称", width = 15)
|
||||
private String organizationName;
|
||||
/**键*/
|
||||
@ApiModelProperty(value = "键")
|
||||
@Excel(name = "键", width = 15)
|
||||
private String key;
|
||||
/**值*/
|
||||
@ApiModelProperty(value = "值")
|
||||
@Excel(name = "值", width = 15)
|
||||
private String value;
|
||||
/**备注说明*/
|
||||
@ApiModelProperty(value = "备注说明")
|
||||
@Excel(name = "备注说明", width = 15)
|
||||
private String remark;
|
||||
/**明细值*/
|
||||
@ApiModelProperty(value = "明细值")
|
||||
@Excel(name = "明细值", width = 15)
|
||||
private String detailValue;
|
||||
/**物料添加方式*/
|
||||
@ApiModelProperty(value = "物料添加方式")
|
||||
@Excel(name = "物料添加方式", width = 15)
|
||||
private String materialAddType;
|
||||
}
|
||||
+57
@@ -0,0 +1,57 @@
|
||||
package com.mhd.oms.domain.sysTableConfig.repository.facade;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.mhd.oms.domain.sysTableConfig.entity.SysTableConfig;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.todo.SysTableConfigDTO;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.vo.SysTableConfigVO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface ISysTableConfigService extends IService<SysTableConfig> {
|
||||
|
||||
|
||||
/**
|
||||
* 分页查询配置列表
|
||||
* @param page 分页对象
|
||||
* @param sysTableConfigDTO 查询条件
|
||||
* @return 配置列表
|
||||
*/
|
||||
Page<SysTableConfigVO> queryList(Page<SysTableConfigVO> page, SysTableConfigDTO sysTableConfigDTO);
|
||||
|
||||
/**
|
||||
* 根据组织 ID 和键查询配置
|
||||
* @param organizationId 组织 ID
|
||||
* @param key 配置键
|
||||
* @return 配置信息
|
||||
*/
|
||||
SysTableConfig getByOrgIdAndKey(Long organizationId, String key,Long warehouseId);
|
||||
|
||||
/**
|
||||
* 根据组织 ID 查询所有配置
|
||||
* @param organizationId 组织 ID
|
||||
* @return 配置列表
|
||||
*/
|
||||
List<SysTableConfig> listByOrgId(Long organizationId,Long warehouseId);
|
||||
|
||||
/**
|
||||
* 保存或更新配置(根据组织 ID 和键判断是新增还是更新)
|
||||
* @param sysTableConfigDTO 配置信息
|
||||
* @return 是否成功
|
||||
*/
|
||||
boolean saveOrUpdateConfig(SysTableConfigDTO sysTableConfigDTO);
|
||||
|
||||
/**
|
||||
* 删除配置
|
||||
* @param ids 主键 ID 列表
|
||||
* @return 是否成功
|
||||
*/
|
||||
int delete(List<String> ids);
|
||||
|
||||
/**
|
||||
* 根据组织 ID 删除所有配置
|
||||
* @param organizationId 组织 ID
|
||||
* @return 是否成功
|
||||
*/
|
||||
int deleteByOrgId(Long organizationId);
|
||||
}
|
||||
+47
@@ -0,0 +1,47 @@
|
||||
package com.mhd.oms.domain.sysTableConfig.repository.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.mhd.oms.domain.sysTableConfig.entity.SysTableConfig;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.vo.SysTableConfigVO;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @Description: 系统表配置(全局表内容展示顺序)
|
||||
* @Author: Assistant
|
||||
* @Date: 2026-03-04
|
||||
* @Version: V1.0
|
||||
*/
|
||||
public interface SysTableConfigMapper extends BaseMapper<SysTableConfig> {
|
||||
|
||||
/**
|
||||
* 根据组织 ID 和键查询配置
|
||||
* @param organizationId 组织 ID
|
||||
* @param key 配置键
|
||||
* @return 配置信息
|
||||
*/
|
||||
@Select("SELECT * FROM sys_table_config WHERE organization_id = #{organizationId} AND key = #{key} and warehouse_id = #{warehouseId}")
|
||||
SysTableConfig getByOrgIdAndKey(@Param("organizationId") Long organizationId, @Param("key") String key, @Param("warehouseId") Long warehouseId);
|
||||
|
||||
/**
|
||||
* 根据组织 ID 查询所有配置
|
||||
* @param organizationId 组织 ID
|
||||
* @return 配置列表
|
||||
*/
|
||||
@Select("SELECT * FROM sys_table_config WHERE organization_id = #{organizationId} and warehouse_id = #{warehouseId} ORDER BY create_time DESC")
|
||||
List<SysTableConfig> listByOrgId(@Param("organizationId") Long organizationId, @Param("warehouseId") Long warehouseId);
|
||||
|
||||
/**
|
||||
* 分页查询配置列表
|
||||
* @param page 分页对象
|
||||
* @param organizationId 组织 ID
|
||||
* @param key 配置键(可选)
|
||||
* @return 配置列表
|
||||
*/
|
||||
List<SysTableConfigVO> queryList(Page<SysTableConfigVO> page,
|
||||
@Param("organizationId") Long organizationId,
|
||||
@Param("key") String key, @Param("warehouseId") Long warehouseId);
|
||||
}
|
||||
+149
@@ -0,0 +1,149 @@
|
||||
package com.mhd.oms.domain.sysTableConfig.repository.persistence;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.utils.StringUtils;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.oms.domain.sysTableConfig.entity.SysTableConfig;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.facade.ISysTableConfigService;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.mapper.SysTableConfigMapper;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.todo.SysTableConfigDTO;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.vo.SysTableConfigVO;
|
||||
import com.mhd.system.api.domain.WlhyLoginUser;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
@Service
|
||||
public class SysTableConfigServiceImpl extends ServiceImpl<SysTableConfigMapper, SysTableConfig> implements ISysTableConfigService {
|
||||
|
||||
|
||||
@Resource
|
||||
private SysTableConfigMapper sysTableConfigMapper;
|
||||
|
||||
@Override
|
||||
public Page<SysTableConfigVO> queryList(Page<SysTableConfigVO> page, SysTableConfigDTO sysTableConfigDTO) {
|
||||
// 获取登录人信息(可选,用于自动填充组织 ID)
|
||||
try {
|
||||
WlhyLoginUser loginUser = SecurityUtils.getLoginUser().getWlhyLoginUser();
|
||||
if (loginUser != null && sysTableConfigDTO.getOrganizationId() == null) {
|
||||
// 如果没有传入组织 ID,可以选择不设置或者设置默认值
|
||||
// 这里保持传入参数不变,由 Mapper 层处理 null 值
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
List<SysTableConfigVO> list = sysTableConfigMapper.queryList(page,
|
||||
sysTableConfigDTO.getOrganizationId() != null ? sysTableConfigDTO.getOrganizationId().longValue() : null,
|
||||
sysTableConfigDTO.getKey(), sysTableConfigDTO.getWarehouseId());
|
||||
return page.setRecords(list);
|
||||
}
|
||||
|
||||
@Override
|
||||
public SysTableConfig getByOrgIdAndKey(Long organizationId, String key,Long warehouseId) {
|
||||
if (organizationId == null || StringUtils.isBlank(key)) {
|
||||
throw new ServiceException("组织 ID 和键不能为空");
|
||||
}
|
||||
if (warehouseId == null) {
|
||||
throw new ServiceException("仓库 ID 不能为空");
|
||||
}
|
||||
return sysTableConfigMapper.getByOrgIdAndKey(organizationId, key,warehouseId);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SysTableConfig> listByOrgId(Long organizationId, Long warehouseId) {
|
||||
if (organizationId == null) {
|
||||
throw new ServiceException("组织 ID 不能为空");
|
||||
}
|
||||
if (warehouseId == null) {
|
||||
throw new ServiceException("仓库 ID 不能为空");
|
||||
}
|
||||
return sysTableConfigMapper.listByOrgId(organizationId, warehouseId);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public boolean saveOrUpdateConfig(SysTableConfigDTO sysTableConfigDTO) {
|
||||
if (sysTableConfigDTO.getOrganizationId() == null) {
|
||||
throw new ServiceException("组织 ID 不能为空");
|
||||
}
|
||||
if (StringUtils.isBlank(sysTableConfigDTO.getKey())) {
|
||||
throw new ServiceException("配置键不能为空");
|
||||
}
|
||||
if (StringUtils.isBlank(sysTableConfigDTO.getValue())) {
|
||||
throw new ServiceException("配置值不能为空");
|
||||
}
|
||||
if (sysTableConfigDTO.getWarehouseId() == null) {
|
||||
throw new ServiceException("仓库 ID 不能为空");
|
||||
}
|
||||
|
||||
// 获取登录人信息
|
||||
WlhyLoginUser loginUser = SecurityUtils.getLoginUser().getWlhyLoginUser();
|
||||
String username = loginUser != null ? loginUser.getUsername() : "system";
|
||||
|
||||
// 判断是新增还是更新
|
||||
SysTableConfig existingConfig = sysTableConfigMapper.getByOrgIdAndKey(
|
||||
sysTableConfigDTO.getOrganizationId().longValue(),
|
||||
sysTableConfigDTO.getKey(), sysTableConfigDTO.getWarehouseId());
|
||||
|
||||
if (existingConfig != null) {
|
||||
// 更新
|
||||
existingConfig.setValue(sysTableConfigDTO.getValue());
|
||||
//existingConfig.setUpdateBy(username);
|
||||
existingConfig.setUpdateTime(new Date());
|
||||
existingConfig.setDetailValue(sysTableConfigDTO.getDetailValue());
|
||||
existingConfig.setMaterialAddType(sysTableConfigDTO.getMaterialAddType());
|
||||
if (StringUtils.isNotBlank(sysTableConfigDTO.getRemark())) {
|
||||
existingConfig.setRemark(sysTableConfigDTO.getRemark());
|
||||
}
|
||||
return this.updateById(existingConfig);
|
||||
} else {
|
||||
// 新增
|
||||
SysTableConfig newConfig = new SysTableConfig();
|
||||
BeanUtils.copyProperties(sysTableConfigDTO, newConfig);
|
||||
//newConfig.setCreateBy(username);
|
||||
newConfig.setCreateTime(new Date());
|
||||
//newConfig.setUpdateBy(username);
|
||||
newConfig.setUpdateTime(new Date());
|
||||
return this.save(newConfig);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public int delete(List<String> ids) {
|
||||
if (ids == null || ids.isEmpty()) {
|
||||
throw new ServiceException("删除的 ID 不能为空");
|
||||
}
|
||||
|
||||
// 简单的日志记录,不做复杂的权限验证
|
||||
try {
|
||||
WlhyLoginUser loginUser = SecurityUtils.getLoginUser().getWlhyLoginUser();
|
||||
if (loginUser != null) {
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
return this.removeByIds(ids) ? ids.size() : 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public int deleteByOrgId(Long organizationId) {
|
||||
if (organizationId == null) {
|
||||
throw new ServiceException("组织 ID 不能为空");
|
||||
}
|
||||
|
||||
LambdaQueryWrapper<SysTableConfig> queryWrapper = new LambdaQueryWrapper<>();
|
||||
queryWrapper.eq(SysTableConfig::getOrganizationId, organizationId);
|
||||
|
||||
return this.remove(queryWrapper) ? 1 : 0;
|
||||
}
|
||||
}
|
||||
+61
@@ -0,0 +1,61 @@
|
||||
package com.mhd.oms.domain.sysTableConfig.repository.po;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* @author: brb
|
||||
* @description:
|
||||
* @create: 2026-03-04 14:30
|
||||
*/
|
||||
@Data
|
||||
public class SysTableConfigPO extends BaseVOEntity {
|
||||
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
/*
|
||||
* 仓库id
|
||||
* */
|
||||
@ApiModelProperty("仓库ID")
|
||||
@Excel(name = "仓库ID")
|
||||
private Long warehouseId;
|
||||
/**组织ID*/
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
@Excel(name = "组织ID", width = 15)
|
||||
private Long organizationId;
|
||||
/**键*/
|
||||
@ApiModelProperty(value = "键")
|
||||
@Excel(name = "键", width = 15)
|
||||
private String key;
|
||||
/**值*/
|
||||
@ApiModelProperty(value = "值")
|
||||
@Excel(name = "值", width = 15)
|
||||
private String value;
|
||||
/**备注说明*/
|
||||
@ApiModelProperty(value = "备注说明")
|
||||
@Excel(name = "备注说明", width = 15)
|
||||
private String remark;
|
||||
/**明细值*/
|
||||
@ApiModelProperty(value = "明细值")
|
||||
@Excel(name = "明细值", width = 15)
|
||||
private String detailValue;
|
||||
/**物料添加方式*/
|
||||
@ApiModelProperty(value = "物料添加方式")
|
||||
@Excel(name = "物料添加方式", width = 15)
|
||||
private String materialAddType;
|
||||
/**一级组织ID*/
|
||||
@ApiModelProperty(value = "一级组织ID")
|
||||
@Excel(name = "一级组织ID", width = 15)
|
||||
private Long topOrganizationId;
|
||||
/**组织名称*/
|
||||
@ApiModelProperty(value = "组织名称")
|
||||
@Excel(name = "组织名称", width = 15)
|
||||
private String organizationName;
|
||||
}
|
||||
+62
@@ -0,0 +1,62 @@
|
||||
package com.mhd.oms.domain.sysTableConfig.repository.todo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* @author: brb
|
||||
* @description:
|
||||
* @create: 2026-03-04 14:30
|
||||
*/
|
||||
@Data
|
||||
@TableName("sys_table_config")
|
||||
public class SysTableConfigDTO extends BaseVOEntity {
|
||||
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
/*
|
||||
* 仓库id
|
||||
* */
|
||||
@ApiModelProperty("仓库ID")
|
||||
@Excel(name = "仓库ID")
|
||||
private Long warehouseId;
|
||||
/**组织ID*/
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
@Excel(name = "组织ID", width = 15)
|
||||
private Long organizationId;
|
||||
/**键*/
|
||||
@ApiModelProperty(value = "键")
|
||||
@Excel(name = "键", width = 15)
|
||||
private String key;
|
||||
/**值*/
|
||||
@ApiModelProperty(value = "值")
|
||||
@Excel(name = "值", width = 15)
|
||||
private String value;
|
||||
/**备注说明*/
|
||||
@ApiModelProperty(value = "备注说明")
|
||||
@Excel(name = "备注说明", width = 15)
|
||||
private String remark;
|
||||
/**明细值*/
|
||||
@ApiModelProperty(value = "明细值")
|
||||
@Excel(name = "明细值", width = 15)
|
||||
private String detailValue;
|
||||
/**物料添加方式*/
|
||||
@ApiModelProperty(value = "物料添加方式")
|
||||
@Excel(name = "物料添加方式", width = 15)
|
||||
private String materialAddType;
|
||||
/**一级组织ID*/
|
||||
@ApiModelProperty(value = "一级组织ID")
|
||||
@Excel(name = "一级组织ID", width = 15)
|
||||
private Long topOrganizationId;
|
||||
/**组织名称*/
|
||||
@ApiModelProperty(value = "组织名称")
|
||||
@Excel(name = "组织名称", width = 15)
|
||||
private String organizationName;
|
||||
}
|
||||
+62
@@ -0,0 +1,62 @@
|
||||
package com.mhd.oms.domain.sysTableConfig.repository.vo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* @author: brb
|
||||
* @description:
|
||||
* @create: 2026-03-04 14:30
|
||||
*/
|
||||
@Data
|
||||
@TableName("sys_table_config")
|
||||
public class SysTableConfigVO extends BaseVOEntity {
|
||||
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
/*
|
||||
* 仓库id
|
||||
* */
|
||||
@ApiModelProperty("仓库ID")
|
||||
@Excel(name = "仓库ID")
|
||||
private Long warehouseId;
|
||||
/**组织ID*/
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
@Excel(name = "组织ID", width = 15)
|
||||
private Long organizationId;
|
||||
/**键*/
|
||||
@ApiModelProperty(value = "键")
|
||||
@Excel(name = "键", width = 15)
|
||||
private String key;
|
||||
/**值*/
|
||||
@ApiModelProperty(value = "值")
|
||||
@Excel(name = "值", width = 15)
|
||||
private String value;
|
||||
/**备注说明*/
|
||||
@ApiModelProperty(value = "备注说明")
|
||||
@Excel(name = "备注说明", width = 15)
|
||||
private String remark;
|
||||
/**明细值*/
|
||||
@ApiModelProperty(value = "明细值")
|
||||
@Excel(name = "明细值", width = 15)
|
||||
private String detailValue;
|
||||
/**物料添加方式*/
|
||||
@ApiModelProperty(value = "物料添加方式")
|
||||
@Excel(name = "物料添加方式", width = 15)
|
||||
private String materialAddType;
|
||||
/**一级组织ID*/
|
||||
@ApiModelProperty(value = "一级组织ID")
|
||||
@Excel(name = "一级组织ID", width = 15)
|
||||
private Long topOrganizationId;
|
||||
/**组织名称*/
|
||||
@ApiModelProperty(value = "组织名称")
|
||||
@Excel(name = "组织名称", width = 15)
|
||||
private String organizationName;
|
||||
}
|
||||
+179
@@ -0,0 +1,179 @@
|
||||
package com.mhd.oms.interfaces.facade.ReservationStockOutOrder;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.mhd.common.core.web.controller.BaseController;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.core.web.page.TableDataInfo;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.todo.ReservationStockInOrderDO;
|
||||
import com.mhd.oms.domain.reservationStockInOrder.repository.todo.ReservationStockInOrderDTO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.entity.ReservationStockOutOrder;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.facade.IReservationStockOutOrderService;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.po.ReservationStockOutOrderPO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDTO;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.service.ReservationStockOutOrderApplicationService;
|
||||
import com.mhd.oms.domain.reservationStockOutOrder.service.ReservationStockOutOrderAssembler;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 出库单Api
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-28
|
||||
*/
|
||||
@Slf4j
|
||||
@RestController
|
||||
@RequestMapping("/stockOutOrderApi")
|
||||
public class ReservationStockOutOrderApi extends BaseController {
|
||||
@Autowired
|
||||
private ReservationStockOutOrderApplicationService stockOutOrderApplicationService;
|
||||
|
||||
@Resource
|
||||
private ReservationStockOutOrderAssembler stockOutOrderAssembler;
|
||||
|
||||
@Autowired
|
||||
private IReservationStockOutOrderService stockOutOrderService;
|
||||
|
||||
/**
|
||||
* 分页查询出库单列表
|
||||
*/
|
||||
@ApiOperation("查询出库单列表")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(ReservationStockOutOrderDTO stockOutOrderDTO)
|
||||
{
|
||||
//转换实体
|
||||
ReservationStockOutOrderDO stockOutOrderDO = stockOutOrderAssembler.toDO(stockOutOrderDTO);
|
||||
startPage();
|
||||
List<ReservationStockOutOrderPO> list = stockOutOrderApplicationService.queryList(stockOutOrderDO);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 编辑出库单
|
||||
*/
|
||||
@ApiOperation("编辑出库单")
|
||||
@PostMapping("/edit")
|
||||
public AjaxResult edit(@RequestBody ReservationStockOutOrderDTO stockOutOrderDTO)
|
||||
{
|
||||
//转换实体
|
||||
ReservationStockOutOrderDO stockOutOrderDO = stockOutOrderAssembler.toDOByEdit(stockOutOrderDTO);
|
||||
if(stockOutOrderDTO.getOutOrderId() != null){
|
||||
return toAjax(stockOutOrderApplicationService.update(stockOutOrderDO));
|
||||
}else {
|
||||
return toAjax(stockOutOrderApplicationService.insert(stockOutOrderDO));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除出库单
|
||||
*/
|
||||
@ApiOperation("批量删除出库单")
|
||||
@DeleteMapping("/deleteByIds/{outOrderIds}")
|
||||
public AjaxResult delete(@PathVariable Long[] outOrderIds)
|
||||
{
|
||||
return toAjax(stockOutOrderApplicationService.delete(outOrderIds));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取出库单详细信息
|
||||
*/
|
||||
@ApiOperation("获取出库单")
|
||||
@GetMapping(value = "/getInfo/{outOrderId}")
|
||||
public AjaxResult getInfo(@PathVariable("outOrderId") Long outOrderId)
|
||||
{
|
||||
return AjaxResult.success(stockOutOrderApplicationService.getInfoChildren(outOrderId));
|
||||
}
|
||||
/**
|
||||
* 根据出库单号获取出库单详细信息
|
||||
*/
|
||||
@ApiOperation("获取出库单")
|
||||
@GetMapping(value = "/getInfoOutOrderNumber")
|
||||
public AjaxResult getInfoOutOrderNumber(String outOrderNumber)
|
||||
{
|
||||
// 根据出库单号查询出库单,再按出库单ID查询详情,保证与出库管理页面一致
|
||||
ReservationStockOutOrder stockOutOrder = stockOutOrderService.getOne(new LambdaQueryWrapper<ReservationStockOutOrder>()
|
||||
.eq(ReservationStockOutOrder::getOutOrderNumber, outOrderNumber));
|
||||
if (stockOutOrder == null) {
|
||||
return AjaxResult.error("出库单不存在");
|
||||
}
|
||||
return AjaxResult.success(stockOutOrderApplicationService.getInfoChildren(stockOutOrder.getOutOrderId()));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据来源单号/出库单号(orderNumber)获取出库单详细信息
|
||||
* 方便交接作业单等场景直接用 orderNumber 调用,内部仍然通过 outOrderNumber 精确匹配出库单
|
||||
*/
|
||||
@ApiOperation("根据orderNumber获取出库单详情")
|
||||
@GetMapping("/getInfoByOrderNumber")
|
||||
public AjaxResult getInfoByOrderNumber(@RequestParam("orderNumber") String orderNumber) {
|
||||
if (orderNumber == null || orderNumber.trim().isEmpty()) {
|
||||
return AjaxResult.error("orderNumber不能为空");
|
||||
}
|
||||
ReservationStockOutOrder stockOutOrder = stockOutOrderService.getOne(new LambdaQueryWrapper<ReservationStockOutOrder>()
|
||||
.eq(ReservationStockOutOrder::getOutOrderNumber, orderNumber));
|
||||
if (stockOutOrder == null) {
|
||||
return AjaxResult.error("出库单不存在");
|
||||
}
|
||||
return AjaxResult.success(stockOutOrderApplicationService.getInfoChildren(stockOutOrder.getOutOrderId()));
|
||||
}
|
||||
|
||||
/**
|
||||
* 审核出库单
|
||||
*/
|
||||
// @ApiOperation("审核出库单")
|
||||
// @PostMapping(value = "/auditState")
|
||||
// public AjaxResult auditState(@RequestBody ReservationStockOutOrderDTO stockOutOrderDTO) {
|
||||
// ReservationStockOutOrderDO stockOutOrderDO = stockOutOrderAssembler.toDO(stockOutOrderDTO);
|
||||
// return AjaxResult.success(stockOutOrderApplicationService.auditState(stockOutOrderDO));
|
||||
// }
|
||||
|
||||
/**
|
||||
* 获取出库单复核详细信息
|
||||
*/
|
||||
// @ApiOperation("获取出库单复核详细信息")
|
||||
// @GetMapping(value = "/getCheckInfo")
|
||||
// public AjaxResult getCheckInfo(ReservationStockOutOrderDTO stockOutOrderDTO)
|
||||
// {
|
||||
// //转换实体
|
||||
// ReservationStockOutOrderDO stockOutOrderDO = stockOutOrderAssembler.toDO(stockOutOrderDTO);
|
||||
// return AjaxResult.success(stockOutOrderApplicationService.getCheckInfo(stockOutOrderDO));
|
||||
// }
|
||||
|
||||
|
||||
/**
|
||||
* 审核出库单
|
||||
*/
|
||||
@ApiOperation("审核出库单")
|
||||
@PostMapping(value = "/auditState")
|
||||
public AjaxResult auditState(@RequestBody ReservationStockOutOrderDTO stockOutOrderDTO) {
|
||||
ReservationStockOutOrderDO stockOutOrderDO = stockOutOrderAssembler.toDO(stockOutOrderDTO);
|
||||
return AjaxResult.success(stockOutOrderApplicationService.auditState(stockOutOrderDO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 下发出库单
|
||||
*/
|
||||
@ApiOperation("下发出库单")
|
||||
@PostMapping(value = "/issueOrder")
|
||||
public AjaxResult issueOrder(@RequestBody ReservationStockOutOrderDTO stockOutOrderDTO) {
|
||||
ReservationStockOutOrderDO stockOutOrderDO = stockOutOrderAssembler.toDO(stockOutOrderDTO);
|
||||
return AjaxResult.success(stockOutOrderApplicationService.issueOrder(stockOutOrderDO));
|
||||
}
|
||||
|
||||
@ApiOperation("关闭出库单")
|
||||
@PostMapping("/close")
|
||||
public AjaxResult close(@RequestBody ReservationStockOutOrderDTO stockOutOrderDTO)
|
||||
{
|
||||
//转换实体
|
||||
ReservationStockOutOrderDO stockOutOrderDO = stockOutOrderAssembler.toDOByEdit(stockOutOrderDTO);
|
||||
return toAjax(stockOutOrderApplicationService.close(stockOutOrderDO));
|
||||
}
|
||||
|
||||
}
|
||||
+10
@@ -105,6 +105,16 @@ public class ReservationStockInOrderApi extends BaseController {
|
||||
return AjaxResult.success(stockInOrderApplicationService.auditState(stockInOrderDO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 下发入库单
|
||||
*/
|
||||
@ApiOperation("下发入库单")
|
||||
@PostMapping(value = "/issueOrder")
|
||||
public AjaxResult issueOrder(@RequestBody ReservationStockInOrderDTO stockInOrderDTO) {
|
||||
ReservationStockInOrderDO stockInOrderDO = stockInOrderAssembler.toDO(stockInOrderDTO);
|
||||
return AjaxResult.success(stockInOrderApplicationService.issueOrder(stockInOrderDO));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 取消入库单
|
||||
|
||||
+198
@@ -0,0 +1,198 @@
|
||||
package com.mhd.oms.interfaces.facade.sysTableConfig;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.mhd.common.core.utils.sms.Result;
|
||||
import com.mhd.common.core.web.controller.BaseController;
|
||||
import com.mhd.oms.domain.sysTableConfig.entity.SysTableConfig;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.facade.ISysTableConfigService;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.todo.SysTableConfigDTO;
|
||||
import com.mhd.oms.domain.sysTableConfig.repository.vo.SysTableConfigVO;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-21
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/sysTableConfigApi")
|
||||
@Slf4j
|
||||
public class SysTableConfigApi extends BaseController {
|
||||
@Autowired
|
||||
private ISysTableConfigService sysTableConfigService;
|
||||
|
||||
/**
|
||||
* 分页列表查询
|
||||
*
|
||||
* @param sysTableConfigDTO
|
||||
* @param pageNo
|
||||
* @param pageSize
|
||||
* @param req
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "系统表配置 - 分页列表查询", notes = "系统表配置 - 分页列表查询")
|
||||
@GetMapping(value = "/queryList")
|
||||
public Result<?> queryList(SysTableConfigDTO sysTableConfigDTO,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
HttpServletRequest req) {
|
||||
Result<IPage<SysTableConfigVO>> result = new Result<>();
|
||||
Page<SysTableConfigVO> pageList = new Page<>(pageNo, pageSize);
|
||||
pageList = sysTableConfigService.queryList(pageList, sysTableConfigDTO);
|
||||
result.setResult(pageList);
|
||||
result.setSuccess(true);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据组织 ID 和键查询配置
|
||||
*
|
||||
* @param organizationId 组织 ID
|
||||
* @param key 配置键
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "系统表配置 - 根据组织 ID 和键查询", notes = "系统表配置 - 根据组织 ID 和键查询")
|
||||
@GetMapping(value = "/getByOrgIdAndKey")
|
||||
public Result<?> getByOrgIdAndKey(@RequestParam(name="organizationId") Long organizationId,
|
||||
@RequestParam(name="warehouseId") Long warehouseId,
|
||||
@RequestParam(name="key") String key) {
|
||||
try {
|
||||
SysTableConfig config = sysTableConfigService.getByOrgIdAndKey(organizationId, key, warehouseId);
|
||||
if (config == null) {
|
||||
return Result.ok("未找到对应配置");
|
||||
}
|
||||
return Result.ok(config);
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
return Result.error("查询失败:" + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据组织 ID 查询所有配置
|
||||
*
|
||||
* @param organizationId 组织 ID
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "系统表配置 - 根据组织 ID 查询所有配置", notes = "系统表配置 - 根据组织 ID 查询所有配置")
|
||||
@GetMapping(value = "/listByOrgId")
|
||||
public Result<?> listByOrgId(@RequestParam(name="organizationId") Long organizationId,
|
||||
@RequestParam(name="warehouseId") Long warehouseId) {
|
||||
try {
|
||||
List<SysTableConfig> list = sysTableConfigService.listByOrgId(organizationId, warehouseId);
|
||||
return Result.ok(list);
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
return Result.error("查询失败:" + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加或更新配置
|
||||
*
|
||||
* @param sysTableConfigDTO
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "系统表配置 - 添加或更新", notes = "系统表配置 - 添加或更新")
|
||||
@PostMapping(value = "/saveOrUpdate")
|
||||
public Result<?> saveOrUpdate(@RequestBody SysTableConfigDTO sysTableConfigDTO) {
|
||||
Result<?> result = new Result<>();
|
||||
try {
|
||||
boolean success = sysTableConfigService.saveOrUpdateConfig(sysTableConfigDTO);
|
||||
if (success) {
|
||||
result.success("保存成功!");
|
||||
} else {
|
||||
result.error500("保存失败");
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
result.error500("操作失败:" + e.getMessage());
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过 id 删除
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "系统表配置 - 删除", notes = "系统表配置 - 删除")
|
||||
@DeleteMapping(value = "/delete")
|
||||
public Result<?> delete(@RequestParam(name="id",required=true) String id) {
|
||||
Result<?> result = new Result<>();
|
||||
try {
|
||||
sysTableConfigService.delete(Arrays.asList(id));
|
||||
result.success("删除成功!");
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
result.error500("操作失败:" + e.getMessage());
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "系统表配置 - 批量删除", notes = "系统表配置 - 批量删除")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
public Result<?> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||
Result<?> result = new Result<>();
|
||||
try {
|
||||
int count = sysTableConfigService.delete(Arrays.asList(ids.split(",")));
|
||||
result.success("删除成功,共删除" + count + "条记录");
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
result.error500("操作失败:" + e.getMessage());
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据组织 ID 删除所有配置
|
||||
*
|
||||
* @param organizationId 组织 ID
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "系统表配置 - 根据组织 ID 删除所有配置", notes = "系统表配置 - 根据组织 ID 删除所有配置")
|
||||
@DeleteMapping(value = "/deleteByOrgId")
|
||||
public Result<?> deleteByOrgId(@RequestParam(name="organizationId",required=true) Long organizationId) {
|
||||
Result<?> result = new Result<>();
|
||||
try {
|
||||
int count = sysTableConfigService.deleteByOrgId(organizationId);
|
||||
result.success("删除成功,共删除" + count + "条记录");
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
result.error500("操作失败:" + e.getMessage());
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 通过 id 查询
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "系统表配置 - 通过 id 查询", notes = "系统表配置 - 通过 id 查询")
|
||||
@GetMapping(value = "/queryById")
|
||||
public Result<?> queryById(@RequestParam(name="id",required=true) String id) {
|
||||
SysTableConfig config = sysTableConfigService.getById(id);
|
||||
if (config == null) {
|
||||
return Result.error("未找到对应数据");
|
||||
}
|
||||
return Result.ok(config);
|
||||
}
|
||||
|
||||
}
|
||||
+1
-1
@@ -328,7 +328,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<select id="queryInOrderList" parameterType="com.mhd.oms.domain.reservationInMaterialDetail.repository.todo.QueryOrderOverStockDO" resultMap="MaterialDetailResult">
|
||||
select
|
||||
<include refid="selectMaterialDetailPo"/>
|
||||
<include refid="com.mhd.wms.domain.stockInOrder.repository.mapper.StockInOrderMapper.joinStockInOrderPo"/>
|
||||
<include refid="com.mhd.oms.domain.reservationStockInOrder.repository.mapper.ReservationStockInOrderMapper.joinStockInOrderPo"/>
|
||||
from reservation_in_material_detail a
|
||||
LEFT JOIN reservation_stock_in_order b ON a.in_order_number = b.in_order_number
|
||||
<where>
|
||||
|
||||
+408
@@ -0,0 +1,408 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mhd.oms.domain.reservationOutMaterialDetail.repository.mapper.ReservationOutMaterialDetailMapper">
|
||||
|
||||
<resultMap type="com.mhd.oms.domain.reservationOutMaterialDetail.repository.po.ReservationOutMaterialDetailPO" id="MaterialDetailResult">
|
||||
<result property="materialDetailId" column="material_detail_id" />
|
||||
<result property="organizationId" column="organization_id" />
|
||||
<result property="organizationName" column="organization_name" />
|
||||
<result property="topOrganizationId" column="top_organization_id" />
|
||||
<result property="uniqueId" column="unique_id" />
|
||||
<result property="outOrderNumber" column="out_order_number" />
|
||||
<result property="materialBaseInfoId" column="material_base_info_id" />
|
||||
<result property="materialCode" column="material_code" />
|
||||
<result property="materialName" column="material_name" />
|
||||
<result property="barCode" column="bar_code" />
|
||||
<result property="weightLimit" column="weight_limit" />
|
||||
<result property="volumeLimit" column="volume_limit" />
|
||||
<result property="quantity" column="quantity" />
|
||||
<result property="allocationQuantity" column="allocation_quantity" />
|
||||
<result property="pickingQuantity" column="picking_quantity" />
|
||||
<result property="checkQuantity" column="check_quantity" />
|
||||
<result property="waitCheckQuantity" column="WAIT_CHECK_QUANTITY" />
|
||||
<result property="packId" column="pack_id" />
|
||||
<result property="packCode" column="pack_code" />
|
||||
<result property="packName" column="pack_name" />
|
||||
<result property="packDetailId" column="pack_detail_id" />
|
||||
<result property="unitCode" column="unit_code" />
|
||||
<result property="unitName" column="unit_name" />
|
||||
<result property="materialWarehouseControlId" column="material_warehouse_control_id" />
|
||||
<result property="serialNumberManage" column="serial_number_manage" />
|
||||
<result property="materialInventoryId" column="material_inventory_id" />
|
||||
<result property="warehouseId" column="warehouse_id" />
|
||||
<result property="warehouseCode" column="warehouse_code" />
|
||||
<result property="warehouseName" column="warehouse_name" />
|
||||
<result property="storageSectionId" column="storage_section_id" />
|
||||
<result property="storageCode" column="storage_code" />
|
||||
<result property="storageName" column="storage_name" />
|
||||
<result property="storageLocationId" column="storage_location_id" />
|
||||
<result property="storageLocationCode" column="storage_location_code" />
|
||||
<result property="storageLocationName" column="storage_location_name" />
|
||||
<result property="level" column="level" />
|
||||
<result property="parentUniqueId" column="parent_unique_id" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createByName" column="create_by_name" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateByName" column="update_by_name" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
<result property="overStockId" column="over_stock_id" />
|
||||
<result property="overStockStatus" column="over_stock_status" />
|
||||
<result property="overStockType" column="over_stock_type" />
|
||||
<result property="commodityName" column="COMMODITY_NAME" />
|
||||
<result property="commodityNo" column="COMMODITY_NO" />
|
||||
<result property="materialNo" column="MATERIAL_NO" />
|
||||
<result property="specificationModel" column="SPECIFICATION_MODEL" />
|
||||
<result property="skucode" column="SKUCODE" />
|
||||
<result property="invoiceNo" column="INVOICE_NO" />
|
||||
<result property="liter" column="LITER" />
|
||||
<result property="size" column="SIZE" />
|
||||
<result property="declareUnit" column="DECLARE_UNIT" />
|
||||
<result property="batchRefNo" column="BATCH_REF_NO" />
|
||||
<result property="sheetRefNo" column="SHEET_REF_NO" />
|
||||
<result property="countryOfOrigin" column="COUNTRY_OF_ORIGIN" />
|
||||
<result property="boxPalletNo" column="BOX_PALLET_NO" />
|
||||
<result property="currency" column="CURRENCY" />
|
||||
<result property="declareQuantity" column="DECLARE_QUANTITY" />
|
||||
<result property="caseCount" column="CASE_COUNT" />
|
||||
<result property="pieceCount" column="PIECE_COUNT" />
|
||||
<result property="outboundQuantity" column="OUTBOUND_QUANTITY" />
|
||||
<result property="totalNetWeight" column="TOTAL_NET_WEIGHT" />
|
||||
<result property="totalGrossWeight" column="TOTAL_GROSS_WEIGHT" />
|
||||
<result property="totalVolume" column="TOTAL_VOLUME" />
|
||||
<result property="totalArea" column="TOTAL_AREA" />
|
||||
<result property="totalAmount" column="TOTAL_AMOUNT" />
|
||||
<result property="unit" column="UNIT" />
|
||||
<result property="extAttr1" column="EXT_ATTR_1" />
|
||||
<result property="extAttr2" column="EXT_ATTR_2" />
|
||||
<result property="productionDate" column="PRODUCTION_DATE" />
|
||||
<result property="expiryDate" column="EXPIRY_DATE" />
|
||||
<result property="inventoryDate" column="INVENTORY_DATE" />
|
||||
<result property="extAttr3" column="EXT_ATTR_3" />
|
||||
<result property="extAttr4" column="EXT_ATTR_4" />
|
||||
<result property="contractFee" column="contract_fee" />
|
||||
<result property="monthlyWarehouseFee" column="monthly_warehouse_fee" />
|
||||
<result property="halfMonthWhFee" column="half_month_wh_fee" />
|
||||
<result property="discountRate" column="discount_rate" />
|
||||
<result property="singleVolume" column="single_volume" />
|
||||
<result property="singleGrossWeight" column="single_gross_weight" />
|
||||
<result property="lotNo" column="lot_no" />
|
||||
<result property="inOrderNumber" column="in_order_number" />
|
||||
<result property="stockUnit" column="stock_unit" />
|
||||
<result property="stockQuantity" column="stock_quantity" />
|
||||
</resultMap>
|
||||
|
||||
|
||||
<sql id="selectMaterialDetailPo">
|
||||
a.contract_fee ,
|
||||
a.monthly_warehouse_fee ,
|
||||
a.half_month_wh_fee ,
|
||||
a.discount_rate ,
|
||||
a.single_volume ,
|
||||
a.single_gross_weight ,
|
||||
a.lot_no ,
|
||||
a.stock_quantity ,
|
||||
a.stock_unit ,a.in_order_number ,
|
||||
a.material_detail_id, a.organization_id, a.organization_name, a.top_organization_id, a.unique_id, a.out_order_number, a.material_base_info_id, a.line_number, a.material_code, a.material_name, a.bar_code, a.weight_limit, a.volume_limit,
|
||||
a.quantity, a.already_allocation_quantity, a.allocation_quantity, a.picking_quantity, a.check_quantity, ROUND(GREATEST(0, IFNULL(a.quantity, 0) - IFNULL(a.check_quantity, 0), IFNULL(a.picking_quantity, 0) - IFNULL(a.check_quantity, 0)), 2) AS wait_check_quantity,
|
||||
a.pack_id, a.pack_code, a.pack_name, a.pack_detail_id, a.unit_code, a.unit_name, a.material_warehouse_control_id, a.serial_number_manage,
|
||||
a.warehouse_id, a.warehouse_code, a.warehouse_name, a.storage_section_id, a.storage_code, a.storage_name, a.storage_location_id, a.storage_location_code, a.storage_location_name, a.level, a.parent_unique_id, a.allow_modify,
|
||||
a.material_inventory_id, a.batch_number, a.container_id, a.container_code, a.container_type, a.container_type_name, a.material_status_code, a.material_status_name,
|
||||
a.remark, a.create_time, a.create_by,gen_picking_order,
|
||||
a.create_by_name, a.update_time, a.update_by, a.update_by_name, a.del_flag, a.over_stock_id, a.over_stock_status, a.over_stock_type,
|
||||
a.COMMODITY_NAME,
|
||||
a.COMMODITY_NO,
|
||||
a.MATERIAL_NO ,
|
||||
a.SPECIFICATION_MODEL,
|
||||
a.SKUCODE ,
|
||||
a.INVOICE_NO,
|
||||
a.LITER,
|
||||
a.SIZE,
|
||||
a.DECLARE_UNIT,
|
||||
a.BATCH_REF_NO,
|
||||
a.SHEET_REF_NO,
|
||||
a.COUNTRY_OF_ORIGIN,
|
||||
a.BOX_PALLET_NO,
|
||||
a.CURRENCY,
|
||||
a.DECLARE_QUANTITY,
|
||||
a.CASE_COUNT,
|
||||
a.PIECE_COUNT,
|
||||
a.OUTBOUND_QUANTITY,
|
||||
a.TOTAL_NET_WEIGHT,
|
||||
a.TOTAL_GROSS_WEIGHT,
|
||||
a.TOTAL_VOLUME,
|
||||
a.TOTAL_AREA,
|
||||
a.TOTAL_AMOUNT,
|
||||
a.UNIT,
|
||||
a.EXT_ATTR_1,
|
||||
a.EXT_ATTR_2,
|
||||
a.PRODUCTION_DATE,
|
||||
a.EXPIRY_DATE,
|
||||
a.INVENTORY_DATE,
|
||||
a.EXT_ATTR_3,
|
||||
a.EXT_ATTR_4,
|
||||
a.INVENTORY_QUANTITY
|
||||
</sql>
|
||||
|
||||
<sql id="selectMaterialDetailPo1">
|
||||
<if test="organizationId != null ">
|
||||
and a.organization_id = #{organizationId}
|
||||
</if>
|
||||
<if test="organizationName != null and organizationName != ''">
|
||||
and a.organization_name like concat('%', #{organizationName}, '%')
|
||||
</if>
|
||||
<if test="topOrganizationId != null ">
|
||||
and a.top_organization_id = #{topOrganizationId}
|
||||
</if>
|
||||
<if test="outOrderNumber != null and outOrderNumber != '' ">
|
||||
and a.out_order_number = #{outOrderNumber}
|
||||
</if>
|
||||
<if test="materialBaseInfoId != null ">
|
||||
and a.material_base_info_id = #{materialBaseInfoId}
|
||||
</if>
|
||||
<if test="materialCode != null and materialCode != ''">
|
||||
and a.material_code = #{materialCode}
|
||||
</if>
|
||||
<if test="materialName != null and materialName != ''">
|
||||
and a.material_name like concat('%', #{materialName}, '%')
|
||||
</if>
|
||||
<if test="barCode != null and barCode != ''">
|
||||
and a.bar_code = #{barCode}
|
||||
</if>
|
||||
<if test="quantity != null ">
|
||||
and a.quantity = #{quantity}
|
||||
</if>
|
||||
<if test="allocationQuantity != null ">
|
||||
and a.allocation_quantity = #{allocationQuantity}
|
||||
</if>
|
||||
<if test="pickingQuantity != null ">
|
||||
and a.picking_quantity = #{pickingQuantity}
|
||||
</if>
|
||||
<if test="checkQuantity != null ">
|
||||
and a.check_quantity = #{checkQuantity}
|
||||
</if>
|
||||
<if test="packId != null ">
|
||||
and a.pack_id = #{packId}
|
||||
</if>
|
||||
<if test="packCode != null and packCode != ''">
|
||||
and a.pack_code = #{packCode}
|
||||
</if>
|
||||
<if test="packName != null and packName != ''">
|
||||
and a.pack_name like concat('%', #{packName}, '%')
|
||||
</if>
|
||||
<if test="packDetailId != null and packDetailId != ''">
|
||||
and a.pack_detail_id = #{packDetailId}
|
||||
</if>
|
||||
<if test="unitCode != null and unitCode != ''">
|
||||
and a.unit_code = #{unitCode}
|
||||
</if>
|
||||
<if test="unitName != null and unitName != ''">
|
||||
and a.unit_name like concat('%', #{unitName}, '%')
|
||||
</if>
|
||||
<if test="materialWarehouseControlId != null ">
|
||||
and a.material_warehouse_control_id = #{materialWarehouseControlId}
|
||||
</if>
|
||||
<if test="serialNumberManage != null ">
|
||||
and a.serial_number_manage = #{serialNumberManage}
|
||||
</if>
|
||||
<if test="warehouseId != null ">
|
||||
and a.warehouse_id = #{warehouseId}
|
||||
</if>
|
||||
<if test="warehouseCode != null and warehouseCode != ''">
|
||||
and a.warehouse_code = #{warehouseCode}
|
||||
</if>
|
||||
<if test="warehouseName != null and warehouseName != ''">
|
||||
and a.warehouse_name like concat('%', #{warehouseName}, '%')
|
||||
</if>
|
||||
<if test="storageSectionId != null ">
|
||||
and a.storage_section_id = #{storageSectionId}
|
||||
</if>
|
||||
<if test="storageCode != null and storageCode != ''">
|
||||
and a.storage_code = #{storageCode}
|
||||
</if>
|
||||
<if test="storageName != null and storageName != ''">
|
||||
and a.storage_name like concat('%', #{storageName}, '%')
|
||||
</if>
|
||||
<if test="storageLocationId != null ">
|
||||
and a.storage_location_id = #{storageLocationId}
|
||||
</if>
|
||||
<if test="storageLocationCode != null and storageLocationCode != ''">
|
||||
and a.storage_location_code = #{storageLocationCode}
|
||||
</if>
|
||||
<if test="storageLocationName != null and storageLocationName != ''">
|
||||
and a.storage_location_name like concat('%', #{storageLocationName}, '%')
|
||||
</if>
|
||||
<if test="level != null ">
|
||||
and a.level = #{level}
|
||||
</if>
|
||||
<if test="genPickingOrder != null ">
|
||||
and a.gen_picking_order = #{genPickingOrder}
|
||||
</if>
|
||||
<if test="parentUniqueId != null ">
|
||||
and a.parent_unique_id = #{parentUniqueId}
|
||||
</if>
|
||||
<if test="createByName != null and createByName != ''">
|
||||
and a.create_by_name like concat('%', #{createByName}, '%')
|
||||
</if>
|
||||
<if test="updateByName != null and updateByName != ''">
|
||||
and a.update_by_name like concat('%', #{updateByName}, '%')
|
||||
</if>
|
||||
<if test="outOrderNumberList != null and outOrderNumberList.size > 0 ">
|
||||
and a.out_order_number in
|
||||
<foreach collection="outOrderNumberList" item="item" index="index" open="(" close=")" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<choose>
|
||||
<when test="delFlag != null"> and a.del_flag = #{delFlag} </when>
|
||||
<otherwise> and a.del_flag = 1 </otherwise>
|
||||
</choose>
|
||||
</sql>
|
||||
|
||||
<sql id="joinMaterialDetailPoWhere">
|
||||
<if test="organizationId != null ">
|
||||
and a.organization_id = #{organizationId}
|
||||
</if>
|
||||
<if test="organizationName != null and organizationName != ''">
|
||||
and a.organization_name like concat('%', #{organizationName}, '%')
|
||||
</if>
|
||||
<if test="topOrganizationId != null ">
|
||||
and a.top_organization_id = #{topOrganizationId}
|
||||
</if>
|
||||
<if test="overStockStatus != null ">
|
||||
and a.over_stock_status = #{overStockStatus}
|
||||
</if>
|
||||
<if test="materialBaseInfoId != null ">
|
||||
and a.material_base_info_id = #{materialBaseInfoId}
|
||||
</if>
|
||||
<if test="materialBaseInfoIdList != null and materialBaseInfoIdList != ''">
|
||||
and a.material_base_info_id in
|
||||
<foreach collection="materialBaseInfoIdList" item="item" index="index" open="(" close=")" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<choose>
|
||||
<when test="delFlag != null"> and a.del_flag = #{delFlag} </when>
|
||||
<otherwise> and a.del_flag = 1 </otherwise>
|
||||
</choose>
|
||||
</sql>
|
||||
|
||||
<sql id="joinStockOutOrderPoWhere">
|
||||
<if test="outOrderNumber != null and outOrderNumber != ''">
|
||||
and b.out_order_number = #{outOrderNumber}
|
||||
</if>
|
||||
<if test="warehouseId != null and warehouseId != '' ">
|
||||
and b.warehouse_id = #{warehouseId}
|
||||
</if>
|
||||
<if test="shipperId != null and shipperId != ''">
|
||||
and b.shipper_id = #{shipperId}
|
||||
</if>
|
||||
<if test="shipperIdList != null and shipperIdList != ''">
|
||||
and b.shipper_id in
|
||||
<foreach collection="shipperIdList" item="item" index="index" open="(" close=")" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="outOrderExpectStartTime != null and outOrderExpectStartTime != ''"><!-- 开始时间检索 -->
|
||||
and date_format(b.expect_time,'%y%m%d') >= date_format(#{outOrderExpectStartTime},'%y%m%d')
|
||||
</if>
|
||||
<if test="outOrderExpectEndTime != null and outOrderExpectEndTime != ''"><!-- 结束时间检索 -->
|
||||
and date_format(b.expect_time,'%y%m%d') <= date_format(#{outOrderExpectEndTime},'%y%m%d')
|
||||
</if>
|
||||
<if test="outOrderTypeCode != null and outOrderTypeCode != ''">
|
||||
and b.order_type_code = #{outOrderTypeCode}
|
||||
</if>
|
||||
<!-- 出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-拣货中 6-波次中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭 -->
|
||||
<if test="outStatus != null ">
|
||||
and b.status = #{outStatus}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="delFlag != null"> and b.del_flag = #{delFlag} </when>
|
||||
<otherwise> and b.del_flag = 1 </otherwise>
|
||||
</choose>
|
||||
</sql>
|
||||
|
||||
<select id="queryList" parameterType="com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO" resultMap="MaterialDetailResult">
|
||||
select
|
||||
<include refid="selectMaterialDetailPo"/>
|
||||
from reservation_out_material_detail a
|
||||
<where>
|
||||
<include refid="selectMaterialDetailPo1"/>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="queryOutOrderList" parameterType="com.mhd.oms.domain.reservationInMaterialDetail.repository.todo.QueryOrderOverStockDO" resultMap="MaterialDetailResult">
|
||||
select
|
||||
<include refid="selectMaterialDetailPo"/>
|
||||
<include refid="com.mhd.oms.domain.reservationStockOutOrder.repository.mapper.ReservationStockOutOrderMapper.joinStockOutOrderPo"/>
|
||||
from reservation_out_material_detail a
|
||||
left join reservation_stock_out_order b on a.out_order_number = b.out_order_number
|
||||
<where>
|
||||
<include refid="joinMaterialDetailPoWhere"/>
|
||||
<include refid="joinStockOutOrderPoWhere"/>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<update id="batchAddAllocationQuantityByIds" parameterType="com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO">
|
||||
UPDATE reservation_out_material_detail
|
||||
<set>
|
||||
allocation_quantity = CASE material_detail_id
|
||||
<foreach collection="children" item="item" index="index" separator=",">
|
||||
WHEN #{item.materialDetailId} THEN allocation_quantity + #{item.allocationQuantity}
|
||||
</foreach>
|
||||
END,
|
||||
update_by = #{item.updateBy},
|
||||
update_by_name = #{item.updateByName},
|
||||
update_time = now()
|
||||
</set>
|
||||
WHERE material_detail_id IN
|
||||
<foreach collection="children" item="item" index="index" open="(" separator="," close=")">
|
||||
#{item.materialDetailId}
|
||||
</foreach>
|
||||
</update>
|
||||
|
||||
<update id="batchAddPickingQuantityByIds" parameterType="com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO">
|
||||
UPDATE reservation_out_material_detail
|
||||
<set>
|
||||
picking_quantity = CASE material_detail_id
|
||||
<foreach collection="children" item="item" index="index" separator=",">
|
||||
WHEN #{item.materialDetailId} THEN picking_quantity + #{item.pickingQuantity}
|
||||
</foreach>
|
||||
END,
|
||||
update_by = #{updateBy},
|
||||
update_by_name = #{updateByName},
|
||||
update_time = now()
|
||||
</set>
|
||||
WHERE material_detail_id IN
|
||||
<foreach collection="children" item="item" index="index" open="(" separator="," close=")">
|
||||
#{item.materialDetailId}
|
||||
</foreach>
|
||||
</update>
|
||||
|
||||
<update id="batchAddPickingQuantityByUniqueIds" parameterType="com.mhd.oms.domain.reservationOutMaterialDetail.repository.todo.ReservationOutMaterialDetailDO">
|
||||
UPDATE reservation_out_material_detail
|
||||
<set>
|
||||
picking_quantity = CASE unique_id
|
||||
<foreach collection="children" item="item" index="index" separator=",">
|
||||
WHEN #{item.uniqueId} THEN picking_quantity + #{item.pickingQuantity}
|
||||
</foreach>
|
||||
END,
|
||||
<trim prefix="picking_quantity = CASE unique_id" suffix="END,">
|
||||
<foreach collection="children" item="item" index="index">
|
||||
WHEN #{item.uniqueId} THEN picking_quantity + #{item.pickingQuantity}
|
||||
</foreach>
|
||||
</trim>
|
||||
update_by = #{updateBy},
|
||||
update_by_name = #{updateByName},
|
||||
update_time = now()
|
||||
</set>
|
||||
WHERE unique_id IN
|
||||
<foreach collection="children" item="item" index="index" open="(" separator="," close=")">
|
||||
#{item.uniqueId}
|
||||
</foreach>
|
||||
</update>
|
||||
</mapper>
|
||||
+3
@@ -433,6 +433,9 @@
|
||||
<select id="getinfo" parameterType="java.lang.Long" resultType="com.mhd.oms.domain.reservationStockInOrder.repository.po.MaterialBaseInfoPO">
|
||||
select * from "NGWL_TEST_WMS".MATERIAL_BASE_INFO where MATERIAL_BASE_INFO_ID = #{id}
|
||||
</select>
|
||||
<select id="getMaterialBaseInfoList" parameterType="java.lang.String" resultType="com.mhd.oms.domain.reservationStockInOrder.repository.po.MaterialBaseInfoPO">
|
||||
select * from "NGWL_TEST_WMS".MATERIAL_BASE_INFO where material_code = #{id}
|
||||
</select>
|
||||
|
||||
<select id="getInfoByMaterialBaseInfoIds" parameterType="java.lang.Long" resultType="com.mhd.oms.domain.reservationStockInOrder.repository.po.MaterialWarehouseControlPO">
|
||||
select * from "NGWL_TEST_WMS".MATERIAL_WAREHOUSE_CONTROL where MATERIAL_BASE_INFO_ID = #{id}
|
||||
|
||||
+326
@@ -0,0 +1,326 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mhd.oms.domain.reservationStockOutOrder.repository.mapper.ReservationStockOutOrderMapper">
|
||||
|
||||
<resultMap type="com.mhd.oms.domain.reservationStockOutOrder.repository.po.ReservationStockOutOrderPO" id="StockOutOrderResult">
|
||||
<result property="outOrderId" column="out_order_id" />
|
||||
<result property="organizationId" column="organization_id" />
|
||||
<result property="organizationName" column="organization_name" />
|
||||
<result property="topOrganizationId" column="top_organization_id" />
|
||||
<result property="noticeNumber" column="notice_number" />
|
||||
<result property="outOrderNumber" column="out_order_number" />
|
||||
<result property="status" column="status" />
|
||||
<result property="auditStatus" column="audit_status" />
|
||||
<result property="auditRemark" column="audit_remark" />
|
||||
<result property="auditBy" column="audit_by" />
|
||||
<result property="auditByName" column="audit_by_name" />
|
||||
<result property="auditTime" column="audit_time" />
|
||||
<result property="warehouseId" column="warehouse_id" />
|
||||
<result property="warehouseCode" column="warehouse_code" />
|
||||
<result property="warehouseName" column="warehouse_name" />
|
||||
<result property="shipperId" column="shipper_id" />
|
||||
<result property="shipperName" column="shipper_name" />
|
||||
<result property="orderTypeCode" column="order_type_code" />
|
||||
<result property="orderTypeName" column="order_type_name" />
|
||||
<result property="customerId" column="customer_id" />
|
||||
<result property="customerName" column="customer_name" />
|
||||
<result property="expectTime" column="expect_time" />
|
||||
<result property="supplyChainNumber" column="supply_chain_number" />
|
||||
<result property="priorityLevelCode" column="priority_level_code" />
|
||||
<result property="priorityLevelName" column="priority_level_name" />
|
||||
<result property="directWarehouse" column="direct_warehouse" />
|
||||
<result property="review" column="review" />
|
||||
<result property="annexUrl" column="annex_url" />
|
||||
<result property="quantity" column="quantity" />
|
||||
<result property="cancelOrder" column="cancel_order" />
|
||||
<result property="cancelRemark" column="cancel_remark" />
|
||||
<result property="cancelBy" column="cancel_by" />
|
||||
<result property="cancelByName" column="cancel_by_name" />
|
||||
<result property="cancelTime" column="cancel_time" />
|
||||
<result property="closeOrder" column="close_order" />
|
||||
<result property="closeRemark" column="close_remark" />
|
||||
<result property="closeBy" column="close_by" />
|
||||
<result property="closeByName" column="close_by_name" />
|
||||
<result property="closeTime" column="close_time" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createByName" column="create_by_name" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateByName" column="update_by_name" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
<result property="overStockId" column="over_stock_id" />
|
||||
<result property="overStockStatus" column="over_stock_status" />
|
||||
<result property="overStockType" column="over_stock_type" />
|
||||
<result property="to" column="to"/>
|
||||
<result property="contactPerson" column="contact_person"/>
|
||||
<result property="vehicleModelPlate" column="vehicle_model_plate"/>
|
||||
<result property="entrustNo" column="entrust_no"/>
|
||||
<result property="tel" column="tel"/>
|
||||
<result property="driverSign" column="driver_sign"/>
|
||||
<result property="fax" column="fax"/>
|
||||
<result property="declareCustoms" column="declare_customs"/>
|
||||
<result property="manufacturer" column="manufacturer"/>
|
||||
<result property="customsDeclarerInfo" column="customs_declarer_info"/>
|
||||
<result property="deliveryAddr" column="delivery_addr"/>
|
||||
<result property="entryExitCustoms" column="entry_exit_customs"/>
|
||||
<result property="departureArrivalCountry" column="departure_arrival_country"/>
|
||||
<result property="carrier" column="carrier"/>
|
||||
<result property="containerNo" column="container_no"/>
|
||||
<result property="containerNoName" column="container_no_name"/>
|
||||
<result property="outboundDate" column="outbound_date"/>
|
||||
<result property="completeTime" column="complete_time"/>
|
||||
<result property="orderDate" column="order_date"/>
|
||||
<result property="transportModeCode" column="transport_mode_code"/>
|
||||
<result property="transportModeName" column="transport_mode_name"/>
|
||||
<result property="supervisionModeCode" column="supervision_mode_code"/>
|
||||
<result property="supervisionModeName" column="supervision_mode_name"/>
|
||||
<result property="customsInspectionFlag" column="customs_inspection_flag"/>
|
||||
<result property="needDeclareFlag" column="need_declare_flag"/>
|
||||
<result property="needTransportFlag" column="need_transport_flag"/>
|
||||
<result property="pictureApp" column="picture_app"/>
|
||||
</resultMap>
|
||||
|
||||
|
||||
<sql id="selectStockOutOrderPo">
|
||||
a.out_order_id, a.organization_id, a.organization_name, a.top_organization_id, a.receipt_notice_id, a.notice_number, a.out_order_number, a.status,
|
||||
a.audit_status, a.audit_remark, a.audit_by, a.audit_by_name, a.audit_time, a.warehouse_id, a.warehouse_code, a.warehouse_name, a.shipper_id, a.shipper_code,
|
||||
a.shipper_name, a.order_type_code, a.order_type_name, a.customer_id, a.customer_code, a.customer_name, a.expect_time, a.supply_chain_number, a.priority_level_code,
|
||||
a.priority_level_name, a.direct_warehouse, a.review, a.annex_url, a.material_quantity, a.quantity, a.weight_limit, a.volume_limit, a.check_quantity, a.cancel_order, a.cancel_remark, a.cancel_by, a.cancel_by_name,
|
||||
a.cancel_time, a.close_order, a.close_remark, a.close_by, a.close_by_name, a.close_time, a.check_status,
|
||||
a.check_task_distribution, a.check_task_distribution_time, a.check_operators_by, a.check_operators_name, a.mobilize_code,
|
||||
a.remark, a.create_time, a.create_by, a.create_by_name,
|
||||
a.update_time, a.update_by, a.update_by_name, a.del_flag, over_stock_id, over_stock_status, over_stock_type,a."TO",
|
||||
a.CONTACT_PERSON,a.VEHICLE_MODEL_PLATE,a.ENTRUST_NO,a.TEL,a.DRIVER_SIGN,a.FAX,a.DECLARE_CUSTOMS,a.MANUFACTURER,
|
||||
a.CUSTOMS_DECLARER_INFO,a.DELIVERY_ADDR,a.ENTRY_EXIT_CUSTOMS,a.DEPARTURE_ARRIVAL_COUNTRY,a.CARRIER,a.CONTAINER_NO,a.CONTAINER_NO_NAME,a.OUTBOUND_DATE,
|
||||
a.COMPLETE_TIME,a.ORDER_DATE,a.TRANSPORT_MODE_CODE,a.TRANSPORT_MODE_NAME,a.SUPERVISION_MODE_CODE,a.SUPERVISION_MODE_NAME,
|
||||
a.CUSTOMS_INSPECTION_FLAG,a.NEED_DECLARE_FLAG,a.NEED_TRANSPORT_FLAG,a.picture_app
|
||||
</sql>
|
||||
|
||||
|
||||
<sql id="joinStockOutOrderPo">
|
||||
,b.notice_number, b.out_order_number, b.warehouse_id, b.warehouse_code, b.warehouse_name, b.shipper_id, b.shipper_code,
|
||||
b.shipper_name, b.order_type_code, b.order_type_name, b.customer_id, b.customer_name, b.expect_time, b.supply_chain_number, b.priority_level_code,
|
||||
b.priority_level_name, b.direct_warehouse, b.review, b.annex_url, b.quantity
|
||||
</sql>
|
||||
|
||||
<sql id="joinStockOutOrderPoYc">
|
||||
,b.notice_number, b.out_order_number, b.warehouse_id, b.warehouse_code, b.warehouse_name, b.shipper_id, b.shipper_code,
|
||||
b.shipper_name, b.order_type_code, b.order_type_name, b.customer_id, b.customer_name, b.expect_time, b.supply_chain_number, b.priority_level_code,
|
||||
b.priority_level_name, b.direct_warehouse, b.review, b.annex_url
|
||||
</sql>
|
||||
|
||||
<sql id="selectStockOutOrderPo1">
|
||||
<if test="outOrderId != null ">
|
||||
and a.out_order_id = #{outOrderId}
|
||||
</if>
|
||||
<if test="organizationId != null ">
|
||||
and a.organization_id = #{organizationId}
|
||||
</if>
|
||||
<if test="organizationName != null and organizationName != ''">
|
||||
and a.organization_name like concat('%', #{organizationName}, '%')
|
||||
</if>
|
||||
<if test="topOrganizationId != null ">
|
||||
and a.top_organization_id = #{topOrganizationId}
|
||||
</if>
|
||||
<if test="noticeNumber != null and noticeNumber != ''">
|
||||
and a.notice_number = #{noticeNumber}
|
||||
</if>
|
||||
<if test="outOrderNumber != null and outOrderNumber != ''">
|
||||
and a.out_order_number like concat('%', #{outOrderNumber}, '%')
|
||||
</if>
|
||||
<!-- 出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-拣货中 6-波次中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭 -->
|
||||
<if test="status != null ">
|
||||
<choose>
|
||||
<when test="status == -1 "> <!-- 作业中 -->
|
||||
<!-- 出库状态: 3-部分分配 4-已分配 5-拣货中 6-波次中 7-拣货完成 8-复核中-->
|
||||
and a.status IN (3, 4, 5, 6, 7, 8)
|
||||
</when>
|
||||
<otherwise>
|
||||
and a.status = #{status}
|
||||
</otherwise>
|
||||
</choose>
|
||||
</if>
|
||||
<!-- 出库状态: 1-已创建 2-已审核 3-部分分配 4-已分配 5-拣货中 6-波次中 7-拣货完成 8-复核中 9-已出库 10-已取消 11-已关闭 -->
|
||||
<if test="gtStatus != null ">
|
||||
and a.status > #{gtStatus}
|
||||
</if>
|
||||
<if test="ltStatus != null ">
|
||||
and a.status < #{ltStatus}
|
||||
</if>
|
||||
<if test="auditStatus != null ">
|
||||
and a.audit_status = #{auditStatus}
|
||||
</if>
|
||||
<if test="auditRemark != null and auditRemark != ''">
|
||||
and a.audit_remark = #{auditRemark}
|
||||
</if>
|
||||
<if test="checkTaskDistribution != null ">
|
||||
and a.check_task_distribution = #{checkTaskDistribution}
|
||||
</if>
|
||||
<if test="auditBy != null ">
|
||||
and a.audit_by = #{auditBy}
|
||||
</if>
|
||||
<if test="auditByName != null and auditByName != ''">
|
||||
and a.audit_by_name like concat('%', #{auditByName}, '%')
|
||||
</if>
|
||||
<if test="auditTime != null ">
|
||||
and a.audit_time = #{auditTime}
|
||||
</if>
|
||||
<if test="warehouseId != null ">
|
||||
and a.warehouse_id = #{warehouseId}
|
||||
</if>
|
||||
<if test="warehouseCode != null and warehouseCode != ''">
|
||||
and a.warehouse_code = #{warehouseCode}
|
||||
</if>
|
||||
<if test="warehouseName != null and warehouseName != ''">
|
||||
and a.warehouse_name like concat('%', #{warehouseName}, '%')
|
||||
</if>
|
||||
<if test="shipperId != null ">
|
||||
and a.shipper_id = #{shipperId}
|
||||
</if>
|
||||
<if test="shipperName != null and shipperName != ''">
|
||||
and a.shipper_name like concat('%', #{shipperName}, '%')
|
||||
</if>
|
||||
<if test="orderTypeCode != null and orderTypeCode != ''">
|
||||
and a.order_type_code = #{orderTypeCode}
|
||||
</if>
|
||||
<if test="orderTypeName != null and orderTypeName != ''">
|
||||
and a.order_type_name like concat('%', #{orderTypeName}, '%')
|
||||
</if>
|
||||
<if test="customerId != null ">
|
||||
and a.customer_id = #{customerId}
|
||||
</if>
|
||||
<if test="customerName != null and customerName != ''">
|
||||
and a.customer_name like concat('%', #{customerName}, '%')
|
||||
</if>
|
||||
<if test="expectTime != null ">
|
||||
and a.expect_time = #{expectTime}
|
||||
</if>
|
||||
<if test="supplyChainNumber != null and supplyChainNumber != ''">
|
||||
and a.supply_chain_number = #{supplyChainNumber}
|
||||
</if>
|
||||
<if test="priorityLevelCode != null and priorityLevelCode != ''">
|
||||
and a.priority_level_code = #{priorityLevelCode}
|
||||
</if>
|
||||
<if test="priorityLevelName != null and priorityLevelName != ''">
|
||||
and a.priority_level_name like concat('%', #{priorityLevelName}, '%')
|
||||
</if>
|
||||
<if test="directWarehouse != null ">
|
||||
and a.direct_warehouse = #{directWarehouse}
|
||||
</if>
|
||||
<if test="review != null ">
|
||||
and a.review = #{review}
|
||||
</if>
|
||||
<if test="annexUrl != null and annexUrl != ''">
|
||||
and a.annex_url = #{annexUrl}
|
||||
</if>
|
||||
<if test="quantity != null ">
|
||||
and a.quantity = #{quantity}
|
||||
</if>
|
||||
<if test="cancelOrder != null ">
|
||||
and a.cancel_order = #{cancelOrder}
|
||||
</if>
|
||||
<if test="cancelRemark != null and cancelRemark != ''">
|
||||
and a.cancel_remark = #{cancelRemark}
|
||||
</if>
|
||||
<if test="cancelBy != null ">
|
||||
and a.cancel_by = #{cancelBy}
|
||||
</if>
|
||||
<if test="cancelByName != null and cancelByName != ''">
|
||||
and a.cancel_by_name like concat('%', #{cancelByName}, '%')
|
||||
</if>
|
||||
<if test="cancelTime != null ">
|
||||
and a.cancel_time = #{cancelTime}
|
||||
</if>
|
||||
<if test="closeOrder != null ">
|
||||
and a.close_order = #{closeOrder}
|
||||
</if>
|
||||
<if test="closeRemark != null and closeRemark != ''">
|
||||
and a.close_remark = #{closeRemark}
|
||||
</if>
|
||||
<if test="closeBy != null ">
|
||||
and a.close_by = #{closeBy}
|
||||
</if>
|
||||
<if test="closeByName != null and closeByName != ''">
|
||||
and a.close_by_name like concat('%', #{closeByName}, '%')
|
||||
</if>
|
||||
<if test="closeTime != null ">
|
||||
and a.close_time = #{closeTime}
|
||||
</if>
|
||||
<if test="checkStatus != null ">
|
||||
and a.check_status = #{checkStatus}
|
||||
</if>
|
||||
<if test="gtCheckStatus != null ">
|
||||
and a.check_status > #{gtCheckStatus}
|
||||
</if>
|
||||
<if test="ltCheckStatus != null ">
|
||||
and a.check_status < #{ltCheckStatus}
|
||||
</if>
|
||||
<if test="createByName != null and createByName != ''">
|
||||
and a.create_by_name like concat('%', #{createByName}, '%')
|
||||
</if>
|
||||
<if test="updateByName != null and updateByName != ''">
|
||||
and a.update_by_name like concat('%', #{updateByName}, '%')
|
||||
</if>
|
||||
<if test="checkOperatorsBy != null and checkOperatorsBy != ''">
|
||||
and a.check_operators_by = #{checkOperatorsBy}
|
||||
</if>
|
||||
<if test="outOrderIds != null and outOrderIds.size > 0 ">
|
||||
and a.out_order_id in
|
||||
<foreach collection="outOrderIds" item="item" index="index" open="(" close=")" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="createTimeStart != null and createTimeStart != ''">
|
||||
and date_format(a.create_time,'%Y-%m-%d') >= #{createTimeStart}
|
||||
</if>
|
||||
<if test="createTimeEnd != null and createTimeEnd != ''">
|
||||
and date_format(a.create_time,'%Y-%m-%d') <= #{createTimeEnd}
|
||||
</if>
|
||||
<if test="auditTimeStart != null and auditTimeStart != ''">
|
||||
and date_format(a.audit_time,'%Y-%m-%d') >= #{auditTimeStart}
|
||||
</if>
|
||||
<if test="auditTimeEnd != null and auditTimeEnd != ''">
|
||||
and date_format(a.audit_time,'%Y-%m-%d') <= #{auditTimeEnd}
|
||||
</if>
|
||||
<!-- 出库明细:物料名称、物料编码(同一明细行同时满足;与出库明细口径一致)。关联 material_base_info 避免明细冗余名称与主档不一致时筛不到 -->
|
||||
<if test="(materialName != null and materialName != '') or (materialCode != null and materialCode != '')">
|
||||
and exists (
|
||||
select 1 from out_material_detail omd
|
||||
left join material_base_info mb on omd.material_base_info_id = mb.material_base_info_id and mb.del_flag = 1
|
||||
where omd.out_order_number = a.out_order_number
|
||||
and omd.del_flag = 1
|
||||
and (omd.level is null or omd.level = 1)
|
||||
<if test="materialName != null and materialName != ''">
|
||||
and (
|
||||
omd.material_name like concat('%', #{materialName}, '%')
|
||||
or mb.material_name like concat('%', #{materialName}, '%')
|
||||
)
|
||||
</if>
|
||||
<if test="materialCode != null and materialCode != ''">
|
||||
and (
|
||||
omd.material_code like concat('%', #{materialCode}, '%')
|
||||
or mb.material_code like concat('%', #{materialCode}, '%')
|
||||
)
|
||||
</if>
|
||||
)
|
||||
</if>
|
||||
<choose>
|
||||
<when test="delFlag != null"> and a.del_flag = #{delFlag} </when>
|
||||
<otherwise> and a.del_flag = 1 </otherwise>
|
||||
</choose>
|
||||
</sql>
|
||||
|
||||
<select id="queryList" parameterType="com.mhd.oms.domain.reservationStockOutOrder.repository.todo.ReservationStockOutOrderDO" resultMap="StockOutOrderResult">
|
||||
select
|
||||
<include refid="selectStockOutOrderPo"/>
|
||||
from reservation_stock_out_order a
|
||||
<where>
|
||||
<include refid="selectStockOutOrderPo1"/>
|
||||
</where>
|
||||
order by a.create_time desc nulls last
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mhd.oms.domain.sysTableConfig.repository.mapper.SysTableConfigMapper">
|
||||
|
||||
<!-- 分页查询配置列表 -->
|
||||
<select id="queryList" parameterType="java.lang.String" resultType="com.mhd.oms.domain.sysTableConfig.repository.vo.SysTableConfigVO">
|
||||
SELECT
|
||||
a.id,
|
||||
a.create_by AS createBy,
|
||||
a.create_time AS createTime,
|
||||
a.update_by AS updateBy,
|
||||
a.update_time AS updateTime,
|
||||
a.organization_id AS organizationId,
|
||||
a.key AS key,
|
||||
a.value AS value,
|
||||
a.remark AS remark
|
||||
FROM sys_table_config a
|
||||
WHERE 1=1
|
||||
<include refid="common_where"></include>
|
||||
ORDER BY a.create_time DESC
|
||||
</select>
|
||||
|
||||
<!-- 公共查询条件 -->
|
||||
<sql id="common_where">
|
||||
<if test="organizationId != null">
|
||||
AND a.organization_id = #{organizationId}
|
||||
</if>
|
||||
<if test="warehouseId != null">
|
||||
AND a.warehouse_id = #{warehouseId}
|
||||
</if>
|
||||
<if test="key != null and key != ''">
|
||||
AND a.key LIKE CONCAT('%', #{key}, '%')
|
||||
</if>
|
||||
</sql>
|
||||
|
||||
</mapper>
|
||||
+12
-1
@@ -18,11 +18,13 @@ import com.mhd.system.api.domain.WarehouseFeignPO;
|
||||
import com.mhd.system.api.domain.cache.AssociationWarehouseCacheDO;
|
||||
import com.mhd.system.api.domain.cache.SystemServiceCacheUtil;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import com.mhd.wms.domain.inMaterialDetail.entity.InMaterialDetail;
|
||||
import com.mhd.wms.domain.inMaterialDetail.repository.todo.InMaterialDetailDO;
|
||||
import com.mhd.wms.domain.materialBaseInfo.entity.MaterialBaseInfo;
|
||||
import com.mhd.wms.domain.materialBaseInfo.repository.facade.IMaterialBaseInfoService;
|
||||
import com.mhd.wms.domain.materialBaseInfo.repository.po.MaterialBaseInfoPO;
|
||||
import com.mhd.wms.domain.materialBaseInfo.repository.todo.MaterialBaseInfoDO;
|
||||
import com.mhd.wms.domain.stockInOrder.entity.StockInOrder;
|
||||
import com.mhd.wms.domain.stockInOrder.repository.po.StockInOrderPO;
|
||||
import com.mhd.wms.domain.stockInOrder.repository.todo.StockInOrderDO;
|
||||
import com.mhd.wms.domain.stockInOrder.service.StockInOrderDomainService;
|
||||
@@ -264,6 +266,15 @@ public class StockInOrderApplicationService {
|
||||
return stockInOrderDomainService.auditState(stockInOrderDO);
|
||||
}
|
||||
|
||||
|
||||
public void omsOrderAdd(StockInOrder stockInOrder){
|
||||
stockInOrderDomainService.omsOrderAdd(stockInOrder);
|
||||
}
|
||||
|
||||
public void omsOrderAddDetail(List<InMaterialDetail> inMaterialDetails){
|
||||
stockInOrderDomainService.omsOrderAddDetail(inMaterialDetails);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 取消入库单
|
||||
* @author ZhouGY
|
||||
@@ -1867,4 +1878,4 @@ public class StockInOrderApplicationService {
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
+12
@@ -25,6 +25,7 @@ import com.mhd.system.api.domain.WarehouseFeignPO;
|
||||
import com.mhd.system.api.domain.cache.AssociationWarehouseCacheDO;
|
||||
import com.mhd.system.api.domain.cache.SystemServiceCacheUtil;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import com.mhd.wms.domain.inMaterialDetail.entity.InMaterialDetail;
|
||||
import com.mhd.wms.domain.materialInventory.entity.MaterialInventory;
|
||||
import com.mhd.wms.domain.materialInventory.repository.mapper.MaterialInventoryMapper;
|
||||
import com.mhd.wms.domain.materialInventory.repository.po.MaterialInventoryPO;
|
||||
@@ -38,6 +39,7 @@ import com.mhd.wms.domain.outMaterialDetail.repository.todo.OutMaterialDetailDO;
|
||||
import com.mhd.wms.domain.outMaterialDetail.service.OutMaterialDetailDomainService;
|
||||
import com.mhd.wms.domain.pickingMaterialDetail.repository.facade.IPickingMaterialDetailService;
|
||||
import com.mhd.wms.domain.pickingMaterialDetail.repository.po.PickingMaterialDetailPO;
|
||||
import com.mhd.wms.domain.stockInOrder.entity.StockInOrder;
|
||||
import com.mhd.wms.domain.stockOutOrder.entity.StockOutOrder;
|
||||
import com.mhd.wms.domain.stockOutOrder.repository.facade.IStockOutOrderService;
|
||||
import com.mhd.wms.domain.stockOutOrder.repository.po.StockOutOrderPO;
|
||||
@@ -1312,4 +1314,14 @@ public class StockOutOrderApplicationService {
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void omsOrderAdd(StockOutOrder stockOutOrder){
|
||||
stockOutOrderDomainService.omsOrderAdd(stockOutOrder);
|
||||
}
|
||||
|
||||
public void omsOrderAddDetail(List<OutMaterialDetail> outMaterialDetails){
|
||||
stockOutOrderDomainService.omsOrderAddDetail(outMaterialDetails);
|
||||
}
|
||||
|
||||
}
|
||||
+9
@@ -14,6 +14,7 @@ import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.SystemServiceFeign;
|
||||
import com.mhd.system.api.domain.PackDetailFeignPO;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import com.mhd.wms.domain.inMaterialDetail.entity.InMaterialDetail;
|
||||
import com.mhd.wms.domain.inMaterialDetail.repository.facade.IInMaterialDetailService;
|
||||
import com.mhd.wms.domain.inMaterialDetail.repository.po.InMaterialDetailPO;
|
||||
import com.mhd.wms.domain.inMaterialDetail.repository.todo.InMaterialDetailBaseDO;
|
||||
@@ -357,6 +358,14 @@ public class StockInOrderDomainService {
|
||||
}
|
||||
}
|
||||
|
||||
public void omsOrderAdd(StockInOrder stockInOrder) {
|
||||
stockInOrderService.save(stockInOrder);
|
||||
}
|
||||
|
||||
public void omsOrderAddDetail(List<InMaterialDetail> inMaterialDetails) {
|
||||
materialDetailService.saveBatch(inMaterialDetails);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 审核入库单
|
||||
* @author ZhouGY
|
||||
|
||||
+10
@@ -21,6 +21,7 @@ import com.mhd.wms.domain.deliveTask.repository.facade.IDeliveTaskService;
|
||||
import com.mhd.wms.domain.deliveTask.repository.todo.DeliveTaskDO;
|
||||
import com.mhd.wms.domain.handoverTaskOrder.repository.facade.IHandoverTaskOrderService;
|
||||
import com.mhd.wms.domain.handoverTaskOrder.repository.todo.HandoverTaskOrderDO;
|
||||
import com.mhd.wms.domain.inMaterialDetail.entity.InMaterialDetail;
|
||||
import com.mhd.wms.domain.inMaterialDetail.repository.todo.InMaterialDetailDO;
|
||||
import com.mhd.wms.domain.inventoryStandingDetail.repository.facade.IInventoryStandingDetailService;
|
||||
import com.mhd.wms.domain.inventoryStandingDetail.repository.todo.InventoryStandingDetailDO;
|
||||
@@ -58,6 +59,7 @@ import com.mhd.wms.domain.pushSyncBms.PushSyncBmsDomainService;
|
||||
import com.mhd.wms.domain.replenishmentNotice.repository.todo.ReplenishmentNoticeDO;
|
||||
import com.mhd.wms.domain.replenishmentNotice.service.ReplenishmentNoticeDomainService;
|
||||
import com.mhd.wms.domain.statementStatistics.po.ImmediateInventoryPO;
|
||||
import com.mhd.wms.domain.stockInOrder.entity.StockInOrder;
|
||||
import com.mhd.wms.domain.stockInOrder.repository.todo.StockInOrderDO;
|
||||
import com.mhd.wms.domain.stockInOrder.service.StockInOrderDomainService;
|
||||
import com.mhd.wms.domain.stockOutOrder.entity.StockOutOrder;
|
||||
@@ -1648,4 +1650,12 @@ public class StockOutOrderDomainService {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void omsOrderAdd(StockOutOrder stockOutOrder) {
|
||||
stockOutOrderService.save(stockOutOrder);
|
||||
}
|
||||
|
||||
public void omsOrderAddDetail(List<OutMaterialDetail> outMaterialDetails) {
|
||||
outMaterialDetailService.saveBatch(outMaterialDetails);
|
||||
}
|
||||
}
|
||||
+22
-1
@@ -6,6 +6,8 @@ import com.mhd.common.core.web.page.TableDataInfo;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.utils.StringUtils;
|
||||
import com.mhd.wms.application.service.stockInOrder.StockInOrderApplicationService;
|
||||
import com.mhd.wms.domain.inMaterialDetail.entity.InMaterialDetail;
|
||||
import com.mhd.wms.domain.stockInOrder.entity.StockInOrder;
|
||||
import com.mhd.wms.domain.stockInOrder.repository.po.StockInOrderPO;
|
||||
import com.mhd.wms.domain.stockInOrder.repository.todo.StockInOrderDO;
|
||||
import com.mhd.wms.interfaces.assember.stockInOrder.StockInOrderAssembler;
|
||||
@@ -129,4 +131,23 @@ public class StockInOrderApi extends BaseController {
|
||||
return AjaxResult.success(stockInOrderApplicationService.closeOrder(stockInOrderDO));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* oms下发单保存
|
||||
*/
|
||||
@ApiOperation("oms下发单保存")
|
||||
@PostMapping(value = "/omsInOrderAdd")
|
||||
public void omsInOrderAdd(@RequestBody StockInOrder stockInOrder) {
|
||||
stockInOrderApplicationService.omsOrderAdd(stockInOrder);
|
||||
}
|
||||
|
||||
/**
|
||||
* oms下发单明细保存
|
||||
*/
|
||||
@ApiOperation("oms下发单明细保存")
|
||||
@PostMapping(value = "/omsInOrderAddDetail")
|
||||
public void omsInOrderAddDetail(@RequestBody List<InMaterialDetail> inMaterialDetails) {
|
||||
stockInOrderApplicationService.omsOrderAddDetail(inMaterialDetails);
|
||||
}
|
||||
|
||||
}
|
||||
+23
@@ -9,7 +9,10 @@ import com.mhd.wms.application.service.handoverTaskOrder.HandoverTaskOrderApplic
|
||||
import com.mhd.wms.application.service.stockOutOrder.StockOutOrderApplicationService;
|
||||
import com.mhd.wms.domain.handoverTaskOrder.entity.HandoverTaskOrder;
|
||||
import com.mhd.wms.domain.handoverTaskOrder.repository.facade.IHandoverTaskOrderService;
|
||||
import com.mhd.wms.domain.inMaterialDetail.entity.InMaterialDetail;
|
||||
import com.mhd.wms.domain.outMaterialDetail.entity.OutMaterialDetail;
|
||||
import com.mhd.wms.domain.outMaterialDetail.repository.todo.OutMaterialDetailDO;
|
||||
import com.mhd.wms.domain.stockInOrder.entity.StockInOrder;
|
||||
import com.mhd.wms.domain.stockOutOrder.entity.StockOutOrder;
|
||||
import com.mhd.wms.domain.stockOutOrder.repository.facade.IStockOutOrderService;
|
||||
import com.mhd.wms.domain.stockOutOrder.repository.listener.ExcelParseService;
|
||||
@@ -384,4 +387,24 @@ public class StockOutOrderApi extends BaseController {
|
||||
return toAjax(stockOutOrderApplicationService.close(stockOutOrderDO));
|
||||
}
|
||||
|
||||
/**
|
||||
* oms下发单保存
|
||||
*/
|
||||
@ApiOperation("oms下发单保存")
|
||||
@PostMapping(value = "/omsOutOrderAdd")
|
||||
public void omsOutOrderAdd(@RequestBody StockOutOrder stockOutOrder) {
|
||||
stockOutOrderApplicationService.omsOrderAdd(stockOutOrder);
|
||||
}
|
||||
|
||||
/**
|
||||
* oms下发单明细保存
|
||||
*/
|
||||
@ApiOperation("oms下发单明细保存")
|
||||
@PostMapping(value = "/omsOutOrderAddDetail")
|
||||
public void omsOutOrderAddDetail(@RequestBody List<OutMaterialDetail> outMaterialDetails) {
|
||||
stockOutOrderApplicationService.omsOrderAddDetail(outMaterialDetails);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user