From a74e9adcbc5773b61236335a1e0184fd3afed224 Mon Sep 17 00:00:00 2001
From: wxg0103 <727495428@qq.com>
Date: Tue, 26 Oct 2021 19:21:24 +0800
Subject: [PATCH] =?UTF-8?q?fix=5F=E6=8E=A5=E5=8F=A3=E5=AE=9A=E4=B9=89=5F?=
=?UTF-8?q?=E5=8D=A1=E7=89=87=E8=B7=B3=E8=BD=AC?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../mapper/ext/ExtApiDefinitionMapper.xml | 5 +++--
.../api/definition/ApiDefinition.vue | 3 ++-
.../components/ApiNewTestCaseList.vue | 21 +++++++++++--------
3 files changed, 17 insertions(+), 12 deletions(-)
diff --git a/backend/src/main/java/io/metersphere/base/mapper/ext/ExtApiDefinitionMapper.xml b/backend/src/main/java/io/metersphere/base/mapper/ext/ExtApiDefinitionMapper.xml
index 14c47d2abb..8a4a198e82 100644
--- a/backend/src/main/java/io/metersphere/base/mapper/ext/ExtApiDefinitionMapper.xml
+++ b/backend/src/main/java/io/metersphere/base/mapper/ext/ExtApiDefinitionMapper.xml
@@ -717,8 +717,9 @@
diff --git a/frontend/src/business/components/api/definition/ApiDefinition.vue b/frontend/src/business/components/api/definition/ApiDefinition.vue
index e9e0175144..923347d00e 100644
--- a/frontend/src/business/components/api/definition/ApiDefinition.vue
+++ b/frontend/src/business/components/api/definition/ApiDefinition.vue
@@ -383,6 +383,7 @@ export default {
});
},
'$route'(to, from) { // 路由改变时,把接口定义界面中的 ctrl s 保存快捷键监听移除
+ window.location.reload();
if (to.path.indexOf('/api/definition') === -1) {
if (this.$refs && this.$refs.apiConfig) {
this.$refs.apiConfig.forEach(item => {
@@ -390,7 +391,7 @@ export default {
});
}
}
- }
+ },
},
created() {
this.getEnv();
diff --git a/frontend/src/business/components/api/homepage/components/ApiNewTestCaseList.vue b/frontend/src/business/components/api/homepage/components/ApiNewTestCaseList.vue
index b2b3844bc4..30d957d003 100644
--- a/frontend/src/business/components/api/homepage/components/ApiNewTestCaseList.vue
+++ b/frontend/src/business/components/api/homepage/components/ApiNewTestCaseList.vue
@@ -4,19 +4,21 @@
-
+
{{ row.num }}
-
+
-
+
-
+
{{ row.name }}
-
+
-
+
@@ -32,7 +34,7 @@
+ width="100">
{{ row.caseTotal }}
@@ -40,7 +42,8 @@
+ :label="$t('api_test.home_page.new_case_list.table_coloum.relation_scenario')"
+ width="100">
{{ row.scenarioTotal }}
@@ -196,7 +199,7 @@ export default {
redirect(pageType, param) {
switch (pageType) {
case "api":
- this.$emit('redirectPage', 'api', 'api', 'apiList:' + param);
+ this.$router.push('/api/definition?resourceId=' + param)
break;
case "apiCase":
this.$emit('redirectPage', 'api', 'apiTestCase', 'singleList:' + param);