fix(性能测试): 压力配置中资源池无效时有时会显示uuid

--bug=1012469 --user=李玉号 【系统设置】配额列表,修改可用资源池,添加性能测试时资源池显示uuid
https://www.tapd.cn/55049933/s/1145166
This commit is contained in:
shiziyuan9527 2022-04-24 11:27:13 +08:00 committed by 刘瑞斌
parent 76abd781e2
commit 1183cddd71
1 changed files with 7 additions and 1 deletions

View File

@ -328,6 +328,7 @@ export default {
rpsLimitEnable: false,
options: {},
resourcePool: null,
setPoolNull: false,
resourcePools: [],
resourceNodes: [],
resourcePoolType: null,
@ -371,7 +372,10 @@ export default {
test: {
handler(n) {
if (n.testResourcePoolId) {
this.resourcePool = n.testResourcePoolId;
// ID
if (!this.setPoolNull) {
this.resourcePool = n.testResourcePoolId;
}
}
},
deep: true,
@ -407,6 +411,8 @@ export default {
// null
if (response.data.filter(p => p.id === this.resourcePool).length === 0) {
this.resourcePool = null;
// IDnull
this.setPoolNull = true;
}
this.resourcePoolChange();