Spaces:
Sleeping
Sleeping
Upload data_files.html
Browse files- templates/data_files.html +42 -0
templates/data_files.html
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<!DOCTYPE html>
|
| 2 |
+
<html lang="en">
|
| 3 |
+
<head>
|
| 4 |
+
<meta charset="UTF-8">
|
| 5 |
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>Data Files</title>
|
| 7 |
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css">
|
| 8 |
+
</head>
|
| 9 |
+
<body class="bg-dark text-white">
|
| 10 |
+
|
| 11 |
+
<div class="container mt-5">
|
| 12 |
+
<h1 class="text-center">Upload or Overwrite Data Files</h1>
|
| 13 |
+
|
| 14 |
+
<!-- Upload Form -->
|
| 15 |
+
<form action="{{ url_for('upload_data_file') }}" method="POST" enctype="multipart/form-data" class="mt-4">
|
| 16 |
+
<div class="mb-3">
|
| 17 |
+
<input type="file" name="file" class="form-control" required>
|
| 18 |
+
</div>
|
| 19 |
+
<button type="submit" class="btn btn-success">Upload</button>
|
| 20 |
+
</form>
|
| 21 |
+
|
| 22 |
+
<hr>
|
| 23 |
+
|
| 24 |
+
<h2 class="mt-5">Uploaded Data Files</h2>
|
| 25 |
+
|
| 26 |
+
<!-- List of Uploaded Files -->
|
| 27 |
+
<ul class="list-group mt-3">
|
| 28 |
+
{% if files %}
|
| 29 |
+
{% for file in files %}
|
| 30 |
+
<li class="list-group-item d-flex justify-content-between align-items-center bg-secondary text-white">
|
| 31 |
+
{{ file }}
|
| 32 |
+
<a href="{{ url_for('download_files', filename=file) }}" class="btn btn-sm btn-primary">Download</a>
|
| 33 |
+
</li>
|
| 34 |
+
{% endfor %}
|
| 35 |
+
{% else %}
|
| 36 |
+
<li class="list-group-item bg-secondary text-white">No files found.</li>
|
| 37 |
+
{% endif %}
|
| 38 |
+
</ul>
|
| 39 |
+
</div>
|
| 40 |
+
|
| 41 |
+
</body>
|
| 42 |
+
</html>
|