Wire up the scale action on the task group page

This commit is contained in:
Michael Lange
2020-06-18 22:50:47 -07:00
parent 2227f24474
commit eb901b59b0
2 changed files with 7 additions and 1 deletions

View File

@@ -54,4 +54,9 @@ export default class TaskGroupController extends Controller.extend(
gotoAllocation(allocation) {
this.transitionToRoute('allocations.allocation', allocation);
}
@action
scaleTaskGroup(count) {
return this.model.scale(count);
}
}

View File

@@ -15,7 +15,8 @@
@max={{model.scaling.max}}
@value={{model.count}}
@class="is-primary is-small"
@disabled={{or model.job.runningDeployment (cannot "scale job")}}>
@disabled={{or model.job.runningDeployment (cannot "scale job")}}
@onChange={{action "scaleTaskGroup"}}>
Count
</StepperInput>
{{/if}}