mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-23 22:50:09 +03:00
Feature #2746: Remove all .showinfo calls
This commit is contained in:
parent
568e63183f
commit
d34386822d
@ -929,13 +929,6 @@ var cluster_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Cluster.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Cluster.show,
|
||||
callback: updateClusterInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Cluster.show_to_update" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Cluster.show,
|
||||
@ -1447,7 +1440,7 @@ $(document).ready(function(){
|
||||
|
||||
initCheckAllBoxes(dataTable_clusters);
|
||||
tableCheckboxesListener(dataTable_clusters);
|
||||
infoListener(dataTable_clusters, "Cluster.showinfo");
|
||||
infoListener(dataTable_clusters, "Cluster.show");
|
||||
dataTable_clusters.fnSort( [ [1,config['user_config']['table_order']] ] );
|
||||
}
|
||||
});
|
||||
|
@ -322,19 +322,12 @@ var datastore_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Datastore.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Datastore.show,
|
||||
callback: updateDatastoreInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Datastore.refresh" : {
|
||||
type: "custom",
|
||||
call: function(){
|
||||
var tab = dataTable_datastores.parents(".tab");
|
||||
if (Sunstone.rightInfoVisible(tab)) {
|
||||
Sunstone.runAction("Datastore.showinfo", Sunstone.rightInfoResourceId(tab))
|
||||
Sunstone.runAction("Datastore.show", Sunstone.rightInfoResourceId(tab))
|
||||
} else {
|
||||
waitingNodes(dataTable_datastores);
|
||||
Sunstone.runAction("Datastore.list");
|
||||
@ -756,13 +749,6 @@ function updateDatastoreInfo(request,ds){
|
||||
Sunstone.updateInfoPanelTab("datastore_info_panel","datastore_image_tab",datastore_info_tab);
|
||||
Sunstone.popUpInfoPanel("datastore_info_panel", "datastores-tab");
|
||||
|
||||
|
||||
|
||||
$("#datastore_info_panel_refresh", $("#datastore_info_panel")).click(function(){
|
||||
$(this).html(spinner);
|
||||
Sunstone.runAction('Datastore.showinfo', info.ID);
|
||||
})
|
||||
|
||||
// Define datatables
|
||||
// Images datatable
|
||||
|
||||
@ -1172,7 +1158,7 @@ $(document).ready(function(){
|
||||
|
||||
initCheckAllBoxes(dataTable_datastores);
|
||||
tableCheckboxesListener(dataTable_datastores);
|
||||
infoListener(dataTable_datastores,'Datastore.showinfo');
|
||||
infoListener(dataTable_datastores,'Datastore.show');
|
||||
|
||||
// Reset filter in case the view was filtered because it was accessed
|
||||
// from a single cluster.
|
||||
|
@ -173,13 +173,6 @@ var file_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"File.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Image.show,
|
||||
callback: updateFileInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"File.refresh" : {
|
||||
type: "custom",
|
||||
call: function () {
|
||||
|
@ -234,13 +234,6 @@ var group_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Group.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Group.show,
|
||||
callback: updateGroupInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Group.autorefresh" : {
|
||||
type: "custom",
|
||||
call: function () {
|
||||
|
@ -150,13 +150,6 @@ var host_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Host.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Host.show,
|
||||
callback: updateHostInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Host.refresh" : {
|
||||
type: "custom",
|
||||
call: function(){
|
||||
@ -810,11 +803,6 @@ function updateHostInfo(request,host){
|
||||
|
||||
Sunstone.popUpInfoPanel("host_info_panel", "hosts-tab");
|
||||
|
||||
|
||||
$("#host_info_panel_refresh", $("#host_info_panel")).click(function(){
|
||||
$(this).html(spinner);
|
||||
Sunstone.runAction('Host.showinfo', host_info.ID);
|
||||
})
|
||||
// TODO: re-use Host.pool_monitor data?
|
||||
|
||||
//pop up panel while we retrieve the graphs
|
||||
@ -956,7 +944,7 @@ $(document).ready(function(){
|
||||
|
||||
initCheckAllBoxes(dataTable_hosts);
|
||||
tableCheckboxesListener(dataTable_hosts);
|
||||
infoListener(dataTable_hosts, "Host.showinfo");
|
||||
infoListener(dataTable_hosts, "Host.show");
|
||||
|
||||
// This listener removes any filter on hosts table when its menu item is
|
||||
// selected. The cluster plugins will filter hosts when the hosts
|
||||
|
@ -280,14 +280,6 @@ var image_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
// TODO: only needed by insert_permissions_table in sunstone.js
|
||||
"Image.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Image.show,
|
||||
callback: updateImageInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Image.refresh" : {
|
||||
type: "custom",
|
||||
call: function () {
|
||||
|
@ -34,7 +34,7 @@ var market_actions = {
|
||||
call: function () {
|
||||
var tab = dataTable_marketplace.parents(".tab");
|
||||
if (Sunstone.rightInfoVisible(tab)) {
|
||||
Sunstone.runAction("Marketplace.showinfo", Sunstone.rightInfoResourceId(tab))
|
||||
Sunstone.runAction("Marketplace.show", Sunstone.rightInfoResourceId(tab))
|
||||
} else {
|
||||
waitingNodes(dataTable_marketplace);
|
||||
Sunstone.runAction("Marketplace.list");
|
||||
@ -163,10 +163,16 @@ var market_actions = {
|
||||
},
|
||||
error: onError
|
||||
},
|
||||
"Marketplace.showinfo" : {
|
||||
|
||||
"Marketplace.show" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Marketplace.show,
|
||||
callback: updateMarketInfo,
|
||||
callback: function(request, response) {
|
||||
// updateMarketElement(request, response);
|
||||
if (Sunstone.rightInfoVisible($("#marketplace-tab"))) {
|
||||
updateMarketInfo(request, response);
|
||||
}
|
||||
},
|
||||
error: onError
|
||||
}
|
||||
}
|
||||
@ -315,11 +321,6 @@ function updateMarketInfo(request,app){
|
||||
|
||||
Sunstone.updateInfoPanelTab("marketplace_info_panel", "marketplace_info_tab", info_tab);
|
||||
Sunstone.popUpInfoPanel("marketplace_info_panel", "marketplace-tab");
|
||||
|
||||
$("#marketplace_info_panel_refresh", $("#marketplace_info_panel")).click(function(){
|
||||
$(this).html(spinner);
|
||||
Sunstone.runAction('Marketplace.showinfo', app['_id']["$oid"]);
|
||||
})
|
||||
};
|
||||
|
||||
function infoListenerMarket(dataTable){
|
||||
@ -339,7 +340,7 @@ function updateMarketInfo(request,app){
|
||||
} else {
|
||||
var context = $(this).parents(".tab");
|
||||
popDialogLoading();
|
||||
Sunstone.runAction("Marketplace.showinfo",id);
|
||||
Sunstone.runAction("Marketplace.show",id);
|
||||
$(".resource-id", context).html(id);
|
||||
$('.top_button, .list_button', context).attr('disabled', false);
|
||||
}
|
||||
|
@ -911,13 +911,6 @@ var service_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Service.showinfo" : {
|
||||
type: "single",
|
||||
call: Service.show,
|
||||
callback: updateServiceInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Service.refresh" : {
|
||||
type: "custom",
|
||||
call: function () {
|
||||
|
@ -377,13 +377,6 @@ var service_template_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"ServiceTemplate.showinfo" : {
|
||||
type: "single",
|
||||
call: ServiceTemplate.show,
|
||||
callback: updateServiceTemplateInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"ServiceTemplate.instantiate" : {
|
||||
type: "multiple",
|
||||
call: ServiceTemplate.instantiate,
|
||||
|
@ -270,14 +270,6 @@ var template_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
// TODO: only needed by insert_permissions_table in sunstone.js
|
||||
"Template.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Template.show,
|
||||
callback: updateTemplateInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Template.refresh" : {
|
||||
type: "custom",
|
||||
call: function () {
|
||||
|
@ -377,13 +377,6 @@ var user_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"User.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.User.show,
|
||||
callback: updateUserInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"User.delete" : {
|
||||
type: "multiple",
|
||||
call: OpenNebula.User.del,
|
||||
@ -743,11 +736,6 @@ function updateUserInfo(request,user){
|
||||
Sunstone.updateInfoPanelTab("user_info_panel","user_quotas_tab",quotas_tab);
|
||||
//Sunstone.updateInfoPanelTab("user_info_panel","user_acct_tab",acct_tab);
|
||||
Sunstone.popUpInfoPanel("user_info_panel", 'users-tab');
|
||||
|
||||
$("#user_info_panel_refresh", $("#user_info_panel")).click(function(){
|
||||
$(this).html(spinner);
|
||||
Sunstone.runAction('User.show', info.ID);
|
||||
})
|
||||
};
|
||||
|
||||
// Used also from groups-tabs.js
|
||||
|
@ -449,12 +449,6 @@ var vm_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"VM.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.VM.show,
|
||||
callback: updateVMInfo,
|
||||
error: onError
|
||||
},
|
||||
"VM.refresh" : {
|
||||
type: "custom",
|
||||
call : function (){
|
||||
|
@ -355,14 +355,6 @@ var vnet_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Network.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Network.show,
|
||||
callback: updateVNetworkInfo,
|
||||
error: onError
|
||||
|
||||
},
|
||||
|
||||
"Network.refresh" : {
|
||||
type: "custom",
|
||||
call: function(){
|
||||
@ -734,11 +726,6 @@ function updateVNetworkInfo(request,vn){
|
||||
Sunstone.popUpInfoPanel("vnet_info_panel", "vnets-tab");
|
||||
|
||||
setPermissionsTable(vn_info,'');
|
||||
|
||||
$("#vnet_info_panel_refresh", $("#vnet_info_panel")).click(function(){
|
||||
$(this).html(spinner);
|
||||
Sunstone.runAction('Network.showinfo', vn_info.ID);
|
||||
})
|
||||
}
|
||||
|
||||
// Prints the lis of leases depending on the Vnet TYPE
|
||||
@ -1402,7 +1389,7 @@ $(document).ready(function(){
|
||||
|
||||
initCheckAllBoxes(dataTable_vNetworks);
|
||||
tableCheckboxesListener(dataTable_vNetworks);
|
||||
infoListener(dataTable_vNetworks,'Network.showinfo');
|
||||
infoListener(dataTable_vNetworks,'Network.show');
|
||||
|
||||
// Reset list filter in case it was set because we were lookin
|
||||
// at a single cluster view
|
||||
|
@ -122,13 +122,6 @@ var zone_actions = {
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Zone.showinfo" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Zone.show,
|
||||
callback: updateZoneInfo,
|
||||
error: onError
|
||||
},
|
||||
|
||||
"Zone.show_to_update" : {
|
||||
type: "single",
|
||||
call: OpenNebula.Zone.show,
|
||||
@ -191,7 +184,7 @@ var zone_actions = {
|
||||
call: OpenNebula.Zone.rename,
|
||||
callback: function(request) {
|
||||
notifyMessage(tr("Zone renamed correctly"));
|
||||
Sunstone.runAction('Zone.showinfo',request.request.data[0][0]);
|
||||
Sunstone.runAction('Zone.show',request.request.data[0][0]);
|
||||
},
|
||||
error: onError,
|
||||
notify: true
|
||||
|
@ -3245,9 +3245,7 @@ function insert_permissions_table(tab_name, resource_type, resource_id, owner, g
|
||||
var resource_struct = new Array();
|
||||
resource_struct[0] = resource_id;
|
||||
|
||||
// TODO: race condition. Show can return before chown does
|
||||
Sunstone.runAction(resource_type+".chown",resource_struct,value_str);
|
||||
Sunstone.runAction(resource_type+".showinfo",resource_id);
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -3288,7 +3286,6 @@ function insert_permissions_table(tab_name, resource_type, resource_id, owner, g
|
||||
var resource_struct = new Array();
|
||||
resource_struct[0] = resource_id;
|
||||
Sunstone.runAction(resource_type+".chgrp",resource_struct,value_str);
|
||||
Sunstone.runAction(resource_type+".showinfo",resource_id);
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -3367,7 +3364,6 @@ function insert_cluster_dropdown(resource_type, resource_id, cluster_value, clus
|
||||
var resource_struct = new Array();
|
||||
resource_struct[0] = resource_id;
|
||||
Sunstone.runAction(resource_type+".addtocluster",resource_struct,value_str);
|
||||
Sunstone.runAction(resource_type+".showinfo",resource_id);
|
||||
}
|
||||
});
|
||||
|
||||
@ -3405,7 +3401,6 @@ function insert_group_dropdown(resource_type, resource_id, group_value, group_id
|
||||
var resource_struct = new Array();
|
||||
resource_struct[0] = resource_id;
|
||||
Sunstone.runAction(resource_type+".chgrp",resource_struct,value_str);
|
||||
Sunstone.runAction(resource_type+".showinfo",resource_id);
|
||||
}
|
||||
});
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user