diff --git a/test-track/frontend/src/business/case/components/TestCaseList.vue b/test-track/frontend/src/business/case/components/TestCaseList.vue index 929860a838..f51f1bbb10 100644 --- a/test-track/frontend/src/business/case/components/TestCaseList.vue +++ b/test-track/frontend/src/business/case/components/TestCaseList.vue @@ -549,6 +549,10 @@ export default { watch: { '$route'(to) { if (to.path.indexOf("/track/case/all") >= 0) { + if (to.query.moduleId) { + // 点击模块导致路由变更不刷新,避免刷新两次 + return; + } this.getTemplateField(); let ids = this.$route.params.ids; if (ids) { diff --git a/test-track/frontend/src/business/module/TestCaseNodeTree.vue b/test-track/frontend/src/business/module/TestCaseNodeTree.vue index 9e7c6667d2..b8418c7f6d 100644 --- a/test-track/frontend/src/business/module/TestCaseNodeTree.vue +++ b/test-track/frontend/src/business/module/TestCaseNodeTree.vue @@ -323,6 +323,8 @@ export default { this.currentModule = node.data; this.currentNode = node; + this.$emit("nodeSelectEvent", node, node.data.id === 'root' ? [] : nodeIds, pNodes); + // 刷新模块树 this.nohupReloadTree(node.data.id); },