资源池为空时跳转到压力配置Tab
This commit is contained in:
parent
25ee74760f
commit
ffdd3ebd40
|
@ -32,7 +32,7 @@
|
||||||
<performance-basic-config :test-plan="testPlan" ref="basicConfig"/>
|
<performance-basic-config :test-plan="testPlan" ref="basicConfig"/>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane :label="$t('load_test.pressure_config')">
|
<el-tab-pane :label="$t('load_test.pressure_config')">
|
||||||
<performance-pressure-config :test-plan="testPlan" :test-id="testId" ref="pressureConfig"/>
|
<performance-pressure-config :test-plan="testPlan" :test-id="testId" ref="pressureConfig" @changeActive="changeTabActive"/>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane :label="$t('load_test.advanced_config')" class="advanced-config">
|
<el-tab-pane :label="$t('load_test.advanced_config')" class="advanced-config">
|
||||||
<performance-advanced-config :test-id="testId" ref="advancedConfig"/>
|
<performance-advanced-config :test-id="testId" ref="advancedConfig"/>
|
||||||
|
@ -156,9 +156,9 @@
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
saveAndRun() {
|
saveAndRun() {
|
||||||
// if (!this.validTestPlan()) {
|
if (!this.validTestPlan()) {
|
||||||
// return;
|
return;
|
||||||
// }
|
}
|
||||||
|
|
||||||
let options = this.getSaveOption();
|
let options = this.getSaveOption();
|
||||||
|
|
||||||
|
@ -239,6 +239,11 @@
|
||||||
/// todo: 其他校验
|
/// todo: 其他校验
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
},
|
||||||
|
changeTabActive(activeName) {
|
||||||
|
this.$nextTick(()=> {
|
||||||
|
this.active = activeName;
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -299,6 +299,8 @@
|
||||||
validConfig() {
|
validConfig() {
|
||||||
if (!this.resourcePool) {
|
if (!this.resourcePool) {
|
||||||
this.$warning(this.$t('load_test.resource_pool_is_null'));
|
this.$warning(this.$t('load_test.resource_pool_is_null'));
|
||||||
|
// 资源池为空,设置参数为资源池所在Tab的name
|
||||||
|
this.$emit('changeActive', '1');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue