Co-authored-by: Michael Grote <michael.grote@posteo.de> Reviewed-on: mg/python-api-server#2
49 lines
1 KiB
HTML
49 lines
1 KiB
HTML
<!doctype html>
|
|
<html>
|
|
<head>
|
|
<title>File List</title>
|
|
<style>
|
|
table {
|
|
border-collapse: collapse;
|
|
width: 100%;
|
|
}
|
|
|
|
th, td {
|
|
text-align: left;
|
|
padding: 8px;
|
|
border-bottom: 1px solid #ddd;
|
|
}
|
|
|
|
tr:hover {
|
|
background-color: #f5f5f5;
|
|
}
|
|
|
|
th {
|
|
background-color: #4CAF50;
|
|
color: white;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<h1>File List</h1>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Size (KB)</th>
|
|
<th>Last Modified</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for file in files %}
|
|
<tr>
|
|
<td><a href="{{ url_for('download_file', filename=file.name) }}">{{ file.name }}</a>
|
|
<td>{{ '%.2f' % (file.size / 1024) }} KB</td>
|
|
<td>{{ file.last_modified }}</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</body>
|
|
</html>
|