1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-01-12 09:17:41 +03:00

F OpenNebula/one#5422: Fix minor (#1432)

This commit is contained in:
Sergio Betanzos 2021-09-02 19:10:37 +02:00 committed by GitHub
parent 461b91a487
commit 5360d68ecc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 9 deletions

View File

@ -74,10 +74,11 @@ export const FIELDS = vmTemplate => {
return disks?.map(SIZE)
}
export const SCHEMA = yup.object({
DISK: yup
.array(yup.object({
SIZE: SIZE().validation
}))
.transform(DISK => [DISK].flat().filter(Boolean))
})
export const SCHEMA = yup
.object({
DISK: yup.array(yup.object({ SIZE: SIZE().validation }))
})
.transform(({ DISK, ...rest }) => ({
...rest,
DISK: [DISK].flat().filter(Boolean)
}))

View File

@ -46,8 +46,6 @@ function InstantiateVmTemplate () {
})
)
console.log(formData)
history.push(templateId ? PATH.TEMPLATE.VMS.LIST : PATH.INSTANCE.VMS.LIST)
enqueueInfo(`VM Template instantiated x${instances} - ${NAME}`)
}