From 0dcd66c6c30d4e8eaa251f72567c3cdb19535be8 Mon Sep 17 00:00:00 2001 From: SadiJr Date: Tue, 14 Feb 2023 10:39:40 -0300 Subject: [PATCH] [UI] Use CPU frequency of unconstrained offerings when importing VMs from vCenter --- ui/src/views/tools/ImportUnmanagedInstance.vue | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/ui/src/views/tools/ImportUnmanagedInstance.vue b/ui/src/views/tools/ImportUnmanagedInstance.vue index 7aaa562e20b9..5ab97db77e19 100644 --- a/ui/src/views/tools/ImportUnmanagedInstance.vue +++ b/ui/src/views/tools/ImportUnmanagedInstance.vue @@ -179,7 +179,7 @@ :maxMemory="getMaxMemory()" @update-iops-value="updateFieldValue" @update-compute-cpunumber="updateFieldValue" - @update-compute-cpuspeed="updateFieldValue" + @update-compute-cpuspeed="updateCpuSpeed" @update-compute-memory="updateFieldValue" />
@@ -585,6 +585,15 @@ export default { this.selectMatchingComputeOffering() }) }, + updateCpuSpeed (name, value) { + if (this.computeOffering.iscustomized) { + if (this.computeOffering.serviceofferingdetails) { + this.updateFieldValue(this.cpuSpeedKey, this.computeOffering.cpuspeed) + } else { + this.updateFieldValue(this.cpuSpeedKey, value) + } + } + }, updateFieldValue (name, value) { this.form[name] = value },