butter-portal/app/templates/usb-file-viewer.html

39 lines
976 B
HTML
Raw Normal View History

2026-02-17 13:52:59 +00:00
{% extends "base.html" %}
{% block content %}
<h1 class="title is-large butter-title">{{ _('File Viewer') }}</h1>
2026-02-17 13:52:59 +00:00
<div>
<table class="table" style="margin: 0 auto">
2026-02-17 13:52:59 +00:00
<thead>
<tr>
<th></th>
<th>File Name</th>
<th class="file-viewer-date-modified">Date modified</th>
2026-02-17 13:52:59 +00:00
<th>Download</th>
</tr>
</thead>
<tbody>
{% for f in render_files %}
<tr>
<td><img src="{{ f.icon_url}}"></td>
{% if f.is_dir %}
<td><a href=".{{ f.relative_path}}">{{ f.name}}</a></td>
{% endif %}
{% if f.is_file %}
<td>{{ f.name}}</td>
{% endif %}
<td class="file-viewer-date-modified">{{ f.last_modified}}</td>
2026-02-17 13:52:59 +00:00
{% if f.is_file %}
<td><a href="{{ url_for('serve_file', filepath=f.path) }}">Download</a></td>
{% endif %}
{% if f.is_dir %}
<td></td>
{% endif %}
</tr>
{% endfor %}
</tbody>
</table>
{% endblock %}