diff options
Diffstat (limited to 'templates/courts.j2')
| -rw-r--r-- | templates/courts.j2 | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/templates/courts.j2 b/templates/courts.j2 index 64fd44a..d650298 100644 --- a/templates/courts.j2 +++ b/templates/courts.j2 @@ -1,9 +1,8 @@ +{% from "macros.j2" import court %} <div class="fixed-grid has-12-cols"> <div class="grid"> -{% for court in courts %} - <div class="cell"> - <button class={% if court.status %} "button is-success" {% else %} "button is-danger" {% endif %} hx-post="{{ "/court-toggle/" ~ court.number}}" hx-trigger="click" hx-swap="outerHTML">{{ court.number }}</button> - </div> +{% for key, value in courts.items() %} + {{ court(key, value) }} {% endfor %} </div> </div>
\ No newline at end of file |
