Skip to content

Commit eba577c

Browse files
authored
ui: show nicAdapter selection for VMware non-readfromova template (apache#5429)
* ui: show nicAdapter selection for non-readfromova template Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com> * show keyboardcontroller and ostype elements in different rows Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
1 parent 10459de commit eba577c

File tree

1 file changed

+45
-33
lines changed

1 file changed

+45
-33
lines changed

ui/src/views/image/RegisterOrUploadTemplate.vue

Lines changed: 45 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@
220220
</a-form-item>
221221

222222
<a-row :gutter="12" v-if="hyperKVMShow || hyperVMWShow">
223-
<a-col :md="24" :lg="24" v-if="hyperKVMShow || (hyperVMWShow && !deployasis)">
223+
<a-col :md="24" :lg="hyperKVMShow ? 24 : 12" v-if="hyperKVMShow || (hyperVMWShow && !deployasis)">
224224
<a-form-item :label="$t('label.rootdiskcontrollertype')">
225225
<a-select
226226
v-decorator="['rootDiskControllerType', {
@@ -240,52 +240,64 @@
240240
</a-select>
241241
</a-form-item>
242242
</a-col>
243-
<a-col :md="24" :lg="24">
244-
<a-form-item v-if="hyperVMWShow && !deployasis" :label="$t('label.keyboardtype')">
243+
<a-col :md="24" :lg="12" v-if="hyperVMWShow && !deployasis">
244+
<a-form-item :label="$t('label.nicadaptertype')">
245245
<a-select
246-
v-decorator="['keyboardType', {
246+
v-decorator="['nicAdapterType', {
247247
rules: [
248248
{
249249
required: false,
250250
message: `${this.$t('message.error.select')}`
251251
}
252252
]
253253
}]"
254-
:placeholder="$t('label.keyboard')">
255-
<a-select-option v-for="opt in keyboardType.opts" :key="opt.id">
256-
{{ opt.name || opt.description }}
257-
</a-select-option>
258-
</a-select>
259-
</a-form-item>
260-
</a-col>
261-
</a-row>
262-
<a-row :gutter="12" v-if="!hyperVMWShow || (hyperVMWShow && !deployasis)">
263-
<a-col :md="24" :lg="24">
264-
<a-form-item :label="$t('label.ostypeid')">
265-
<a-select
266-
showSearch
267-
optionFilterProp="children"
268-
:filterOption="(input, option) => {
269-
return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
270-
}"
271-
v-decorator="['ostypeid', {
272-
initialValue: defaultOsId,
273-
rules: [
274-
{
275-
required: true,
276-
message: `${this.$t('message.error.select')}`
277-
}
278-
]
279-
}]"
280-
:loading="osTypes.loading"
281-
:placeholder="apiParams.ostypeid.description">
282-
<a-select-option v-for="opt in osTypes.opts" :key="opt.id">
254+
:placeholder="$t('label.nicadaptertype')">
255+
<a-select-option v-for="opt in nicAdapterType.opts" :key="opt.id">
283256
{{ opt.name || opt.description }}
284257
</a-select-option>
285258
</a-select>
286259
</a-form-item>
287260
</a-col>
288261
</a-row>
262+
<a-form-item :label="$t('label.keyboardtype')" :lg="12" v-if="hyperVMWShow && !deployasis">
263+
<a-select
264+
v-decorator="['keyboardType', {
265+
rules: [
266+
{
267+
required: false,
268+
message: `${this.$t('message.error.select')}`
269+
}
270+
]
271+
}]"
272+
:placeholder="$t('label.keyboard')">
273+
<a-select-option v-for="opt in keyboardType.opts" :key="opt.id">
274+
{{ opt.name || opt.description }}
275+
</a-select-option>
276+
</a-select>
277+
</a-form-item>
278+
<a-form-item :label="$t('label.ostypeid')" v-if="!hyperVMWShow || (hyperVMWShow && !deployasis)">
279+
<a-select
280+
showSearch
281+
optionFilterProp="children"
282+
:filterOption="(input, option) => {
283+
return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
284+
}"
285+
v-decorator="['ostypeid', {
286+
initialValue: defaultOsId,
287+
rules: [
288+
{
289+
required: true,
290+
message: `${this.$t('message.error.select')}`
291+
}
292+
]
293+
}]"
294+
:loading="osTypes.loading"
295+
:placeholder="apiParams.ostypeid.description">
296+
<a-select-option v-for="opt in osTypes.opts" :key="opt.id">
297+
{{ opt.name || opt.description }}
298+
</a-select-option>
299+
</a-select>
300+
</a-form-item>
289301
<a-row :gutter="12">
290302
<a-col :md="24" :lg="24">
291303
<a-form-item>

0 commit comments

Comments
 (0)