fix(接口定义): 修复场景导入切换项目数据不一致的缺陷
--bug=1016234 --user=王孝刚 【接口测试】场景编辑-导入场景-切换项目 / 切换工作空间 -列表数据未对应更新 https://www.tapd.cn/55049933/s/1233227
This commit is contained in:
parent
f1f9f5f2dd
commit
58f93e55e3
|
@ -174,7 +174,7 @@ export default {
|
||||||
this.getVersionOptions();
|
this.getVersionOptions();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
search() {
|
search(projectId) {
|
||||||
this.selectRows = new Set();
|
this.selectRows = new Set();
|
||||||
this.condition.moduleIds = this.selectNodeIds;
|
this.condition.moduleIds = this.selectNodeIds;
|
||||||
if (this.trashEnable) {
|
if (this.trashEnable) {
|
||||||
|
@ -182,6 +182,9 @@ export default {
|
||||||
this.condition.moduleIds = [];
|
this.condition.moduleIds = [];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (projectId) {
|
||||||
|
this.projectId = projectId;
|
||||||
|
}
|
||||||
if (this.projectId != null && typeof projectId === 'string') {
|
if (this.projectId != null && typeof projectId === 'string') {
|
||||||
this.condition.projectId = this.projectId;
|
this.condition.projectId = this.projectId;
|
||||||
} else if (this.projectId != null) {
|
} else if (this.projectId != null) {
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
:is-across-space="isAcrossSpace"
|
:is-across-space="isAcrossSpace"
|
||||||
:dialog-title="$t('api_test.automation.scenario_import')"
|
:dialog-title="$t('api_test.automation.scenario_import')"
|
||||||
@setProject="setProject"
|
@setProject="setProject"
|
||||||
|
@refreshNode="refresh"
|
||||||
ref="baseRelevance">
|
ref="baseRelevance">
|
||||||
<template v-slot:aside>
|
<template v-slot:aside>
|
||||||
<ms-api-scenario-module
|
<ms-api-scenario-module
|
||||||
|
@ -221,7 +222,7 @@ export default {
|
||||||
this.moduleOptions = data;
|
this.moduleOptions = data;
|
||||||
},
|
},
|
||||||
refresh() {
|
refresh() {
|
||||||
this.$refs.apiScenarioList.search();
|
this.$refs.apiScenarioList.search(this.projectId);
|
||||||
},
|
},
|
||||||
setData(data) {
|
setData(data) {
|
||||||
this.currentScenario = Array.from(data).map(row => row);
|
this.currentScenario = Array.from(data).map(row => row);
|
||||||
|
@ -229,7 +230,6 @@ export default {
|
||||||
},
|
},
|
||||||
setProject(projectId) {
|
setProject(projectId) {
|
||||||
this.projectId = projectId;
|
this.projectId = projectId;
|
||||||
this.selectNodeIds = [];
|
|
||||||
},
|
},
|
||||||
getConditions() {
|
getConditions() {
|
||||||
return this.$refs.apiScenarioList.getConditions();
|
return this.$refs.apiScenarioList.getConditions();
|
||||||
|
|
Loading…
Reference in New Issue