fix(测试计划): 测试计划在修改运行配置时,不会影响到其它的测试计划

This commit is contained in:
song-tianyang 2024-02-07 13:24:15 +08:00 committed by 建国
parent f9a33bf35d
commit 29ae426d6d
1 changed files with 21 additions and 19 deletions

View File

@ -1133,25 +1133,27 @@ export default {
this.haveOtherExecCase = false; this.haveOtherExecCase = false;
this.currentPlanId = row.id; this.currentPlanId = row.id;
let haveApiCase = row.testPlanApiCaseCount > 0; //idtick
let haveScenarioCase = row.testPlanApiScenarioCount > 0; this.$nextTick(() => {
let haveLoadCase = row.testPlanLoadCaseCount > 0; let haveApiCase = row.testPlanApiCaseCount > 0;
this.haveUICase = row.testPlanUiScenarioCount > 0; let haveScenarioCase = row.testPlanApiScenarioCount > 0;
let haveLoadCase = row.testPlanLoadCaseCount > 0;
if (!this.haveUICase && !haveApiCase && !haveScenarioCase && haveLoadCase) { this.haveUICase = row.testPlanUiScenarioCount > 0;
// if (!this.haveUICase && !haveApiCase && !haveScenarioCase && haveLoadCase) {
this.$refs.runMode.handleCommand("run"); //
} else if (haveApiCase || haveScenarioCase) { this.$refs.runMode.handleCommand("run");
// , } else if (haveApiCase || haveScenarioCase) {
this.haveOtherExecCase = true; // ,
this.$refs.runMode.open("API", row.runModeConfig); this.haveOtherExecCase = true;
} else if (this.haveUICase) { this.$refs.runMode.open("API", row.runModeConfig);
// UI } else if (this.haveUICase) {
this.$refs.runMode.open("", row.runModeConfig); // UI
} else { this.$refs.runMode.open("", row.runModeConfig);
// } else {
this.$router.push("/track/plan/view/" + row.id); //
} this.$router.push("/track/plan/view/" + row.id);
}
});
}, },
_handleRun(config) { _handleRun(config) {
let defaultPlanEnvMap = config.testPlanDefaultEnvMap; let defaultPlanEnvMap = config.testPlanDefaultEnvMap;