mirror of
https://github.com/OpenNebula/one.git
synced 2026-11-20 20:02:38 +09:00
Sunstone: do not open info tabs when clicking on empty tables
This commit is contained in:
1 parent
60b8e15ee9
commit
0b0d0d1166
5 files changed
+19
-5
No files matched your search
@@ -369,9 +369,12 @@ function hostInfoListener(){
|
||||
$('#tbodyhosts tr',dataTable_hosts).live("click",function(e){
|
||||
//do nothing if we are clicking a checkbox!
|
||||
if ($(e.target).is('input')) {return true;}
|
||||
popDialogLoading();
|
||||
|
||||
var aData = dataTable_hosts.fnGetData(this);
|
||||
var id = $(aData[0]).val();
|
||||
if (!id) return true;
|
||||
|
||||
popDialogLoading();
|
||||
Sunstone.runAction("Host.showinfo",id);
|
||||
return false;
|
||||
});
|
||||
|
||||
@@ -528,9 +528,11 @@ function imageInfoListener(){
|
||||
if (target.is('input') || target.is('select') || target.is('option'))
|
||||
return true;
|
||||
|
||||
popDialogLoading();
|
||||
var aData = dataTable_images.fnGetData(this);
|
||||
var id = $(aData[0]).val();
|
||||
if (!id) return true;
|
||||
|
||||
popDialogLoading();
|
||||
Sunstone.runAction("Image.showinfo",id);
|
||||
return false;
|
||||
});
|
||||
|
||||
@@ -865,9 +865,12 @@ function templateElementArray(template_json){
|
||||
function templateInfoListener(){
|
||||
$('#tbodytemplates tr',dataTable_templates).live("click",function(e){
|
||||
if ($(e.target).is('input')) {return true;}
|
||||
popDialogLoading();
|
||||
|
||||
var aData = dataTable_templates.fnGetData(this);
|
||||
var id = $(aData[0]).val();
|
||||
if (!id) return true;
|
||||
|
||||
popDialogLoading();
|
||||
Sunstone.runAction("Template.showinfo",id);
|
||||
return false;
|
||||
});
|
||||
|
||||
@@ -651,9 +651,12 @@ function vMachineInfoListener(){
|
||||
|
||||
$('#tbodyvmachines tr',dataTable_vMachines).live("click", function(e){
|
||||
if ($(e.target).is('input') || $(e.target).is('a img')) {return true;}
|
||||
popDialogLoading();
|
||||
|
||||
var aData = dataTable_vMachines.fnGetData(this);
|
||||
var id = $(aData[0]).val();
|
||||
if (!id) return true;
|
||||
|
||||
popDialogLoading();
|
||||
Sunstone.runAction("VM.showinfo",id);
|
||||
return false;
|
||||
});
|
||||
|
||||
@@ -457,9 +457,12 @@ function vNetworkInfoListener(){
|
||||
|
||||
$('#tbodyvnetworks tr',dataTable_vNetworks).live("click", function(e){
|
||||
if ($(e.target).is('input')) {return true;}
|
||||
popDialogLoading();
|
||||
|
||||
var aData = dataTable_vNetworks.fnGetData(this);
|
||||
var id = $(aData[0]).val();
|
||||
if (!id) return true;
|
||||
|
||||
popDialogLoading();
|
||||
Sunstone.runAction("Network.showinfo",id);
|
||||
return false;
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user