article.html 3.06 KB
Newer Older
Jérôme Ortais's avatar
Jérôme Ortais committed
1
{% extends "base.html" %}
2 3

{% block title %}{{ article.title }}{% endblock %}
Jérôme Ortais's avatar
Jérôme Ortais committed
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
{% block head %}
{{ super() }}
{% if article.description %}
<meta name="description" content="{{article.description}}"/>
{% endif %}
{% for tag in article.tags %}
<meta name="tags" content="{{tag}}"/>
{% endfor %}
{% endblock %}

{% import 'translations.html' as translations with context %}
{{ translations.translations_for(page) }}
{% block content %}
<div id="deux_cols">
  <div id="col_droite">
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 61 62 63 64 65 66 67 68 69 70
    <div class="margin-check">
      {% if article.category == "telecharger" %}
      <h3>Historique des versions</h3>
      <ul class="docs">
        {% for cat_name, article_list in categories if cat_name=="telecharger" %}
        {% for article in article_list %}
        <li>
          <a href="{{ SITEURL }}/{{ article.slug }}.html">{{ article.title }}</a>
        </li>
        {% endfor %}
        {% endfor %}
      </ul>
      {% else %}
      {% if article.category == "finances" %}
      <h3>Bilan financier</h3>
      Un immense merci à celles et ceux qui ont contribué financièrement à la vie de
      Pyromaths. Vous trouverez ici l'état de nos finances.
      <form action="https://www.paypal.com/cgi-bin/webscr"
            method="post">
        <p>
          <input type="hidden" name="cmd" value="_s-xclick"/>
          <input type="hidden" name="hosted_button_id" value="5486963"/>
          <input type="image"
                 src="https://www.paypal.com/fr_FR/FR/i/btn/btn_donate_SM.gif"
                 name="submit" alt="PayPal"/>
          <img alt="logo Paypal"
               src="https://www.paypal.com/fr_FR/i/scr/pixel.gif"/>
        </p>
      </form>
      {% else %}
      <h3>Documentation</h3>
      {% for cat_name, article_list in categories if cat_name!="telecharger" and cat_name != "finances"%}
      <ul>
        {% for group in article_list|groupby('category') %}
        {% for article in group.list %}
        {% if loop.first %}
        <li>
          <h4>{{ article.category }}</h4>
          <ul class="docs">
            {% endif %}
            {% if 'hidden' not in article.tags %}
            <li>
              <a href="{{ SITEURL }}/{{ article.slug }}.html">{{ article.title }}</a>
            </li>
            {% endif %}
            {% if loop.last %}
          </ul>
        </li>
        {% endif %}
        {% endfor %}
        {% endfor %}
      </ul>
Jérôme Ortais's avatar
Jérôme Ortais committed
71 72
      {% endfor %}
      {% endif %}
73 74
      {% endif %}
    </div>
Jérôme Ortais's avatar
Jérôme Ortais committed
75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100
  </div>
  <div id="col_gauche">
    <div class="article">
      <h5> Par
        {% for author in article.authors %}
        {{ author }},
        {% endfor %}
        {% if article.modified %}
        <time class="modified" datetime="{{ article.modified.isoformat() }}">
          mis à jour le {{ article.locale_modified }}
        </time>
        {% else %}
        le
        <time class="published" datetime="{{ article.date.isoformat() }}">
          {{ article.locale_date }}
        </time>
        {% endif %}
      </h5>

      <h1>{{ article.title }}</h1>

      {{ article.content }}

    </div>
  </div>
</div>
101 102
<div class="clear">&nbsp;</div>

Jérôme Ortais's avatar
Jérôme Ortais committed
103
{% endblock %}