summaryrefslogtreecommitdiff
path: root/jimbrella/templates/admin/umbrellas.html
blob: 56a5dde7f862d91b10d8132ceeeeb338bb6d6fef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
<!DOCTYPE html>
<html>
    <head>
        <title>JI Umbrella</title>
        <link rel="stylesheet" href="/static/jimbrella.css" />
        <meta name="viewport" content="width=device-width, initial-scale=1" />
    </head>
    <body>
        <h1>All Umbrellas</h1>
        <div id="container">
            {% include "admin/tabs.html" %}
            <div class="data-table-container">
                <table class="data">
                    <thead>
                        <tr>
                            <th>#</th>
                            <th>Status</th>
                            <th>Tenant</th>
                            <th>ID</th>
                            <th>Phone</th>
                            <th colspan=2>Lent at</th>
                        </tr>
                    </thead>
                    <tbody>
                        {% for umb in umbrellas %}
                        <tr class="{{ umb.status }}">
                            <td>{{ umb.serial }}</td>
                            <td>{{ umb.status }}</td>
                            <td>{{ umb.tenant_name }}</td>
                            <td>{{ umb.tenant_id }}</td>
                            <td>{{ umb.tenant_phone }}</td>
                            <td>{{ umb.lent_at_str }}</td>
                            <td>{{ umb.lent_time_ago_str }}
                                {% if umb.status in ["lent", "overdue"] %} ago {% endif %}
                            </td>
                        </tr>
                        {% endfor %}
                    </tbody>
                </table>
            </div>
        </div>
    </body>
</html>