fix(系统设置): 修复环境变量超过十个,编辑变量跳转错误的缺陷

--bug=1028108 --user=王孝刚 【项目设置】github#25802,项目环境通用配置变量超过10个时,编辑变量跳转错误
https://www.tapd.cn/55049933/s/1396750
This commit is contained in:
wxg0103 2023-07-24 19:40:52 +08:00 committed by 刘瑞斌
parent 52ed72a69a
commit 12de2b9758

View File

@ -259,6 +259,7 @@ export default {
const allDataIndex = this.allData.findIndex((d) => d.name === index.name);
this.allData.splice(allDataIndex, 1);
this.sortParameters();
this.currentPage = Math.ceil(this.allData.length / this.pageSize);
this.queryPage();
},
queryPage() {
@ -301,14 +302,13 @@ export default {
}
if (isNeedCreate) {
this.items.push(new KeyValue({ enable: true, id: getUUID(), type: 'CONSTANT', scope: 'api' }));
this.currentPage = Math.ceil(this.allData.length / this.pageSize);
}
//
this.allData = [];
this._filter();
this.currentPage = Math.ceil(this.allData.length / this.pageSize);
this.queryPage();
this.$emit('change', this.items);
// TODO key
},
changeType(data) {
data.value = '';