Merge pull request #114 from harvester/mergify/bp/release-harvester-v1.5/pr-13

align CPU pinning checkbox position in cloud template (backport #13)
This commit is contained in:
Andy Lee 2025-02-06 14:36:03 +08:00 committed by GitHub
commit e79f493cb6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 1 deletions

View File

@ -434,7 +434,7 @@ export default {
<div class="spacer"></div>
<Checkbox
v-if="value.cpuPinningFeatureEnabled"
v-model="cpuPinning"
v-model:value="cpuPinning"
class="check"
type="checkbox"
tooltip-key="harvester.virtualMachine.cpuPinning.tooltip"

View File

@ -210,6 +210,10 @@ export default class HciVmTemplateVersion extends HarvesterResource {
await templateResource.save();
}
get cpuPinningFeatureEnabled() {
return this.$rootGetters['harvester-common/getFeatureEnabled']('cpuPinning');
}
get defaultVersion() {
const templates = this.$rootGetters['harvester/all'](HCI.VM_TEMPLATE);
const template = templates.find((T) => this.templateId === T.id);