diff --git a/scripts/pi-hole/js/queries.js b/scripts/pi-hole/js/queries.js index 39a854ff..46952bef 100644 --- a/scripts/pi-hole/js/queries.js +++ b/scripts/pi-hole/js/queries.js @@ -283,17 +283,16 @@ function formatInfo(data) { ""; } - var regexInfo = "", + var listInfo = "", cnameInfo = ""; - if (data.regex_id !== null && data.regex_id > -1) { - var regexLink = - 'entry with ID ' + - data.regex_id + - ""; - regexInfo = - divStart + "Query was " + queryStatus.matchText + " by " + regexLink + ""; + if (data.list_id !== null && data.list_id !== -1) { + // Some list matched - add link to search page + + var listLink = + 'search lists'; + listInfo = divStart + "Query was " + queryStatus.matchText + ", " + listLink + ""; } if (queryStatus.isCNAME) { @@ -356,7 +355,7 @@ function formatInfo(data) { dnssecInfo + statusInfo + cnameInfo + - regexInfo + + listInfo + ttlInfo + replyInfo + dbInfo + diff --git a/scripts/pi-hole/js/search.js b/scripts/pi-hole/js/search.js index 26875241..dae432ec 100644 --- a/scripts/pi-hole/js/search.js +++ b/scripts/pi-hole/js/search.js @@ -6,6 +6,18 @@ * Please see LICENSE file for your rights under this license. */ /* global utils:false, apiFailure:false */ +var GETDict = {}; + +$(function () { + GETDict = utils.parseQueryString(); + if (GETDict.domain !== undefined) { + $("input[id^='domain']").val(GETDict.domain); + } + + if (GETDict.N !== undefined) { + $("#number").val(GETDict.number); + } +}); function eventsource(partial) { const ta = $("#output"); diff --git a/style/pi-hole.css b/style/pi-hole.css index c60ed9bc..4be5c580 100644 --- a/style/pi-hole.css +++ b/style/pi-hole.css @@ -1075,12 +1075,15 @@ table.dataTable tbody > tr > .selected { #output { position: relative; - display: grid; margin: 5px 0; min-height: 36px; padding: 4px 8px; } +#output.pre-taillog { + display: grid; +} + .loading::before { content: " "; position: absolute; diff --git a/taillog.lp b/taillog.lp index 0514ccc6..4d0aa487 100644 --- a/taillog.lp +++ b/taillog.lp @@ -25,7 +25,7 @@ mg.include('scripts/pi-hole/lua/header_authenticated.lp','r')
-

+