mirror of
https://github.com/FAUSheppy/tmnf-replay-server.git
synced 2025-12-06 07:01:37 +01:00
wip: map info datatables
This commit is contained in:
34
templates/datatable.html
Normal file
34
templates/datatable.html
Normal file
@@ -0,0 +1,34 @@
|
||||
<div style="font-size: 16px; font-weight: 300;" class="mt-5 mb-3 ml-2 mr-2" role="main">
|
||||
<table id="tableMain" class="table table-striped table-bordered table-sm"
|
||||
cellspacing="0">
|
||||
<thead>
|
||||
<tr>
|
||||
{% for item in header_col %}
|
||||
<th class="th-sm font-weighIt-bold">{{ item }}</th>
|
||||
{% endfor %}
|
||||
</tr>
|
||||
</thead>
|
||||
<!-- tbody serverside processing -->
|
||||
</table>
|
||||
<script defer>
|
||||
var dt = null
|
||||
$(document).ready(function () {
|
||||
dt = $('#tableMain').DataTable({
|
||||
serverSide: true,
|
||||
ajax: {
|
||||
url: '/data-source',
|
||||
type: 'POST'
|
||||
},
|
||||
"columnDefs": [
|
||||
{
|
||||
"targets": 3,
|
||||
"render": function ( data, type, full, meta ) {
|
||||
return '<a href=\"/static/'+data+'\" download>Download</a>';
|
||||
}
|
||||
}
|
||||
]
|
||||
});
|
||||
$('.dataTables_length').addClass('bs-select');
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
@@ -1,29 +0,0 @@
|
||||
<head>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||
<meta name="description" content="Image factory providing automatically resized and re-encoded images.">
|
||||
<meta name="author" content="Yannik Schmidt">
|
||||
<meta name="title" content="Image Factory">
|
||||
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="Image Factory" />
|
||||
<meta property="og:description" content="Image Factory developed by Yannik Schmidt" />
|
||||
<meta property="og:url" content="/" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="dev-info">
|
||||
Image Factory for internal use,
|
||||
developed by <a href="https://potaris.de">Yannik Schmidt</a><br>
|
||||
Availiable on
|
||||
<a href="https://github.com/FAUSheppy/python-flask-picture-factory">FAUSheppy GitHub</a>
|
||||
</div>
|
||||
<p>
|
||||
Public Images List:
|
||||
</p>
|
||||
<div class="overview">
|
||||
<p>
|
||||
{% for path in paths %}
|
||||
{{ path }}<br>
|
||||
{% endfor %}
|
||||
</p>
|
||||
</div>
|
||||
</body>
|
||||
31
templates/map-info.html
Normal file
31
templates/map-info.html
Normal file
@@ -0,0 +1,31 @@
|
||||
<head>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||
<meta name="description" content="Image factory providing automatically resized and re-encoded images.">
|
||||
<meta name="author" content="Yannik Schmidt">
|
||||
<meta name="title" content="TM Replays">
|
||||
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="Trackmania Replay Server" />
|
||||
<meta property="og:description" content="TM Replay Server developed by Yannik Schmidt" />
|
||||
<meta property="og:url" content="/" />
|
||||
|
||||
<link rel="shortcut icon" href="/defaultFavicon.ico">
|
||||
|
||||
|
||||
<!-- Bootstrap core JS -->
|
||||
<script src="https://cdn.atlantishq.de/js/jquery.min.js"></script>
|
||||
|
||||
<!-- Bootstrap core CSS -->
|
||||
<link href="https://cdn.atlantishq.de/fontawesome/css/all.css" rel="stylesheet">
|
||||
<link href="https://cdn.atlantishq.de/css/bootstrap.min.css" rel="stylesheet">
|
||||
<script defer src="https://cdn.atlantishq.de/js/bootstrap.min.js"></script>
|
||||
<script defer src="https://cdn.atlantishq.de/js/addons/datatables.min.js"></script>
|
||||
|
||||
<!-- mdb -->
|
||||
<link href="https://cdn.atlantishq.de/css/mdb.min.css" rel="stylesheet">
|
||||
<script defer src="https://cdn.atlantishq.de/js/mdb.min.js"></script>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
{% include "datatable.html" %}
|
||||
</body>
|
||||
Reference in New Issue
Block a user