Some layout experiments.
[wolnelektury.git] / apps / funding / templates / funding / offer_detail.html
index 638431f..f3484ed 100755 (executable)
@@ -2,6 +2,7 @@
 {% load url from future %}
 {% load i18n %}
 {% load funding_tags %}
+{% load pagination_tags %}
 
 
 {% block titleextra %}{{ object }}{% endblock %}
 {% block body %}
 
 <h1>{{ object }}</h1>
-<div class="white-box">
 
-    {% funding object %}
-    {% offer_detail_head object %}
+<div class="normal-text">{{ object.description|safe }}</div>
 
-    {% if object.state == 'running' %}
+{% funding object %}
+<div class="white-box">
+    {% offer_status object %}
+    {% offer_status_more object %}
 
+    {% if object.is_current %}
         <div class="normal-text">
-
-            <h3>{% trans "Support" %}</h3>
+            <h3>{% trans "Support the publication" %}</h3>
             <form action="" method="post">
                 {% csrf_token %}
                 <table>
                 {{ form.as_table }}
-                <tr><td></td><td><button class="honking" type="submit">Wpłać!</button></td></tr>
+                <tr><td></td><td><button class="honking" type="submit">{% trans "Donate!" %}</button></td></tr>
                 </table>
             </form>
-
         </div>
     {% endif %}
 
-    <div class="normal-text">{{ object.description|safe }}</div>
-
-    <p class="normal-text"><a href="{% url 'funding' %}">Zobacz wszystkie zbiórki.</a></p>
+    <p class="normal-text"><a href="{% url 'funding' %}">{% trans "See all fundraisers." %}</a></p>
 
 </div>
 
 <h2>{% trans "Supporters" %}:</h2>
 
 <div class="white-box normal-text">
+{% with object.funding_payed.all as fundings %}
     
     <table class="wlfund">
-    {% for funding in object.funding_payed.all %}
+    {% autopaginate fundings 10 %}
+    {% for funding in fundings %}
         <tr class="funding-plus">
             <td><div>{{ funding.payed_at.date }}</div></td>
             <td><div>
@@ -53,7 +54,7 @@
                     <em>{% trans "Anonymous" %}</em>
                 {% endif %}
             </div></td>
-            <td><div>+{{ funding.amount }} zł</div></td>
+            <td><div>{{ funding.amount }} zł</div></td>
             <td><div>
                 {% for perk in funding.perks.all %}
                     {{ perk.name }}{% if not forloop.last %},{% endif %}
@@ -61,7 +62,9 @@
             </div></td>
     {% endfor %}
     </table>
-
+    
+    {% paginate %}
+{% endwith %}
 </div>
 
 {% endblock %}