From f770e36d5ec735f53df298445a6940daa20d0bfa Mon Sep 17 00:00:00 2001 From: xyc <jc_xiong@hotmail.com> Date: 星期一, 18 十一月 2024 11:12:05 +0800 Subject: [PATCH] 修复bug:1)一键排版时不要自动保存; 2)无论设备数量多少,deviceNo统一改成从1开始。 --- modules/mainPart/src/main/java/com/zt/life/modules/mainPart/taskReliability/service/SimulatAssessService.java | 4 ++-- web/src/views/modules/taskReliability/RBD-edit-img.vue | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/taskReliability/service/SimulatAssessService.java b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/taskReliability/service/SimulatAssessService.java index 93e99b1..989600b 100644 --- a/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/taskReliability/service/SimulatAssessService.java +++ b/modules/mainPart/src/main/java/com/zt/life/modules/mainPart/taskReliability/service/SimulatAssessService.java @@ -1086,8 +1086,8 @@ // 璁惧 Integer deviceNo = node.getDeviceNo(); Element nodeTag = parent.addElement("node"); - nodeTag.addAttribute("name", deviceNo == 0 ? dataId.toString() : dataId.toString() + "-" + deviceNo); - nodeTag.addAttribute("real_name", deviceNo == 0 ? product.getName() : product.getName() + "-" + deviceNo); + nodeTag.addAttribute("name", dataId.toString() + "-" + deviceNo); + nodeTag.addAttribute("real_name", product.getName() + "-" + deviceNo); nodeTag.addAttribute("name_path", product.getNamePath()); nodeTag.addAttribute("type", "node"); diff --git a/web/src/views/modules/taskReliability/RBD-edit-img.vue b/web/src/views/modules/taskReliability/RBD-edit-img.vue index e331399..079cc4c 100644 --- a/web/src/views/modules/taskReliability/RBD-edit-img.vue +++ b/web/src/views/modules/taskReliability/RBD-edit-img.vue @@ -937,7 +937,7 @@ no = i if (node.getData().basicUnitNum >= 1) { node.getData().deviceNo = i - if(node.getData().basicUnitNum > 1){ + if(node.getData().deviceNo > 1){ node.attr('text/text', node.attr('text/text') + '-' + i) } } @@ -1040,7 +1040,7 @@ type: 'imageNodes2', dataId: item.dataId, basicUnitNum: item.basicUnitNum, - deviceNo: 0, + deviceNo: 1, nodeType: item.nodeType, nodeTypeExt: item.nodeTypeExt, productType: item.productType, -- Gitblit v1.9.1