From 3017cb31063660bfc0378910b4b63537d786e5a9 Mon Sep 17 00:00:00 2001 From: zhaoqing <3160641494@qq.com> Date: Wed, 10 Jun 2026 09:52:16 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A8=E9=80=81=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../BusinessDocumentOrderApplicationService.java | 5 +++++ .../repository/po/MaterialBaseInfoPO.java | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/mhd_oms/src/main/java/com/mhd/oms/application/service/businessDocumentOrder/BusinessDocumentOrderApplicationService.java b/mhd_oms/src/main/java/com/mhd/oms/application/service/businessDocumentOrder/BusinessDocumentOrderApplicationService.java index 949c9dd10..d594a8edf 100644 --- a/mhd_oms/src/main/java/com/mhd/oms/application/service/businessDocumentOrder/BusinessDocumentOrderApplicationService.java +++ b/mhd_oms/src/main/java/com/mhd/oms/application/service/businessDocumentOrder/BusinessDocumentOrderApplicationService.java @@ -229,6 +229,11 @@ public class BusinessDocumentOrderApplicationService { body.put("billDate", billDate); // 商品类型取第一个cargo的productType(0料件,1半成品,2成品) Integer goodsType = (cargoList != null && !cargoList.isEmpty()) ? cargoList.get(0).getProductType() : null; + if (goodsType == null && cargoList != null && !cargoList.isEmpty() && cargoList.get(0).getMaterialBaseInfoId() != null) { + // productType为空时,从物料表查goodsType作为兜底 + MaterialBaseInfoPO material = reservationStockInOrderMapper.getinfo(cargoList.get(0).getMaterialBaseInfoId()); + goodsType = material != null ? material.getGoodsType() : null; + } body.put("goodsType", goodsType != null ? goodsType : ""); body.put("ieFlag", order.getIeType() != null ? order.getIeType() : ""); body.put("corpCode", corpCode != null ? corpCode : ""); diff --git a/mhd_oms/src/main/java/com/mhd/oms/domain/reservationStockInOrder/repository/po/MaterialBaseInfoPO.java b/mhd_oms/src/main/java/com/mhd/oms/domain/reservationStockInOrder/repository/po/MaterialBaseInfoPO.java index b7f40a5e2..5dc4b21e3 100644 --- a/mhd_oms/src/main/java/com/mhd/oms/domain/reservationStockInOrder/repository/po/MaterialBaseInfoPO.java +++ b/mhd_oms/src/main/java/com/mhd/oms/domain/reservationStockInOrder/repository/po/MaterialBaseInfoPO.java @@ -209,6 +209,10 @@ public class MaterialBaseInfoPO extends BaseVOEntity { @ApiModelProperty("HS码") private String hsCode; + @ApiModelProperty("货物类型:0-物料 1-半成品 2-成品") + @Excel(name = "货物类型:0-物料 1-半成品 2-成品") + private Integer goodsType; + @ApiModelProperty("申报单位") private String declarationUnit;