fix(接口测试): 修复sql的test页面显示前置sql数据源显示错误的缺陷

--bug=1027594 --user=王孝刚 【接口测试】test-前置sql-选择运行
环境和数据源-更新api接口-再次进入查看-sql环境为空 https://www.tapd.cn/55049933/s/1390005
This commit is contained in:
wxg0103 2023-07-06 11:22:05 +08:00 committed by f2c-ci-robot[bot]
parent e76a5a37f3
commit 2aaf7c00fb
1 changed files with 3 additions and 0 deletions

View File

@ -220,6 +220,9 @@ export default {
parseEnvironment(environment);
//
if (environment.id === this.request.environmentId) {
if (!environmentId) {
environmentId = environment.id;
}
if (environment.config && environment.config.databaseConfigs) {
environment.config.databaseConfigs.forEach((item) => {
if (item.id === this.request.dataSourceId) {