mirror of
https://github.com/OpenNebula/one.git
synced 2025-01-11 05:17:41 +03:00
bug #4227: Fix template instantiate when image size is 0
This commit is contained in:
parent
346c1cdce9
commit
c85877424e
@ -154,10 +154,12 @@ define(function(require){
|
||||
$(".diskContainer", context).each(function(){
|
||||
if ($(this).data("template_disk")) {
|
||||
disk = $(this).data("template_disk");
|
||||
original_size = $(this).data("original_size");
|
||||
size = $("#SIZE", this).val();
|
||||
if (size) {
|
||||
disk['SIZE'] = Math.ceil(size * 1024);
|
||||
|
||||
if ($("#SIZE", this).is(':enabled')) {
|
||||
size = $("#SIZE", this).val();
|
||||
if (size) {
|
||||
disk['SIZE'] = Math.ceil(size * 1024);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -58,7 +58,7 @@ define(function(require) {
|
||||
}
|
||||
});
|
||||
|
||||
if (opts.startValue) {
|
||||
if (opts.startValue != undefined) {
|
||||
slider.foundation('slider', 'set_value', opts.startValue);
|
||||
input.val(opts.startValue);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user