Fix merge conflict

Signed-off-by: Adam Warner <adamw@rner.email>
This commit is contained in:
Adam Warner
2018-04-14 00:43:27 +01:00
9 changed files with 316 additions and 83 deletions
+36 -4
View File
@@ -255,6 +255,23 @@ function updateQueryTypesPie() {
queryTypePieChart.update();
// Don't use rotation animation for further updates
queryTypePieChart.options.animation.duration=0;
// Generate legend in separate div
$("#query-types-legend").html(queryTypePieChart.generateLegend());
$("#query-types-legend > ul > li").on("click",function(e){
$(this).toggleClass("strike");
var index = $(this).index();
var ci = e.view.queryTypePieChart;
var meta = ci.data.datasets[0]._meta;
for(let i in meta)
{
if ({}.hasOwnProperty.call(meta, i))
{
var curr = meta[i].data[index];
curr.hidden = !curr.hidden;
}
}
ci.update();
});
}).done(function() {
// Reload graph after minute
setTimeout(updateQueryTypesPie, 60000);
@@ -469,6 +486,23 @@ function updateForwardDestinationsPie() {
forwardDestinationPieChart.update();
// Don't use rotation animation for further updates
forwardDestinationPieChart.options.animation.duration=0;
// Generate legend in separate div
$("#forward-destinations-legend").html(forwardDestinationPieChart.generateLegend());
$("#forward-destinations-legend > ul > li").on("click",function(e){
$(this).toggleClass("strike");
var index = $(this).index();
var ci = e.view.forwardDestinationPieChart;
var meta = ci.data.datasets[0]._meta;
for(let i in meta)
{
if ({}.hasOwnProperty.call(meta, i))
{
var curr = meta[i].data[index];
curr.hidden = !curr.hidden;
}
}
ci.update();
});
}).done(function() {
// Reload graph after one minute
setTimeout(updateForwardDestinationsPie, 60000);
@@ -1041,8 +1075,7 @@ $(document).ready(function() {
},
options: {
legend: {
display: true,
position: "right"
display: false
},
tooltips: {
enabled: true,
@@ -1079,8 +1112,7 @@ $(document).ready(function() {
},
options: {
legend: {
display: true,
position: "right"
display: false
},
tooltips: {
enabled: true,
+3 -4
View File
@@ -82,7 +82,7 @@ function add(domain,list) {
}
});
});
// Reset Modal after it has faded out
alertModal.one("hidden.bs.modal", function() {
alProcessing.show();
@@ -136,11 +136,10 @@ $(document).ready(function() {
{
APIstring += "&domain="+GETDict["domain"];
}
// If we don't ask filtering and also not for all queries, just request the most recent 100 queries
else if(!("all" in GETDict))
{
var timestamp = Math.floor(Date.now() / 1000);
APIstring += "&from="+(timestamp - 600);
APIstring += "&until="+(timestamp + 100);
APIstring += "=100";
}
tableApi = $("#all-queries").DataTable( {
+2 -1
View File
@@ -123,7 +123,8 @@ function isinserverlist($addr) {
"Norton" => ["v4_1" => "199.85.126.10", "v4_2" => "199.85.127.10"],
"Comodo" => ["v4_1" => "8.26.56.26", "v4_2" => "8.20.247.20"],
"DNS.WATCH" => ["v4_1" => "84.200.69.80", "v4_2" => "84.200.70.40", "v6_1" => "2001:1608:10:25:0:0:1c04:b12f", "v6_2" => "2001:1608:10:25:0:0:9249:d69b"],
"Quad9" => ["v4_1" => "9.9.9.9", "v4_2" => "149.112.112.112", "v6_1" => "2620:fe::fe"]
"Quad9" => ["v4_1" => "9.9.9.9", "v4_2" => "149.112.112.112", "v6_1" => "2620:fe::fe"],
"Cloudflare" => ["v4_1" => "1.1.1.1", "v4_2" => "1.0.0.1", "v6_1" => "2606:4700:4700::1111", "v6_2" => "2606:4700:4700::1001"]
];
$adlist = [];