feat: Probably functional
This commit is contained in:
50
app/templates/transactions.html
Normal file
50
app/templates/transactions.html
Normal file
@@ -0,0 +1,50 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Transactions</title>
|
||||
<link rel="stylesheet" href="{{ url_for('static', filename='style.css') }}">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
|
||||
<h1 class="mb">Transactions</h1>
|
||||
|
||||
<div class="card">
|
||||
|
||||
{% if transactions %}
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Drink</th>
|
||||
<th>User</th>
|
||||
<th>Qty</th>
|
||||
<th>Time</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for t in transactions %}
|
||||
<tr>
|
||||
<td>{{ t.drink_name }}</td>
|
||||
<td>{{ t.user_name }}</td>
|
||||
<td>{{ t.quantity }}</td>
|
||||
<td class="muted">
|
||||
{{ t.timestamp.strftime("%Y-%m-%d %H:%M") }}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% else %}
|
||||
<p>No transactions yet.</p>
|
||||
{% endif %}
|
||||
|
||||
</div>
|
||||
|
||||
<div class="mt">
|
||||
<a class="button button-secondary" href="/">Back</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user