Lagt til html-visning av kategorier og en oversikt over hyller.
This commit is contained in:
14
python/web/templates/category/index.html
Normal file
14
python/web/templates/category/index.html
Normal file
@@ -0,0 +1,14 @@
|
||||
{% extends "base/main.html" %}
|
||||
|
||||
{%block title%}
|
||||
Worblehat 0.1: Kategorier
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<h3>Kategorier:</h3>
|
||||
<ul>
|
||||
{% for category in categories %}
|
||||
<li><a href="/kategori/{{ category.id }}">{{ category }}</a></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endblock %}
|
23
python/web/templates/category/view.html
Normal file
23
python/web/templates/category/view.html
Normal file
@@ -0,0 +1,23 @@
|
||||
{% extends "base/main.html" %}
|
||||
|
||||
{%block title%}
|
||||
Worblehat 0.1: Kategori: {{ category }}
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
{{ category }}<br />
|
||||
|
||||
{% if not book_list %}
|
||||
Det finnes ingen bøker i denne kategorien.
|
||||
{% else %}
|
||||
Følgende bøker finnes i denne kategorien:
|
||||
<ul>
|
||||
{% for book in book_list %}
|
||||
<li><a href="/bok/{{ book.id }}">{{ book }}</a></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
|
||||
{% endblock %}
|
||||
|
15
python/web/templates/map/index.html
Normal file
15
python/web/templates/map/index.html
Normal file
@@ -0,0 +1,15 @@
|
||||
{% extends "base/main.html" %}
|
||||
|
||||
{%block title%}
|
||||
Worblehat 0.1: Fresh, detailed, life-saving maps!
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
Hyller:
|
||||
<ul>
|
||||
{% for shelf_name in shelves %}
|
||||
<li><a href="/kart/{{ shelf_name }}">{{ shelf_name }}</a></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endblock %}
|
||||
|
@@ -1,7 +1,7 @@
|
||||
{% extends "base/main.html" %}
|
||||
|
||||
{%block title%}
|
||||
Worblehat 0.1: Fresh, detailed, life-saving maps!
|
||||
Worblehat 0.1: Hylle {{ shelf_name }}
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
@@ -12,7 +12,7 @@ Worblehat 0.1: Fresh, detailed, life-saving maps!
|
||||
<td>
|
||||
<table>
|
||||
{% for category in column %}
|
||||
<tr><td><a href="/category/{{ category.id }}"> {{ category }} </a></td></tr>
|
||||
<tr><td><a href="/kategori/{{ category.id }}">{{ category }}</a></td></tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
</td>
|
||||
|
Reference in New Issue
Block a user