mirror of
https://github.com/pi-hole/web.git
synced 2025-12-27 13:59:14 +00:00
Make the client column clickable and send the user to the correspondignly filtered Query Log page on click
Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
@@ -162,8 +162,21 @@ $(document).ready(function() {
|
||||
"targets": -1,
|
||||
"data": null,
|
||||
"defaultContent": ""
|
||||
} ]
|
||||
} ],
|
||||
"initComplete": function () {
|
||||
var api = this.api();
|
||||
// Client -> jump to Query Log on click
|
||||
api.$("td:eq(0)").click( function () { openInNewTab("/admin/queries.php?client="+this.innerHTML) });
|
||||
api.$("td:eq(0)").hover(
|
||||
function () { this.title="Click to show queries made by "+this.innerHTML; this.style.color="#72afd2"; },
|
||||
function () { this.style.color=""; }
|
||||
);
|
||||
api.$("td:eq(0)").css("cursor","pointer");
|
||||
}
|
||||
});
|
||||
} );
|
||||
|
||||
|
||||
function openInNewTab(url) {
|
||||
var win = window.open(url, '_blank');
|
||||
win.focus();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user