src/egonomy/templates/egonomy_all_fragments.html
author ymh <ymh.work@gmail.com>
Mon, 11 Feb 2013 14:10:22 +0100
changeset 31 29caac899e1f
parent 27 daaafc916dc4
child 30 a96a795aa08f
permissions -rw-r--r--
improve default logging + virtualenv creation
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
27
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     1
{% extends "egonomy_base.html" %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     2
{% load static %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     3
{% load i18n %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     4
{% load thumbnail %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     5
{% load navigation %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     6
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     7
{% block title %}{% trans "All fragments" %}{% endblock %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     8
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
     9
{% block content %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    10
                <div class="fullwidth">
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    11
                    <div class="fullwidth">
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    12
                        <h2>{% trans "All fragments" %}</h2>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    13
						{% if nb_pages %}<p>{% build_pagination nb_pages cur_page_nb "all_fragments" "contents_page clickable" %}</p>{% endif %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    14
                        <ul class="fullwidth">
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    15
                          {% for frg in results %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    16
                            <li class="subcol_all">
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    17
                              <a href="{% url 'view_fragment' fragment_pk=prg.pk %}">
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    18
                              <div class="center-image">
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    19
                                <div class="image-and-fragment">
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    20
                                 {% with frg.image.info.image_file as image %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    21
                                 {% if image %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    22
                                  {% if image|is_portrait %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    23
							 	    {% thumbnail image "x110" format="PNG" crop="center" as im %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    24
	                                  <img src="{{ im.url }}" width="{{ im.width }}" height="{{ im.height }}"/>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    25
	                                {% empty %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    26
	                                  <img src="{% static 'egonomy/img/empty.gif' %}" width="110" height="110" class="placeholder" />
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    27
	                                {% endthumbnail %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    28
	                              {% else %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    29
                                    {% thumbnail image "110" format="PNG" crop="center" as im %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    30
                                      <img src="{{ im.url }}" width="{{ im.width }}" height="{{ im.height }}"/>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    31
                                    {% empty %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    32
                                      <img src="{% static 'egonomy/img/empty.gif' %}" width=110" height="110" class="placeholder" />
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    33
                                    {% endthumbnail %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    34
	                              {% endif %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    35
	                             {% else %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    36
	                                  <img src="{% static 'egonomy/img/empty.gif' %}" width=110" height="110" class="placeholder" />
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    37
	                             {% endif %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    38
	                             {% endwith %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    39
	                                  <svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewbox="0 0 1 1" preserveAspectRatio="none">
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    40
                                        <path d="{{ frg.coordinates }}" stroke="red" stroke-width=".02" fill="red" fill-opacity=".3" />
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    41
                                      </svg>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    42
                                </div>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    43
                             </div>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    44
                             <h3>{{ frg.title }}</h3></a>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    45
                             <p>{% trans "Annotated by" %} <strong>{{ frg.author }}</strong></p>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    46
                            </li>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    47
                          {% endfor %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    48
                        </ul>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    49
                        {% if nb_pages %}<p>{% build_pagination nb_pages cur_page_nb "all_fragments" "contents_page clickable" %}</p>{% endif %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    50
                    </div>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    51
                </div>
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    52
{% endblock %}
daaafc916dc4 Debug in templates. All fragments page added. Language files updated.
cavaliet
parents:
diff changeset
    53