fix: VM's machine type options is not support (#307)

* feat: get options from API

Signed-off-by: Yi-Ya Chen <yiya.chen@suse.com>

* feat: add feature flag

Signed-off-by: Yi-Ya Chen <yiya.chen@suse.com>

* refactor: remove default value

Signed-off-by: Yi-Ya Chen <yiya.chen@suse.com>

* refactor: fallback to none

Signed-off-by: Yi-Ya Chen <yiya.chen@suse.com>

---------

Signed-off-by: Yi-Ya Chen <yiya.chen@suse.com>
This commit is contained in:
Yiya Chen
2025-06-02 12:38:04 +08:00
committed by GitHub
parent d6da4898b4
commit 7ecc9c320d
4 changed files with 18 additions and 9 deletions
@@ -114,13 +114,11 @@ export default {
},
machineTypeOptions() {
return [{
label: 'None',
value: ''
}, {
label: 'q35',
value: 'q35'
}];
return this.machineTypes.map((type) => {
if (!type) return { label: 'None', value: '' };
return { label: type, value: type };
});
},
templateOptions() {