Tingy
This commit is contained in:
@@ -1,15 +1,59 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Vinlottis</title>
|
||||
<link href="https://fonts.googleapis.com/css?family=Roboto&display=swap" rel="stylesheet">
|
||||
</head>
|
||||
<body>
|
||||
<h1>Official vin lottis homepage</h1>
|
||||
</body>
|
||||
<head>
|
||||
<title>Vinlottis</title>
|
||||
<link
|
||||
href="https://fonts.googleapis.com/css?family=Roboto&display=swap"
|
||||
rel="stylesheet"
|
||||
/>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Official vin lottis homepage</h1>
|
||||
<code id="purchase"></code>
|
||||
<code id="wines"></code>
|
||||
<code id="colors"></code>
|
||||
<code id="highscores"></code>
|
||||
|
||||
<style>
|
||||
body {
|
||||
font-family: 'Roboto', sans-serif;
|
||||
}
|
||||
</style>
|
||||
<script>
|
||||
(async function() {
|
||||
var _purchase = await fetch("/api/purchase/statistics");
|
||||
var purchase = await _purchase.json();
|
||||
|
||||
var _wines = await fetch("/api/wines/statistics");
|
||||
var wines = await _wines.json();
|
||||
|
||||
var _colors = await fetch("/api/purchase/statistics/color");
|
||||
var color = await _colors.json();
|
||||
|
||||
var _highscores = await fetch("/api/highscore/statistics");
|
||||
var highscore = await _highscores.json();
|
||||
|
||||
document.getElementById("purchase").innerHTML = JSON.stringify(
|
||||
purchase,
|
||||
null,
|
||||
2
|
||||
);
|
||||
document.getElementById("wines").innerHTML = JSON.stringify(
|
||||
wines,
|
||||
null,
|
||||
2
|
||||
);
|
||||
document.getElementById("colors").innerHTML = JSON.stringify(
|
||||
color,
|
||||
null,
|
||||
2
|
||||
);
|
||||
document.getElementById("highscores").innerHTML = JSON.stringify(
|
||||
highscore,
|
||||
null,
|
||||
2
|
||||
);
|
||||
})();
|
||||
</script>
|
||||
</body>
|
||||
|
||||
<style>
|
||||
body {
|
||||
font-family: "Roboto", sans-serif;
|
||||
}
|
||||
</style>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user