fix(region): disk update disk type (#21160)

This commit is contained in:
屈轩
2024-09-04 10:44:26 +08:00
committed by GitHub
parent f0927f0aba
commit 63e2a97dfd
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -425,7 +425,7 @@ func (self *SDisk) ValidateUpdateData(ctx context.Context, userCred mcclient.Tok
var err error
if input.DiskType != "" {
if !utils.IsInStringArray(input.DiskType, []string{api.DISK_TYPE_DATA, api.DISK_TYPE_VOLUME}) {
if !utils.IsInStringArray(input.DiskType, []string{api.DISK_TYPE_DATA, api.DISK_TYPE_VOLUME, api.DISK_TYPE_SYS}) {
return input, httperrors.NewInputParameterError("not support update disk_type %s", input.DiskType)
}
}