From 7bb2bce81da1ff8bf0f685cafdde9e60251d45c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=A7=E7=B1=B3?= <470431449@qq.com> Date: Tue, 15 Oct 2024 15:48:23 +0800 Subject: [PATCH] =?UTF-8?q?EBOM-=E8=BD=ACPBOM=E6=97=B6=EF=BC=8C=E7=9B=B4?= =?UTF-8?q?=E5=8F=91=E5=8C=85=EF=BC=8C=E5=8F=91=E8=B4=A7=E5=89=8D=E5=8C=85?= =?UTF-8?q?-=E7=9B=B4=E6=8E=A5=E8=A6=86=E7=9B=96=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E8=A1=A8=E7=9A=84PBOM?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../nflg/product/bomnew/service/domain/EBom/EBomToPbomBase.java | 2 +- .../service/domain/EBom/topbomnew/FormalEBomToPbomBase.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/EBom/EBomToPbomBase.java b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/EBom/EBomToPbomBase.java index 28e9a32e..215fb54f 100644 --- a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/EBom/EBomToPbomBase.java +++ b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/EBom/EBomToPbomBase.java @@ -191,7 +191,7 @@ public abstract class EBomToPbomBase { //if (oldParent.getCreatedBy().equals(parentVo.getCreatedBy())) { if (ConvertToPBomModelEnum.OVERRIDE.equalsValue(convertMode.getValue())) { //当bom创建人为本人 或 版本大于当前版本则覆盖 - if (oldParent.getCreatedBy().equals(parentVo.getCreatedBy()) || parentVo.getCurrentVersion()==null || VersionUtil.compare(parentVo.getCurrentVersion(),oldParent.getCurrentVersion())>0){ + if (VirtualPackageTypeEnum.DIRECT_DELIVERY_PACKAGE.equalsValue(parentVo.getVirtualPartType()) || VirtualPackageTypeEnum.PRE_ASSEMBLY_PACKAGE.equalsValue(parentVo.getVirtualPartType()) || oldParent.getCreatedBy().equals(parentVo.getCreatedBy()) || parentVo.getCurrentVersion()==null || VersionUtil.compare(parentVo.getCurrentVersion(),oldParent.getCurrentVersion())>0){ SpringUtil.getBean(BomNewPbomChildService.class).getBaseMapper().deleteByMap(ImmutableMap.of("parent_row_id", oldParent.getRowId())); // this.delParentRowIds.add(oldParent.getRowId()); oldParent.setSourceRowId(parentVo.getBomRowId()); diff --git a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/EBom/topbomnew/FormalEBomToPbomBase.java b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/EBom/topbomnew/FormalEBomToPbomBase.java index da85a4af..3f14568b 100644 --- a/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/EBom/topbomnew/FormalEBomToPbomBase.java +++ b/nflg_project_dev/nflg-bom-new/src/main/java/com/nflg/product/bomnew/service/domain/EBom/topbomnew/FormalEBomToPbomBase.java @@ -193,7 +193,7 @@ public abstract class FormalEBomToPbomBase { else if (Objects.nonNull(oldParent) && oldParent.getStatus() < EBomStatusEnum.PUBLISHED.getValue()) { //if (oldParent.getCreatedBy().equals(parentVo.getCreatedBy())) { if (ConvertToPBomModelEnum.OVERRIDE.equalsValue(convertMode.getValue())) { - if (oldParent.getCreatedBy().equals(parentVo.getCreatedBy()) || parentVo.getCurrentVersion()==null || VersionUtil.compare(parentVo.getCurrentVersion(),oldParent.getCurrentVersion())>0) { + if (VirtualPackageTypeEnum.DIRECT_DELIVERY_PACKAGE.equalsValue(parentVo.getVirtualPartType()) || VirtualPackageTypeEnum.PRE_ASSEMBLY_PACKAGE.equalsValue(parentVo.getVirtualPartType()) || oldParent.getCreatedBy().equals(parentVo.getCreatedBy()) || parentVo.getCurrentVersion()==null || VersionUtil.compare(parentVo.getCurrentVersion(),oldParent.getCurrentVersion())>0) { SpringUtil.getBean(BomNewPbomChildService.class).getBaseMapper().deleteByMap(ImmutableMap.of("parent_row_id", oldParent.getRowId())); oldParent.setSourceRowId(parentVo.getBomRowId()); oldParent.setCreatedTime(LocalDateTime.now());