public: quick refactor
This commit is contained in:
@@ -2,15 +2,15 @@
|
||||
|
||||
{% block content %}
|
||||
<div class="container">
|
||||
<h6>Please <a href="/login">log in</a> to see more details</h6>
|
||||
{% include "inventory_filter.html" %}
|
||||
|
||||
<p><a class="waves-effect waves-light btn" href="/login?redirect_url={{ redirect_url }}">Log in</a> to see more items</p>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Slug</th>
|
||||
<th>Name</th>
|
||||
<th>Type</th>
|
||||
<th>In use</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -24,10 +24,11 @@
|
||||
</td>
|
||||
<td><a href="/m/inventory/{{ item._id }}/view">{{ item | format_name }} {{ item.comment }}</a></td>
|
||||
<td>{{ item.type }}</td>
|
||||
<td>{% if item.inventory.user %}<i class="material-icons">check_circle</i>{% endif %}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<p><a class="waves-effect waves-light btn" href="/login?redirect_url={{ redirect_url }}">Log in</a> to see more items</p>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
@@ -1,8 +1,9 @@
|
||||
{% extends 'base.html' %}
|
||||
{% block content %}
|
||||
<div class="container">
|
||||
<h6>Please <a href="/login?redirect_url={{ redirect_url }}">log in</a> to see more details</h6>
|
||||
<p>Inventory item.</p>
|
||||
<title>{% if item.get("shortener").slug %}/{{ item.get("shortener").slug }}{% else %}k6{% endif %}: {{ item.name }}</title>
|
||||
|
||||
<p><a class="waves-effect waves-light btn" href="/login?redirect_url={{ redirect_url }}">Log in</a> to see more details</p>
|
||||
|
||||
<table>
|
||||
<thead>
|
||||
@@ -12,12 +13,17 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
<tr>
|
||||
<td>Type</td>
|
||||
<td>{{ item["type"] }}</td>
|
||||
<td>Sticker</td>
|
||||
<td>
|
||||
{% if item.get("shortener").slug %}
|
||||
{{ item.get("shortener", {}).get("slug") | qr_code }}
|
||||
<a href="http://k6.ee/{{ item.get("shortener").slug }}">
|
||||
k6.ee/{{ item.get("shortener").slug }}
|
||||
</a>
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Vendor</td>
|
||||
<td>{{ item.get("hardware").vendor }}</td>
|
||||
@@ -32,30 +38,14 @@
|
||||
<td>Name</td>
|
||||
<td>{{ item.name }}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>Sticker</td>
|
||||
<td>
|
||||
{% if item.get("shortener").slug %}
|
||||
<a href="http://k6.ee/{{ item.get("shortener").slug }}">
|
||||
k6.ee/{{ item.get("shortener").slug }}
|
||||
</a>
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="tooltip" data-tooltip="Unauthenticated user can see this in public list">In use</td>
|
||||
<td>{% if item.inventory.user %}<i class="material-icons">check_circle</i>{% endif %}</td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<p><a class="waves-effect waves-light btn" href="/login?redirect_url={{ redirect_url }}">Log in</a> to see more details</p>
|
||||
|
||||
<h3>Photo</h3>
|
||||
{% if item.has_photo %}
|
||||
<img src="{{ photo_url }}" alt="" style="max-width: 800px; width: 100%;">
|
||||
{% endif %}
|
||||
|
||||
{% endblock %}
|
||||
|
||||
|
Reference in New Issue
Block a user