forked from rc/aircox
62 lines
1.6 KiB
HTML
62 lines
1.6 KiB
HTML
{% extends "aircox_cms/base_site.html" %}
|
|
{# generic page to display list of articles #}
|
|
|
|
{% load i18n %}
|
|
{% load wagtailcore_tags %}
|
|
{% load wagtailimages_tags %}
|
|
|
|
|
|
{% block title %}
|
|
<h1>
|
|
{# Translators: titles for the page that shows a list of elements. #}
|
|
{# Translators: terms are search terms, or tag tarms. url: url to the page #}
|
|
{% if page.list_from_request %}
|
|
{% with terms=list_selector.terms %}
|
|
{% if terms %}
|
|
{% blocktrans %}Search in publications for <i>{{ terms }}</i>{% endblocktrans %}
|
|
{% elif list_selector.filter_related %}
|
|
{# should never happen #}
|
|
{% with title=list_selector.filter_related.title url=list_selector.filter_related.url %}
|
|
{% blocktrans %}
|
|
Related to <a href="{{ url }}">{{ title }}</a>{% endblocktrans %}
|
|
{% endwith %}
|
|
{% else %}
|
|
{% blocktrans %}All the publications{% endblocktrans %}
|
|
{% endif %}
|
|
{% endwith %}
|
|
{% else %}
|
|
{{ page.title }}
|
|
{% endif %}
|
|
</h1>
|
|
{% endblock %}
|
|
|
|
|
|
{% block content %}
|
|
{% if page.list_from_request %}
|
|
{% with related=list_selector.filter_related %}
|
|
{% if related %}
|
|
<div class="body summary">
|
|
{% image related.cover fill-128x128 class="cover item_cover" %}
|
|
{{ related.summary }}
|
|
<a href="{{ related.url }}">{% trans "More about it" %}</a>
|
|
</div>
|
|
{% elif page.body %}
|
|
<div class="body">
|
|
{{ page.body|richtext }}
|
|
</div>
|
|
{% endif %}
|
|
{% endwith %}
|
|
|
|
{% with list_paginator=paginator %}
|
|
{% include "aircox_cms/snippets/list.html" %}
|
|
{% endwith %}
|
|
{% else %}
|
|
<div class="body">
|
|
{{ page.body|richtext }}
|
|
</div>
|
|
{% endif %}
|
|
{% endblock %}
|
|
|
|
|
|
|