mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
Sunstone's multiple VM instantation should act as CLI's when naming the new VMs
(cherry picked from commit be1cea51b1d8d376ee3d34a9ac88ea0b578193af)
This commit is contained in:
parent
fe2e33c488
commit
60fe076f85
@ -750,20 +750,17 @@ function setupCreateVMDialog(){
|
||||
if (!template_id.length){
|
||||
notifyError("You have not selected a template");
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
if (n_times.length){
|
||||
n_times_int=parseInt(n_times,10);
|
||||
}
|
||||
};
|
||||
|
||||
if (n_times_int>1){
|
||||
if (!vm_name.length){
|
||||
vm_name = $('#template_id option:selected',this).text();
|
||||
}
|
||||
for (var i=0; i< n_times_int; i++){
|
||||
Sunstone.runAction("Template.instantiate",template_id,vm_name+"_"+i);
|
||||
};
|
||||
} else {
|
||||
if (!vm_name.length){
|
||||
vm_name = $('#template_id option:selected',this).text();
|
||||
};
|
||||
|
||||
for (var i=0; i< n_times_int; i++){
|
||||
Sunstone.runAction("Template.instantiate",template_id,vm_name);
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user