From 10ac6dab3d8b7d552ca646b96752fc1a1c3acd43 Mon Sep 17 00:00:00 2001 From: Jackwang Date: Thu, 28 Jul 2022 17:44:35 +0800 Subject: [PATCH] =?UTF-8?q?=E6=95=B0=E6=8D=AE=E7=B1=BB=E5=9E=8B=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../axis/service/impl/PowerAxisStructServiceImpl.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/epmet-plugins-module/pli-power-base/pli-power-base-server/src/main/java/com/epmet/plugin/power/modules/axis/service/impl/PowerAxisStructServiceImpl.java b/epmet-plugins-module/pli-power-base/pli-power-base-server/src/main/java/com/epmet/plugin/power/modules/axis/service/impl/PowerAxisStructServiceImpl.java index 34bad4f..531b61b 100644 --- a/epmet-plugins-module/pli-power-base/pli-power-base-server/src/main/java/com/epmet/plugin/power/modules/axis/service/impl/PowerAxisStructServiceImpl.java +++ b/epmet-plugins-module/pli-power-base/pli-power-base-server/src/main/java/com/epmet/plugin/power/modules/axis/service/impl/PowerAxisStructServiceImpl.java @@ -144,8 +144,8 @@ public class PowerAxisStructServiceImpl extends BaseServiceImpl NumConstant.ONE) { + Integer parentStructLevel = powerAxisTagService.selectStructLevelById(customerId, PowerTagCategoryEnum.STRUCT.category(), structDto.getPid()); + if (structLevel - parentStructLevel.intValue() > NumConstant.ONE) { throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "无法跨级添加节点"); } } @@ -274,4 +274,4 @@ public class PowerAxisStructServiceImpl extends BaseServiceImpl