* Split off the detail and list templates into a normal one that generates a full...
[matthijs/projects/xerxes.git] / templates / influences / index.html
index ccd2da9d670e14cd9a94b731db078011279b0028..02596e1550cdc9801760bcaedb4354159b051cc3 100644 (file)
@@ -1,33 +1,15 @@
 {% extends "base/base.html" %}
-{% load i18n %}
 
 {% block content %}
 
-<h1>{% trans "Your characters"%}</h1>
-{% if characters %}
-       <ul>
-       {% for character in characters %}
-               <li><a href="{% url influences_character_detail character.id %}">{{ character.name }}</a></li>
-       {% endfor %}
-       </ul>
-{% else %}
-       <p>{% trans "No characters. Add a character first, so you can submit your influences." %}</p>
-{% endif %}
-
-<p><a href="{% url influences_add_character %}">{% trans "Add character" %}</a></p>
+{% with characters as object_list %}
+{% include "influences/character_list_block.html" %}
+{% endwith %}
 
 {% if characters %}
-<h1>{% trans "Your influences" %}</h1>
-{% if influences %}
-       <ul>
-       {% for influence in influences %}
-        <li><a href="{% url influences_influence_detail influence.id %}">{{influence.contact }} -- {{ influence.summary }}</a></li>
-       {% endfor %}
-       </ul>
-{% else %}
-       <p>{% trans "No influences yet." %}</p>
+{% with influences as object_list %}
+{% include "influences/influence_list_block.html" %}
+{% endwith %}
 {% endif %}
 
-<p><a href="{% url influences_add_influence %}">{% trans "Submit influence" %}</a></p>
-{% endif %}
 {% endblock %}