From b689e3aacf6ef90ada77ea808a0aae43b5a1ceb6 Mon Sep 17 00:00:00 2001 From: Yiya Chen Date: Fri, 23 May 2025 16:23:09 +0800 Subject: [PATCH] feat: disable label (#310) Signed-off-by: Yi-Ya Chen --- pkg/harvester/config/labels-annotations.js | 3 ++- pkg/harvester/edit/harvesterhci.io.virtualmachineimage.vue | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/pkg/harvester/config/labels-annotations.js b/pkg/harvester/config/labels-annotations.js index 98a5bbf9..d35d5ff1 100644 --- a/pkg/harvester/config/labels-annotations.js +++ b/pkg/harvester/config/labels-annotations.js @@ -67,5 +67,6 @@ export const HCI = { VM_DEVICE_ALLOCATION_DETAILS: 'harvesterhci.io/deviceAllocationDetails', SVM_BACKUP_ID: 'harvesterhci.io/svmbackupId', DISABLE_LONGHORN_V2_ENGINE: 'node.longhorn.io/disable-v2-data-engine', - K8S_ARCH: 'kubernetes.io/arch' + K8S_ARCH: 'kubernetes.io/arch', + IMAGE_DISPLAY_NAME: 'harvesterhci.io/imageDisplayName' }; diff --git a/pkg/harvester/edit/harvesterhci.io.virtualmachineimage.vue b/pkg/harvester/edit/harvesterhci.io.virtualmachineimage.vue index b7871c38..0bea5572 100644 --- a/pkg/harvester/edit/harvesterhci.io.virtualmachineimage.vue +++ b/pkg/harvester/edit/harvesterhci.io.virtualmachineimage.vue @@ -110,6 +110,7 @@ export default { headers: {}, fileUrl: '', file: '', + HCI_ANNOTATIONS, }; }, @@ -595,6 +596,8 @@ export default { :pad-left="false" :read-allowed="false" :value-can-be-empty="true" + :toggle-filter="true" + :protected-keys="[HCI_ANNOTATIONS.IMAGE_DISPLAY_NAME]" @focusKey="focusKey" @update:value="value.setLabels($event)" > @@ -611,7 +614,7 @@ export default {