fix(接口测试): 接口定义,接口自动化列表切换模块 模块树统计异常

--bug=1020906 --user=张勇 【接口测试】接口定义 / 接口自动化列表、接口定义 / 接口自动化 回收站列表,简单搜索后,再点击左侧模块树切换模块,模块树的统计就变回去了 https://www.tapd.cn/55049933/s/1316586
This commit is contained in:
zhangyong 2022-12-17 20:43:01 +08:00 committed by f2c-ci-robot[bot]
parent 9e0bb8c208
commit 81b1cae00a
2 changed files with 10 additions and 6 deletions

View File

@ -301,14 +301,14 @@ export default {
if (!this.projectId) {
return;
}
getModuleByTrash(this.projectId).then((response) => {
postModuleByTrash(this.projectId, this.param).then((response) => {
this.setModuleList(response, selectNodeId);
});
} else {
if (!this.projectId) {
return;
}
getModuleByProjectId(this.projectId).then((response) => {
postModuleByProjectId(this.projectId, this.param).then((response) => {
this.setModuleList(response, selectNodeId);
});
}

View File

@ -344,16 +344,20 @@ export default {
this.setNohupData(response, selectNodeId);
});
} else if (this.isTrashData) {
getApiModuleByTrash(
postApiModuleByTrash(
this.projectId,
this.condition.protocol + (this.currentVersion ? '/' + this.currentVersion : '')
this.condition.protocol,
this.currentVersion,
this.param
).then((response) => {
this.setNohupData(response, selectNodeId);
});
} else {
getApiModules(
postApiModules(
this.projectId,
this.condition.protocol + (this.currentVersion ? '/' + this.currentVersion : '')
this.condition.protocol,
this.currentVersion,
this.param
).then((response) => {
this.setNohupData(response, selectNodeId);
});