From d707d090bceac372ab1a95856e07107379d599e8 Mon Sep 17 00:00:00 2001 From: jianxing Date: Tue, 15 Aug 2023 16:53:49 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=B5=8B=E8=AF=95=E8=B7=9F=E8=B8=AA):=20?= =?UTF-8?q?=E8=84=91=E5=9B=BE=E5=B0=86=E7=94=A8=E4=BE=8B=E6=8B=96=E5=85=A5?= =?UTF-8?q?=E6=9C=AA=E5=8A=A0=E8=BD=BD=E7=94=A8=E4=BE=8B=E7=9A=84=E6=A8=A1?= =?UTF-8?q?=E5=9D=97=EF=BC=8C=E4=BC=9A=E4=BA=A7=E7=94=9F=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E4=B8=A2=E5=A4=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --bug=1028740 --user=陈建星 【测试跟踪】github#26157,功能用例-》脑图-》修改脑图,移动字节点到其他节点时,展示错误 https://www.tapd.cn/55049933/s/1403966 --- .../frontend/src/business/common/minder/TestCaseMinder.vue | 7 ++++++- .../frontend/src/business/common/minder/minderUtils.js | 4 ++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/test-track/frontend/src/business/common/minder/TestCaseMinder.vue b/test-track/frontend/src/business/common/minder/TestCaseMinder.vue index 7c56c946e3..a641bdb39f 100644 --- a/test-track/frontend/src/business/common/minder/TestCaseMinder.vue +++ b/test-track/frontend/src/business/common/minder/TestCaseMinder.vue @@ -62,7 +62,7 @@ import { isModuleNodeData, listenBeforeExecCommand, listenDblclick, - listenNodeSelected, + listenNodeSelected, loadNode, loadSelectNodes, priorityDisableCheck, tagEditCheck, @@ -276,6 +276,11 @@ export default { // 设置完标签后,优先级显示有问题,重新设置下 setTimeout(() => setPriorityView(true, 'P'), 100); } + + if ('movetoparent' === even.commandName) { + // 拖入的节点尚未加载时,加载节点 + loadNode(even.commandArgs[1], this.getParam(), getTestCasesForMinder, null, getMinderExtraNode); + } }); addIssueHotBox(this); diff --git a/test-track/frontend/src/business/common/minder/minderUtils.js b/test-track/frontend/src/business/common/minder/minderUtils.js index dde8bc2014..cdde8e8c13 100644 --- a/test-track/frontend/src/business/common/minder/minderUtils.js +++ b/test-track/frontend/src/business/common/minder/minderUtils.js @@ -411,7 +411,7 @@ function _appendExtraNodes(parent, data) { } /** - * 去掉已有节点 + * 清理子节点中的tmp节点 * @param parent */ function clearChildren(node) { @@ -419,7 +419,7 @@ function clearChildren(node) { if (children) { for (let i = 0; i < children.length; i++) { let item = children[i]; - if (item.data.type !== 'node') { + if (item.data.type === 'tmp') { window.minder.removeNode(item); i--; }