commit d076ae55db1b90702a04d57227047406acd9954d
parent 07596501fc3836d643c52d16ca9e50500f236c9c
Author: Florian <flokX@users.noreply.github.com>
Date: Fri, 25 Jan 2019 17:45:01 +0100
Add to new admin panel
Diffstat:
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/admin/main.min.js b/admin/main.min.js
@@ -0,0 +1 @@
+function getRandomColor(){"use strict";for(var t="#",e=0;e<6;e++)t+="0123456789ABCDEF"[Math.floor(16*Math.random())];return t}var ctx=document.getElementById("chart").getContext("2d");$.getJSON("stats.json",function(t){"use strict";var e=[];$.each(t,function(t,a){var o=[],n=getRandomColor();$.each(a,function(t,e){o.push({x:t,y:e})}),e.push({label:t,backgroundColor:n,borderColor:n,data:o,fill:!1})});new Chart(ctx,{type:"line",data:{datasets:e},options:{responsive:!0,scales:{xAxes:[{type:"time",scaleLabel:{display:!0,labelString:"Date"}}],yAxes:[{ticks:{min:0},scaleLabel:{display:!0,labelString:"Request number"}}]}}})});
diff --git a/secure/main.min.js b/secure/main.min.js
@@ -1 +0,0 @@
-function getRandomColor(){"use strict";for(var t="#",e=0;e<6;e++)t+="0123456789ABCDEF"[Math.floor(16*Math.random())];return t}var ctx=document.getElementById("chart").getContext("2d");$.getJSON("stats.json",function(t){"use strict";var e=[];$.each(t,function(t,a){var o=[],n=getRandomColor();$.each(a,function(t,e){o.push({x:t,y:e})}),e.push({label:t,backgroundColor:n,borderColor:n,data:o,fill:!1})});new Chart(ctx,{type:"line",data:{datasets:e},options:{responsive:!0,scales:{xAxes:[{type:"time",scaleLabel:{display:!0,labelString:"Date"}}],yAxes:[{ticks:{min:0},scaleLabel:{display:!0,labelString:"Request number"}}]}}})});
-\ No newline at end of file