diff --git a/backend/src/main/java/io/metersphere/track/service/TestCaseNodeService.java b/backend/src/main/java/io/metersphere/track/service/TestCaseNodeService.java index 16dfadf496..22d612a948 100644 --- a/backend/src/main/java/io/metersphere/track/service/TestCaseNodeService.java +++ b/backend/src/main/java/io/metersphere/track/service/TestCaseNodeService.java @@ -586,12 +586,9 @@ public class TestCaseNodeService { } - /** - * 测试用例同级模块排序 - * @param ids - */ + // 测试用例同级模块排序 public void sort(List ids) { - // 获取同级相邻节点 + // 获取相邻节点 String before = ids.get(0); String id = ids.get(1); String after = ids.get(2); diff --git a/frontend/src/business/components/track/common/NodeTree.vue b/frontend/src/business/components/track/common/NodeTree.vue index 835d6cfc9b..33f89d20c5 100644 --- a/frontend/src/business/components/track/common/NodeTree.vue +++ b/frontend/src/business/components/track/common/NodeTree.vue @@ -108,6 +108,9 @@ export default { }, methods: { handleDragEnd(draggingNode, dropNode, dropType, ev) { + if (dropType === "none" || dropType === undefined) { + return; + } let param = this.buildParam(draggingNode, dropNode, dropType); this.list = [];