'+
@@ -2662,7 +2671,7 @@ function setupCreateTemplateDialog(){
//addElement([spinner,'','','','','','','','','','','',''],dataTable_template_hosts);
OpenNebula.Host.list({
- timeout: true,
+ timeout: true,
success: function (request, host_list){
var host_list_array = [];
@@ -2672,7 +2681,7 @@ function setupCreateTemplateDialog(){
});
updateView(host_list_array, dataTable_template_hosts);
- },
+ },
error: onError
});
@@ -2764,7 +2773,7 @@ function setupCreateTemplateDialog(){
//addElement([spinner,'','','','',''],dataTable_template_clusters);
OpenNebula.Cluster.list({
- timeout: true,
+ timeout: true,
success: function (request, cluster_list){
var list_array = [];
@@ -2774,7 +2783,7 @@ function setupCreateTemplateDialog(){
});
updateView(list_array,dataTable_template_clusters);
- },
+ },
error: onError
});
@@ -2842,7 +2851,7 @@ function setupCreateTemplateDialog(){
generate_requirements();
});
- // Select Image or Volatile disk. The div is hidden depending on the selection, and the
+ // Select Image or Volatile disk. The div is hidden depending on the selection, and the
// vm_param class is included to be computed when the template is generated.
$("input[name='req_select']").change(function(){
if ($("input[name='req_select']:checked").val() == "host_select") {
@@ -2866,11 +2875,11 @@ function setupCreateTemplateDialog(){
var generate_requirements = function() {
var req_string=[];
- $.each(selected_hosts, function(key, value) {
+ $.each(selected_hosts, function(key, value) {
req_string.push('ID=\\"'+key+'\\"');
});
- $.each(selected_clusters, function(key, value) {
+ $.each(selected_clusters, function(key, value) {
req_string.push('CLUSTER_ID=\\"'+key+'\\"');
});
@@ -2881,7 +2890,7 @@ function setupCreateTemplateDialog(){
/**************************************************************************
OTHER TAB
-
+
**************************************************************************/
var add_otherTab = function() {
@@ -2926,17 +2935,17 @@ function setupCreateTemplateDialog(){
var tabs = $( "#template_create_tabs", dialog)//.tabs().addClass("ui-tabs-vertical");
- //$('#wizard_next').click(function(){
+ //$('#wizard_next').click(function(){
// var selected = tabs.tabs('option', 'active');
// tabs.tabs("option", "active", selected+1);
//});
//
- //$('#wizard_previous').click(function(){
+ //$('#wizard_previous').click(function(){
// var selected = tabs.tabs('option', 'active');
// tabs.tabs("option", "active", selected-1);
//});
- $('#template_template_reset_button').click(function(){
+ $('#template_template_reset_button').click(function(){
$create_template_dialog.trigger("reveal:close")
$create_template_dialog.empty();
setupCreateTemplateDialog();
@@ -3159,7 +3168,7 @@ function setupCreateTemplateDialog(){
//Reset form - empty boxes
$('button#reset_vm_form',dialog).click(function(){
- $('select#disks_box option',section_disks).remove();
+ $('select#disks_box option',section_disks).remove();
$('select#nics_box option',section_networks).remove();
$('select#inputs_box option',section_inputs).remove();
$('select#custom_var_box option',section_custom_var).remove();
@@ -3177,7 +3186,7 @@ function popUpUpdateTemplateDialog(){
function popUpCreateTemplateDialog(){
$('button#create_template_form_easy', $create_template_dialog).show();
$('button#template_template_update_button', $create_template_dialog).hide();
-
+
$create_template_dialog.reveal();
};
@@ -3247,13 +3256,13 @@ function setupTemplateTemplateUpdateDialog(){
function popUpTemplateTemplateUpdateDialog(){
var selected_nodes = getSelectedNodes(dataTable_templates);
-
+
if ( selected_nodes.length != 1 )
{
notifyMessage("Please select one (and just one) template to update.");
return false;
}
-
+
// Get proper cluster_id
var template_id = ""+selected_nodes[0];
@@ -3324,7 +3333,7 @@ function fillTemplatePopUp(request, response){
//
// GENERAL
//
-
+
var capacity_section = $('li#capacityTab', $create_template_dialog);
autoFillInputs(template, capacity_section);
@@ -3332,7 +3341,7 @@ function fillTemplatePopUp(request, response){
//
// DISKS
//
-
+
var number_of_disks = 0;
function fillDiskTab(disk) {
@@ -3347,7 +3356,7 @@ function fillTemplatePopUp(request, response){
// TODO updateView should not be required. Currently the dataTable
// is filled twice.
OpenNebula.Image.list({
- timeout: true,
+ timeout: true,
success: function (request, images_list){
var image_list_array = [];
@@ -3375,10 +3384,10 @@ function fillTemplatePopUp(request, response){
'IMAGE: '+ disk.IMAGE_ID + tr(" does not exists any more") +
'
×'+
'
';
-
- $(".dataTables_wrapper", disk_section).append(alert);
+
+ $(".dataTables_wrapper", disk_section).append(alert);
}
- },
+ },
error: onError
});
@@ -3412,7 +3421,7 @@ function fillTemplatePopUp(request, response){
//
// NICS
//
-
+
var number_of_nics = 0;
function fillNicTab(nic) {
@@ -3424,7 +3433,7 @@ function fillTemplatePopUp(request, response){
// TODO updateView should not be required. Currently the dataTable
// is filled twice.
OpenNebula.Network.list({
- timeout: true,
+ timeout: true,
success: function (request, networks_list){
var network_list_array = [];
@@ -3451,11 +3460,11 @@ function fillTemplatePopUp(request, response){
'NETWORK: '+ nic.NETWORK_ID + tr(" does not exists any more") +
'