Parent: [01c20a] (diff)

Child: [b55760] (diff)

Download this file

trovecategories.html    61 lines (54 with data), 1.7 kB

 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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
{% set hide_left_bar = True %}
{% extends g.theme.master %}
{% block title %}Trove categories{% endblock %}
{% block header %}Managing trove categories{% endblock %}
{% block content %}
<div class="grid-20">
{% if selected_cat %}
<div class="grid-20">
<a href="/categories">Top-level categories</a>
{% for cat in hierarchy %}
&gt; <a href="/categories/{{cat.shortname}}">{{cat.fullname}}</a>
{% endfor %}
&gt; {{selected_cat.fullname}}
</div>
<h2>
Sub-categories of {{selected_cat.fullname}}
</h2>
{% else %}
<h2>
List of all top-level categories
</h2>
{% endif %}
{% if categories|length > 0 %}
<table>
<thead>
<tr>
<th>Name</th>
<th>Actions</th>
</tr>
</thead>
<tbody>
{% for cat in categories %}
{{g.theme.remove_trove_category.display(category=cat)}}
{% endfor %}
</tbody>
</table>
{% else %}
<div class="grid-20">
There are no categories in this list.
</div>
{% endif %}
</div>
<div class="grid-20">
<h2>Create a new item in this category</h2>
{% if selected_cat %}
{{g.theme.add_trove_category.display(uppercategory_id=selected_cat.trove_cat_id)}}
{% else %}
{{g.theme.add_trove_category.display(uppercategory_id=0)}}
{% endif %}
<div class="grid-20" style="margin-bottom:10px;">
Are you done creating new categories? <a href="/auth/prefs/user_skills/{{selected_cat.shortname}}">Click here</a> to configure your skills!
</div>
</div>
{% endblock %}