fix(项目设置): 修复环境配置中http配置模块条件控制台报错的缺陷 (#15992)

--bug=1015066 --user=王孝刚 [接口测试]#15958v1.20.10 环境配置 - http配置 - 启用条件选择模块 -
选择模块保存后无法删除 https://www.tapd.cn/55049933/s/1205075

Co-authored-by: wxg0103 <727495428@qq.com>
This commit is contained in:
MeterSphere Bot 2022-07-21 11:31:46 +08:00 committed by GitHub
parent 5ead3641ae
commit 4b961bd398
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 58 additions and 52 deletions

View File

@ -368,7 +368,7 @@ export default {
this.editData = {delimiter: ",", quotedData: 'false', files: []};
this.editData.type = this.selectType;
this.showDelete = false;
if (this.editData.type === 'CSV') {
if (this.editData.type === 'CSV' && this.$refs.csv) {
this.$refs.csv.cleanPreview();
}
this.$refs.variableTable.cancelCurrentRow();

View File

@ -1,7 +1,8 @@
<template>
<div v-loading="loading">
<div class="mask" v-show="isShowSelect"></div>
<el-popover placement="bottom-start" :width="popoverWidth" trigger="manual" v-model="isShowSelect" @hide="popoverHide" v-outside-click="outsideClick">
<el-popover placement="bottom-start" :width="popoverWidth" trigger="manual" v-model="isShowSelect"
@hide="popoverHide" v-outside-click="outsideClick">
<el-input
size="mini"
prefix-icon="el-icon-search"
@ -32,7 +33,9 @@
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"></el-option>
</el-select>
<el-row>
<el-button v-if="multiple" class="ok" @click="isShowSelect=false" size="mini" type="text">{{ $t('commons.confirm') }}</el-button>
<el-button v-if="multiple" class="ok" @click="isShowSelect=false" size="mini" type="text">
{{ $t('commons.confirm') }}
</el-button>
</el-row>
</el-popover>
</div>
@ -271,8 +274,11 @@ export default {
});
this.returnDatas = t;
}
this.selectNodeIds = [];
if (data) {
this.getChildNodeId(data, this.selectNodeIds);
}
},
getChildNodeId(rootNode, nodeIds) {
//ID