Files
boker/templates/sessions.html
T
2026-06-22 14:17:10 -07:00

55 lines
2.0 KiB
HTML

{% extends "base.html" %}
{% block title %}Sessions · myboker.org{% endblock %}
{% block content %}
<div class="hero">
<p class="hero__kicker">Session history</p>
<h1 class="hero__title">Sessions</h1>
<p class="hero__sub">Browse every recorded game night and inspect table totals.</p>
</div>
<div class="panel">
<div class="panel__head">
<div>
<span class="kicker" style="margin:0;">Archive</span>
<h2 class="panel__title">All sessions</h2>
</div>
</div>
<div class="tbl-scroll">
<table class="tbl" style="min-width:600px;">
<thead>
<tr>
<th class="col-left">Date</th>
<th>Status</th>
<th>Players</th>
<th>Invested</th>
<th>Gross cashout</th>
<th>Table net</th>
</tr>
</thead>
<tbody>
{% for s in sessions %}
<tr onclick="window.location='{{ url_for('public.session_detail', session_id=s.session_id) }}'">
<td class="col-left">
<a href="{{ url_for('public.session_detail', session_id=s.session_id) }}">{{ session_label(s) }}</a>
</td>
<td><span class="badge badge--{{ s.status }}">{{ s.status }}</span></td>
<td>{{ s.entries|length }}</td>
<td>{{ s.total_invested_cents | money }}</td>
<td>{{ s.total_cash_out_cents | money }}</td>
<td class="{{ 'num-pos' if s.total_net_cents > 0 else 'num-neg' if s.total_net_cents < 0 else '' }}">
{{ s.total_net_cents | money }}
</td>
</tr>
{% else %}
<tr>
<td colspan="6" style="text-align:left;padding:28px;color:var(--muted);">No sessions yet.</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>
{% endblock %}