forked from rc/aircox
57 lines
1.8 KiB
HTML
57 lines
1.8 KiB
HTML
{% load i18n easy_thumbnails_tags aircox_web %}
|
|
{% comment %}
|
|
Context variables:
|
|
- object: the actual diffusion
|
|
- page: current parent page in which item is rendered
|
|
- hide_schedule: if True, do not display start time
|
|
{% endcomment %}
|
|
|
|
{% with page as context_page %}
|
|
{% with object.program as program %}
|
|
{% diffusion_page object as page %}
|
|
<article class="media">
|
|
<div class="media-left">
|
|
<img src="{% thumbnail page.cover|default:site.logo 128x128 crop=scale %}">
|
|
</div>
|
|
<div class="media-content">
|
|
<div>
|
|
<h4 class="subtitle is-size-4 is-inline-block">
|
|
{% if page and context_page != page %}
|
|
<a href="{{ page.path }}">{{ page.title }}</a>
|
|
{% else %}
|
|
{{ page.title|default:program.name }}
|
|
{% endif %}
|
|
</h4>
|
|
|
|
<span class="has-text-weight-normal">
|
|
{% if object.page is page and context_page != program.page %}
|
|
— <a href="{% url "program-page" slug=program.page.slug %}">{{ program.page.title }}</a>
|
|
{% endif %}
|
|
|
|
{% if not hide_schedule %}
|
|
<time datetime="{{ object.start|date:"c" }}" title="{{ object.start }}"
|
|
class="has-text-weight-light is-size-6">
|
|
— {{ object.start|date:"d M, H:i" }}
|
|
</time>
|
|
{% endif %}
|
|
|
|
{% if object.initial %}
|
|
{% with object.initial.date as date %}
|
|
<span class="tag is-info" title="{% blocktrans %}Rerun of {{ date }}{% endblocktrans %}">
|
|
{% trans "rerun" %}
|
|
</span>
|
|
{% endwith %}
|
|
{% endif %}
|
|
</span>
|
|
</div>
|
|
|
|
<div class="content">
|
|
{{ page.headline|default:program.page.headline }}
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</article>
|
|
{% endwith %}
|
|
{% endwith %}
|
|
|