diff --git a/frontend/src/business/components/api/automation/scenario/common/RunMode.vue b/frontend/src/business/components/api/automation/scenario/common/RunMode.vue index e9e6958993..5fa03f188d 100644 --- a/frontend/src/business/components/api/automation/scenario/common/RunMode.vue +++ b/frontend/src/business/components/api/automation/scenario/common/RunMode.vue @@ -158,6 +158,10 @@ export default { this.$warning(this.$t('commons.input_name')); return; } + if (this.runConfig.runWithinResourcePool && this.runConfig.resourcePoolId == null) { + this.$warning(this.$t('workspace.env_group.please_select_run_within_resource_pool')); + return; + } this.$emit("handleRunBatch", this.runConfig); this.close(); }, diff --git a/frontend/src/business/components/api/automation/schedule/ScheduleMaintain.vue b/frontend/src/business/components/api/automation/schedule/ScheduleMaintain.vue index 723d4d6a67..181ca72e9a 100644 --- a/frontend/src/business/components/api/automation/schedule/ScheduleMaintain.vue +++ b/frontend/src/business/components/api/automation/schedule/ScheduleMaintain.vue @@ -384,6 +384,10 @@ export default { this.$warning(this.$t('workspace.env_group.please_select_env_for_current_scenario')); return; } + if (this.runConfig.runWithinResourcePool && this.runConfig.resourcePoolId == null) { + this.$warning(this.$t('workspace.env_group.please_select_run_within_resource_pool')); + return; + } } param.config = JSON.stringify(this.runConfig); let url = '/api/automation/schedule/create'; diff --git a/frontend/src/business/components/api/definition/components/list/ApiCaseRunModeWithEnv.vue b/frontend/src/business/components/api/definition/components/list/ApiCaseRunModeWithEnv.vue index 464f50fa58..20682657f9 100644 --- a/frontend/src/business/components/api/definition/components/list/ApiCaseRunModeWithEnv.vue +++ b/frontend/src/business/components/api/definition/components/list/ApiCaseRunModeWithEnv.vue @@ -141,6 +141,10 @@ export default { this.$warning(this.$t('commons.input_name')); return; } + if (this.runConfig.runWithinResourcePool && this.runConfig.resourcePoolId == null) { + this.$warning(this.$t('workspace.env_group.please_select_run_within_resource_pool')); + return; + } this.$emit("handleRunBatch", this.runConfig); this.close(); }, diff --git a/frontend/src/business/components/track/plan/common/PlanRunModeWithEnv.vue b/frontend/src/business/components/track/plan/common/PlanRunModeWithEnv.vue index 3de16634aa..d12770d702 100644 --- a/frontend/src/business/components/track/plan/common/PlanRunModeWithEnv.vue +++ b/frontend/src/business/components/track/plan/common/PlanRunModeWithEnv.vue @@ -201,6 +201,10 @@ export default { }); }, handleCommand(command){ + if (this.runConfig.runWithinResourcePool && this.runConfig.resourcePoolId == null) { + this.$warning(this.$t('workspace.env_group.please_select_run_within_resource_pool')); + return; + } if (command === 'run') { this.runConfig.isRun = true this.handleRunBatch(); diff --git a/frontend/src/business/components/track/plan/components/ScheduleMaintain.vue b/frontend/src/business/components/track/plan/components/ScheduleMaintain.vue index ce8a2cda93..16b70658ab 100644 --- a/frontend/src/business/components/track/plan/components/ScheduleMaintain.vue +++ b/frontend/src/business/components/track/plan/components/ScheduleMaintain.vue @@ -363,6 +363,10 @@ export default { if (!param.workspaceId) { param.workspaceId = getCurrentWorkspaceId(); } + if (this.runConfig.runWithinResourcePool && this.runConfig.resourcePoolId == null) { + this.$warning(this.$t('workspace.env_group.please_select_run_within_resource_pool')); + return; + } param.config = JSON.stringify(this.runConfig); let url = '/api/automation/schedule/create'; if (this.scheduleTaskType === "TEST_PLAN_TEST") { diff --git a/frontend/src/i18n/en-US.js b/frontend/src/i18n/en-US.js index d5472d9c6d..24e8147231 100644 --- a/frontend/src/i18n/en-US.js +++ b/frontend/src/i18n/en-US.js @@ -605,6 +605,7 @@ export default { confirm: "Confirm", please_select_env_for_current_scenario: "please select env for current scenario", please_select_env_for_current_plan: "please select env for current plan", + please_select_run_within_resource_pool: "Please select a resource pool", lack_env: "Environment group is missing environment!", lack_necessary_environment: "This environment group lacks the necessary project environment!", available_group: 'available', diff --git a/frontend/src/i18n/zh-CN.js b/frontend/src/i18n/zh-CN.js index 9bab5b9c02..5ed4db52c1 100644 --- a/frontend/src/i18n/zh-CN.js +++ b/frontend/src/i18n/zh-CN.js @@ -607,6 +607,7 @@ export default { confirm: "确 定", please_select_env_for_current_scenario: "请为当前场景选择一个运行环境!", please_select_env_for_current_plan: "请为当前测试计划选择一个运行环境!", + please_select_run_within_resource_pool: "请选择一个资源池", lack_env: "环境组缺少环境!", lack_necessary_environment: "此环境组缺少必要的项目环境!", available_group: '可用环境组', diff --git a/frontend/src/i18n/zh-TW.js b/frontend/src/i18n/zh-TW.js index 9cfb309a62..b6e5b6862b 100644 --- a/frontend/src/i18n/zh-TW.js +++ b/frontend/src/i18n/zh-TW.js @@ -607,6 +607,7 @@ export default { confirm: "確 定", please_select_env_for_current_scenario: "請為當前場景選擇一個運行環境!", please_select_env_for_current_plan: "請為當前测试计划選擇一個運行環境!", + please_select_run_within_resource_pool: "請選擇一個資源池", lack_env: "環境組缺少環境!", lack_necessary_environment: "此環境組缺少必要的項目環境!", available_group: '可用環境組',