From 930894b37e0f690f9bcc8a49fae065cfd59fbf24 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A7=A6=E9=B8=BF=E5=B1=95?= <18031053041@163.com> Date: Mon, 6 Jul 2026 19:56:54 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=B3=E5=8A=A1=E6=8E=A8=E9=80=81=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E5=AD=97=E6=AE=B5=EF=BC=8C=E5=8F=91=E6=B5=8B=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/mhd/system/api/BmsServiceFeign.java | 2 +- .../com/mhd/system/api/OmsServiceFeign.java | 2 +- .../com/mhd/system/api/WlhyServiceFeign.java | 2 +- .../com/mhd/system/api/WmsServiceFeign.java | 2 +- .../com/mhd/system/api/YmsServiceFeign.java | 2 +- ...sinessDocumentOrderApplicationService.java | 34 ++----------------- .../OrderWithMaterialDTO.java | 6 ++++ .../OriginalImportExportDocumentApi.java | 11 ++++++ mhd_oms/src/main/resources/bootstrap.yml | 2 +- 9 files changed, 26 insertions(+), 37 deletions(-) diff --git a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/BmsServiceFeign.java b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/BmsServiceFeign.java index 8cc8bfd57..91f2f8a11 100644 --- a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/BmsServiceFeign.java +++ b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/BmsServiceFeign.java @@ -18,7 +18,7 @@ import java.util.Set; /** * bms财务结算系统feign调用接口 */ -@FeignClient(contextId = "BmsService", value = ServiceNameConstants.BMS_SERVICE, url = "http://10.102.192.32:8019",fallbackFactory = RemoteBmsFeignFallbackFactory.class, configuration = FeignAutoConfiguration.class) +@FeignClient(contextId = "BmsService", value = ServiceNameConstants.BMS_SERVICE, url = "http://10.33.0.109:8019",fallbackFactory = RemoteBmsFeignFallbackFactory.class, configuration = FeignAutoConfiguration.class) public interface BmsServiceFeign { diff --git a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/OmsServiceFeign.java b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/OmsServiceFeign.java index 25e3fa827..e5de37d8e 100644 --- a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/OmsServiceFeign.java +++ b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/OmsServiceFeign.java @@ -16,7 +16,7 @@ import org.springframework.web.bind.annotation.RequestBody; import java.util.List; import java.util.concurrent.CompletableFuture; -@FeignClient(contextId = "OmsService", value = ServiceNameConstants.OMS_SERVICE,url = "http://10.102.192.33", fallbackFactory = RemoteOmsFeignFallbackFactory.class, configuration = FeignAutoConfiguration.class) +@FeignClient(contextId = "OmsService", value = ServiceNameConstants.OMS_SERVICE,url = "http://10.33.0.99", fallbackFactory = RemoteOmsFeignFallbackFactory.class, configuration = FeignAutoConfiguration.class) public interface OmsServiceFeign { diff --git a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/WlhyServiceFeign.java b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/WlhyServiceFeign.java index d976fcc98..ba9a45148 100644 --- a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/WlhyServiceFeign.java +++ b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/WlhyServiceFeign.java @@ -26,7 +26,7 @@ import org.springframework.web.bind.annotation.*; import java.util.List; import java.util.Map; -@FeignClient(contextId = "commonWlhyServiceFeign",value = ServiceNameConstants.WLHY_SERVICE,url = "http://10.102.192.31:8014",configuration = FeignAutoConfiguration.class) +@FeignClient(contextId = "commonWlhyServiceFeign",value = ServiceNameConstants.WLHY_SERVICE,url = "http://10.33.0.129:8014",configuration = FeignAutoConfiguration.class) public interface WlhyServiceFeign { /** diff --git a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/WmsServiceFeign.java b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/WmsServiceFeign.java index 653f44d4b..688e5ea7c 100644 --- a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/WmsServiceFeign.java +++ b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/WmsServiceFeign.java @@ -21,7 +21,7 @@ import java.util.Map; * @description: TODO * @date 2024/5/10 8:58 **/ -@FeignClient(contextId = "remoteWmsServiceFeign",value = ServiceNameConstants.WMS_SERVICE, url = "http://10.102.192.32:8016", fallbackFactory = RemoteWmsFallbackFactory.class, configuration = FeignAutoConfiguration.class) +@FeignClient(contextId = "remoteWmsServiceFeign",value = ServiceNameConstants.WMS_SERVICE, url = "http://10.33.0.109:8016", fallbackFactory = RemoteWmsFallbackFactory.class, configuration = FeignAutoConfiguration.class) public interface WmsServiceFeign { /** diff --git a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/YmsServiceFeign.java b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/YmsServiceFeign.java index 238ec5f81..48d76d01e 100644 --- a/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/YmsServiceFeign.java +++ b/mhd-api/mhd-api-system/src/main/java/com/mhd/system/api/YmsServiceFeign.java @@ -9,7 +9,7 @@ import com.mhd.system.api.feign.FeignAutoConfiguration; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.web.bind.annotation.*; -@FeignClient(contextId = "YmsService", value = ServiceNameConstants.YMS_SERVICE,fallbackFactory = RemoteBmsFeignFallbackFactory.class,url = "http://10.102.192.33:8018", configuration = FeignAutoConfiguration.class) +@FeignClient(contextId = "YmsService", value = ServiceNameConstants.YMS_SERVICE,fallbackFactory = RemoteBmsFeignFallbackFactory.class,url = "http://10.33.0.99:8018", configuration = FeignAutoConfiguration.class) public interface YmsServiceFeign { /** 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 0de929a6e..b3e99f7f0 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 @@ -25,8 +25,7 @@ import com.mhd.oms.domain.gwLog.entity.GwLog; import com.mhd.oms.domain.gwLog.repository.mapper.GwLogMapper; import com.mhd.oms.domain.documentPushMaterialRecord.entity.DocumentPushMaterialRecord; import com.mhd.oms.domain.documentPushMaterialRecord.repository.mapper.DocumentPushMaterialRecordMapper; -import com.mhd.oms.domain.erpCountry.entity.ErpCountry; -import com.mhd.oms.domain.erpCountry.repository.mapper.ErpCountryMapper; + import com.mhd.oms.interfaces.dto.businessDocumentAddressMulti.BusinessAuditDTO; import com.mhd.oms.interfaces.dto.businessDocumentOrder.BusinessDocumentOrderDTO; import com.mhd.system.api.model.LoginUser; @@ -96,8 +95,7 @@ public class BusinessDocumentOrderApplicationService { @Resource private DocumentPushMaterialRecordMapper documentPushMaterialRecordMapper; - @Resource - private ErpCountryMapper erpCountryMapper; + /** * 分页查询【请填写功能名称】列表 @@ -252,10 +250,6 @@ public class BusinessDocumentOrderApplicationService { body.put("goodsType", goodsType != null ? goodsType : ""); body.put("ieFlag", order.getIeType() != null ? order.getIeType() : ""); body.put("corpCode", corpCode != null ? corpCode : ""); - // 启运/运抵国地区(收货地→ErpCountry表) - body.put("stshipTrsarvNatcd", lookupErpCountryCode(order.getUnloadAreaId(), order.getUnloadName())); - // 贸易国地区(发货地→ErpCountry表) - body.put("tradeAreaCode", lookupErpCountryCode(order.getLoadingAreaId(), order.getLoadingName())); List> billList = new ArrayList<>(); if (cargoList != null && !cargoList.isEmpty()) { @@ -440,29 +434,7 @@ public class BusinessDocumentOrderApplicationService { } - /** 根据区域ID或名称查ErpCountry表获取国别编码 */ - private String lookupErpCountryCode(String areaId, String areaName) { - if (areaId == null && areaName == null) return ""; - try { - LambdaQueryWrapper qw = new LambdaQueryWrapper<>(); - qw.eq(ErpCountry::getDelFlag, 1); - if (areaId != null) { - qw.eq(ErpCountry::getErpCountryCode, areaId); - } - List list = erpCountryMapper.selectList(qw); - if (!list.isEmpty()) return list.get(0).getErpCountryCode(); - // 按名称模糊匹配 - if (areaName != null) { - LambdaQueryWrapper qw2 = new LambdaQueryWrapper<>(); - qw2.eq(ErpCountry::getDelFlag, 1).like(ErpCountry::getErpCountryName, areaName); - List list2 = erpCountryMapper.selectList(qw2); - if (!list2.isEmpty()) return list2.get(0).getErpCountryCode(); - } - } catch (Exception e) { - log.warn("查ErpCountry失败 areaId={} areaName={}", areaId, areaName, e); - } - return areaId != null ? areaId : ""; - } + private void updatePushStatus(Long id, Integer pushStatus, Date pushTime, String pushBy, String pushByName) { diff --git a/mhd_oms/src/main/java/com/mhd/oms/interfaces/dto/originalImportExportDocument/OrderWithMaterialDTO.java b/mhd_oms/src/main/java/com/mhd/oms/interfaces/dto/originalImportExportDocument/OrderWithMaterialDTO.java index 15bfe06ff..168d85ab3 100644 --- a/mhd_oms/src/main/java/com/mhd/oms/interfaces/dto/originalImportExportDocument/OrderWithMaterialDTO.java +++ b/mhd_oms/src/main/java/com/mhd/oms/interfaces/dto/originalImportExportDocument/OrderWithMaterialDTO.java @@ -825,6 +825,12 @@ public class OrderWithMaterialDTO { @ApiModelProperty("贸易国地区") private String tradeAreaCode; + @ApiModelProperty("境内货源地") + private String domesticSourcePlace; + + @ApiModelProperty("最终目的国(地区)") + private String destinationCountry; + @ApiModelProperty("企业总价") private BigDecimal entTotal; diff --git a/mhd_oms/src/main/java/com/mhd/oms/interfaces/facade/originalImportExportDocument/OriginalImportExportDocumentApi.java b/mhd_oms/src/main/java/com/mhd/oms/interfaces/facade/originalImportExportDocument/OriginalImportExportDocumentApi.java index 836497683..3df83c125 100644 --- a/mhd_oms/src/main/java/com/mhd/oms/interfaces/facade/originalImportExportDocument/OriginalImportExportDocumentApi.java +++ b/mhd_oms/src/main/java/com/mhd/oms/interfaces/facade/originalImportExportDocument/OriginalImportExportDocumentApi.java @@ -210,6 +210,15 @@ public class OriginalImportExportDocumentApi extends BaseController { // 贸易国地区(发货地 → ErpCountry) dto.setTradeAreaCode(lookupCountryCode(order.getLoadingAreaId(), order.getLoadingName())); + // 最终目的国(优先取订单填写,未填写则取收货地) + if (dto.getDestinationCountry() == null || dto.getDestinationCountry().isEmpty()) { + dto.setDestinationCountry(order.getUnloadName()); + } + // 境内货源地(优先取订单填写,未填写则取发货地) + if (dto.getDomesticSourcePlace() == null || dto.getDomesticSourcePlace().isEmpty()) { + dto.setDomesticSourcePlace(order.getLoadingName()); + } + // 原产国(直接取originCountry) dto.setCountryCode(dto.getOriginCountry()); @@ -247,6 +256,8 @@ public class OriginalImportExportDocumentApi extends BaseController { } + + @ApiOperation("批量推送") @PostMapping("/batchPushForReviseApply") public AjaxResult batchPushForReviseApply(@RequestBody BusinessDocumentOrderDTO businessDocumentOrderDTO){ diff --git a/mhd_oms/src/main/resources/bootstrap.yml b/mhd_oms/src/main/resources/bootstrap.yml index 88471e390..09ef96b56 100644 --- a/mhd_oms/src/main/resources/bootstrap.yml +++ b/mhd_oms/src/main/resources/bootstrap.yml @@ -17,7 +17,7 @@ spring: nacos: discovery: # server-addr: 127.0.0.1:8848 - # 线上测试环境配置 容器名+端口号 +# 线上测试环境配置 容器名+端口号 server-addr: 10.33.0.129:6010 # server-addr: 10.102.192.30:6848 username: nacos