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

B #5354: Solved bug wrong size to disk (VM temp update) (#461)

This commit is contained in:
Abel Coronado 2017-09-07 12:46:27 +02:00 committed by Tino Vázquez
parent ea065409b6
commit d597cefe15

View File

@ -151,7 +151,6 @@ define(function(require) {
selectedContext = $("div.image", context);
} else {
selectedContext = $("div.volatile", context);
var typeKvm = $("#TYPE_KVM", context).val();
var typeVcenter = $("#TYPE_VCENTER", context).val();
var type = "fs";
@ -168,9 +167,14 @@ define(function(require) {
}
var tmpl = WizardFields.retrieve(selectedContext);
if(type){
tmpl.TYPE = type;
}
tmpl.TYPE = type;
if(tmpl.SIZE != undefined && $(".mb_input_unit", context).val() == "GB"){
tmpl.SIZE = tmpl.SIZE * 1024;
tmpl.SIZE = tmpl.SIZE.toString();
}
var formatKvm = $("#FORMAT_KVM", context).val();
var formatVcenter = $("#FORMAT_VCENTER", context).val();
@ -180,11 +184,6 @@ define(function(require) {
tmpl.FORMAT = formatVcenter;
}
if($(".mb_input_unit", context).val() == "GB"){
tmpl.SIZE = tmpl.SIZE * 1024;
tmpl.SIZE = tmpl.SIZE.toString();
}
if($("input[name='" + this.diskTabId + "']:checked", context).val() == "image" && !tmpl["IMAGE"] && !tmpl["IMAGE_ID"]){
return {};
}