From b59d8e8abf4278b45c625c9ffdb091e3985fa031 Mon Sep 17 00:00:00 2001 From: jianxing Date: Wed, 26 Jul 2023 09:52:47 +0800 Subject: [PATCH] =?UTF-8?q?refactor(=E6=B5=8B=E8=AF=95=E8=B7=9F=E8=B8=AA):?= =?UTF-8?q?=20=E5=8A=9F=E8=83=BD=E7=94=A8=E4=BE=8B=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E5=92=8C=E8=84=91=E5=9B=BE=E5=88=87=E6=8D=A2=E6=97=B6=EF=BC=8C?= =?UTF-8?q?=E6=90=BA=E5=B8=A6=E7=89=88=E6=9C=AC=E7=AD=9B=E9=80=89=E6=9D=A1?= =?UTF-8?q?=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --bug=1028140 --user=陈建星 【测试跟踪】github#25848,功能用例使用版本筛选条件,切换到脑图模式后,条件没有带过来,需要重新筛选 https://www.tapd.cn/55049933/s/1397494 --- test-track/frontend/src/business/case/TestCase.vue | 7 +++++-- .../frontend/src/business/case/components/TestCaseList.vue | 6 ++++-- .../frontend/src/business/common/minder/TestCaseMinder.vue | 7 +++++-- 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/test-track/frontend/src/business/case/TestCase.vue b/test-track/frontend/src/business/case/TestCase.vue index 0f1b1d4c43..e6e56a90a6 100644 --- a/test-track/frontend/src/business/case/TestCase.vue +++ b/test-track/frontend/src/business/case/TestCase.vue @@ -93,7 +93,7 @@ :tree-nodes="treeNodes" :trash-enable="false" :public-enable="false" - :current-version="currentVersion" + :default-version="currentVersion" :version-enable.sync="versionEnable" @refreshTable="refresh" @getTrashList="getTrashList" @@ -107,11 +107,12 @@ @@ -239,6 +240,7 @@ export default { } }, mounted() { + this.currentVersion = this.defaultVersion || null; this.getProject(); this.checkVersionEnable(); }, @@ -454,6 +456,7 @@ export default { }, refreshTreeByCaseFilter(currentVersion) { this.condition.versionId = currentVersion || null; + this.currentVersion = this.condition.versionId; if (this.publicEnable) { this.$refs.publicNodeTree.list(); } else if (this.trashEnable) { diff --git a/test-track/frontend/src/business/case/components/TestCaseList.vue b/test-track/frontend/src/business/case/components/TestCaseList.vue index f16e1fc891..177d821f50 100644 --- a/test-track/frontend/src/business/case/components/TestCaseList.vue +++ b/test-track/frontend/src/business/case/components/TestCaseList.vue @@ -12,7 +12,7 @@ - + @@ -512,7 +512,8 @@ export default { versionEnable: { type: Boolean, default: false - } + }, + defaultVersion: String }, computed: { routeProjectId() { @@ -541,6 +542,7 @@ export default { } }, created: function () { + this.currentVersion = this.defaultVersion || null; this.checkCurrentProject(); getProjectMemberUserFilter((data) => { diff --git a/test-track/frontend/src/business/common/minder/TestCaseMinder.vue b/test-track/frontend/src/business/common/minder/TestCaseMinder.vue index 8aaab16352..a06d77d69f 100644 --- a/test-track/frontend/src/business/common/minder/TestCaseMinder.vue +++ b/test-track/frontend/src/business/common/minder/TestCaseMinder.vue @@ -5,7 +5,7 @@
- +
{ @@ -183,6 +185,7 @@ export default { methods: { changeVersion(currentVersion) { this.currentVersion = currentVersion || null; + this.$emit('versionChange', currentVersion); }, handleNodeUpdateForMinder() { if (this.noRefreshMinder) {