diff options
author | Frederick Yin <fkfd@fkfd.me> | 2022-02-02 11:16:44 +0800 |
---|---|---|
committer | Frederick Yin <fkfd@fkfd.me> | 2022-02-02 11:16:44 +0800 |
commit | 2a5c95261c71d9c30d53053e2d0cd1c1282f6b1c (patch) | |
tree | 6f267175715b980f77ba18aa5c741d6478fc2e9a /jimbrella/templates/admin/umbrellas_mobile.html | |
parent | 357cc3d8d9f2b02e60f0763f4701bd614b876436 (diff) |
Adapt jinja templates
Diffstat (limited to 'jimbrella/templates/admin/umbrellas_mobile.html')
-rw-r--r-- | jimbrella/templates/admin/umbrellas_mobile.html | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/jimbrella/templates/admin/umbrellas_mobile.html b/jimbrella/templates/admin/umbrellas_mobile.html index 3c63418..705722f 100644 --- a/jimbrella/templates/admin/umbrellas_mobile.html +++ b/jimbrella/templates/admin/umbrellas_mobile.html @@ -3,12 +3,12 @@ <div class="data-table-container"> <table class="data"> {% for umb in umbrellas %} - {% if umb.serial == edit %} + {% if umb.id == edit %} <form method="post" action="/admin/umbrellas/edit"> - <input name="serial" type="number" value="{{ umb.serial }}" hidden /> - <tr id="{{ umb.serial }}" class="{{ umb.status }}"> + <input name="id" type="number" value="{{ umb.id }}" hidden /> + <tr id="{{ umb.id }}" class="{{ umb.status }}"> <th rowspan=5> - {{ umb.serial }} <br /> + {{ umb.id }} <br /> {{ status_dropdown(umb) }} <br /> <input type="submit" value="Submit" /> </th> @@ -31,11 +31,11 @@ {% else %} {# not edit mode #} {% if umb.status in ["lent", "overdue"] %} - <tr id="{{ umb.serial }}" class="{{ umb.status }}"> + <tr id="{{ umb.id }}" class="{{ umb.status }}"> <th rowspan=5> - {{ umb.serial }} <br /> + {{ umb.id }} <br /> {{ umb.status }} <br /> - <a href="/admin/umbrellas?edit={{ umb.serial }}">Edit</a> + <a href="/admin/umbrellas?edit={{ umb.id }}">Edit</a> </th> <td>{{ umb.tenant_name }}</td> </tr> @@ -47,11 +47,11 @@ {% if umb.status in ["lent", "overdue"] %} ago {% endif %} </td></tr> {% else %} - <tr id="{{ umb.serial }}" class="{{ umb.status }}"> + <tr id="{{ umb.id }}" class="{{ umb.status }}"> <th colspan=2> - {{ umb.serial }} <br /> + {{ umb.id }} <br /> {{ umb.status }} <br /> - <a href="/admin/umbrellas?edit={{ umb.serial }}#{{ umb.serial }}">Edit</a> + <a href="/admin/umbrellas?edit={{ umb.id }}#{{ umb.id }}">Edit</a> </th> </tr> {% endif %} |