mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
UI: Fix ISO Hypervisor selection (#11261)
This commit is contained in:
parent
9d049707d5
commit
a710ff8c6d
@ -148,7 +148,7 @@
|
||||
@handle-image-search-filter="filters => fetchImages(filters)"
|
||||
@update-image="updateFieldValue"
|
||||
@update-disk-size="updateFieldValue"
|
||||
@change-iso-hypervisor="value => hypervisor = value" />
|
||||
@change-iso-hypervisor="value => form.hypervisor = value" />
|
||||
<a-card
|
||||
v-else
|
||||
:tabList="imageTypeList"
|
||||
|
||||
@ -112,7 +112,7 @@
|
||||
v-model:value="localSelectedIsoHypervisor"
|
||||
:preFillContent="preFillContent"
|
||||
:options="isoHypervisorItems"
|
||||
@change="handleIsoHypervisorChange()"
|
||||
@change="handleIsoHypervisorChange"
|
||||
showSearch
|
||||
optionFilterProp="label"
|
||||
:filterOption="filterOption" />
|
||||
@ -325,8 +325,8 @@ export default {
|
||||
emitUpdateDiskSize (decorator, value) {
|
||||
this.$emit('update-disk-size', decorator, value)
|
||||
},
|
||||
handleIsoHypervisorChange () {
|
||||
this.$emit('change-iso-hypervisor', this.localIsoHypervisor)
|
||||
handleIsoHypervisorChange (hypervisor) {
|
||||
this.$emit('change-iso-hypervisor', hypervisor)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -63,7 +63,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { api } from '@/api'
|
||||
import { getAPI, postAPI } from '@/api'
|
||||
import { genericCompare } from '@/utils/sort.js'
|
||||
import OsLogo from '@/components/widgets/OsLogo'
|
||||
|
||||
@ -164,7 +164,7 @@ export default {
|
||||
params.directdownload = true
|
||||
}
|
||||
return new Promise((resolve, reject) => {
|
||||
api('registerTemplate', params).then(json => {
|
||||
postAPI('registerTemplate', params).then(json => {
|
||||
const result = json.registertemplateresponse.template[0]
|
||||
resolve(result)
|
||||
}).catch(error => {
|
||||
@ -225,7 +225,7 @@ export default {
|
||||
let osTypeId = this.defaultOsTypeId
|
||||
this.loading = true
|
||||
try {
|
||||
const json = await api('listOsTypes', { keyword: osName, filter: 'name,id' })
|
||||
const json = await getAPI('listOsTypes', { keyword: osName, filter: 'name,id' })
|
||||
if (json && json.listostypesresponse && json.listostypesresponse.ostype && json.listostypesresponse.ostype.length > 0) {
|
||||
osTypeId = json.listostypesresponse.ostype[0].id
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user