Commit 20a97aca authored by fred's avatar fred
Browse files

add template for new sounds cell and use it for home and sounds sidebars

parent 0a6a60d0
{% load i18n paniktags %}
<h3 class="sectionLabel right">
<a href="{% url 'listenArchives' %}"><span class="iconLabel">Tous</span></a>
</h3>
<h3 class="sectionLabel">{% trans 'Latest Sounds' %}&nbsp;<a
class="button icon-rss inBlock" href="{% url 'podcasts-feed' %}"></a></h3>
{% if include_search_input %}
<form action="{% url 'listenArchives' %}" id="search-form">
<input id="id_q" name="q" type="text" {% if search_query %}value="{{ search_query }}"{% endif %}>
<button class="icon-search"><span class="sr-only">{% trans "Search" %}</span></button>
</form>
{% endif %}
<ul class="custom list">
{% with count_s=count|stringformat:"s" %}
{% with slice_count=":"|add:count_s %}
{% for soundfile in soundfiles|slice:slice_count %}
<li class="item">
{% soundfile_resume soundfile=soundfile date=soundfile.first_diffusion %}
</li>
{% endfor %}
{% endwith %}
{% endwith %}
</ul>
......@@ -62,15 +62,7 @@
{% if soundfiles %}
<div id="recent-sounds">
<h3 class="sectionLabel right"><a href="{% url 'listenArchives' %}">Tous</a></h3>
<h3 class="sectionLabel"><a href="{% url 'listen' %}">{% trans 'Latest Sounds' %}</a>&nbsp;<a class="button icon-rss inBlock" href="{% url 'podcasts-feed' %}"></a></h3>
<ul class="custom list">
{% for soundfile in soundfiles %}
<li class="item {% for category in soundfile.episode.emission.categories.all %} {{ category|slugify }}{% endfor %}">
{% soundfile_resume soundfile=soundfile date=soundfile.first_diffusion %}
</li>
{% endfor %}
</ul>
{% include "combo/soundscell.html" with include_search_input=False count=3 %}
</div>
{% endif %}
......
......@@ -63,24 +63,7 @@
</div>
<div class="rightPart">
<div class="sub">
<h5 class="sectionLabel right">
<a href="{% url 'listenArchives' %}"><span class="iconLabel">Tous</span></a>
</h5>
<h5 class="sectionLabel">{% trans 'Latest Sounds' %}&nbsp;<a
class="button icon-rss inBlock" href="{% url 'podcasts-feed' %}"></a></h5>
<form action="{% url 'listenArchives' %}" id="search-form">
<input id="id_q" name="q" type="text" {% if search_query %}value="{{ search_query }}"{% endif %}>
<button class="icon-search"><span class="sr-only">{% trans "Search" %}</span></button>
</form>
<ul class="custom list soundfilesList">
{% for soundfile in soundfiles|slice:":20" %}
<li class="item">
{% soundfile_resume soundfile=soundfile date=soundfile.first_diffusion %}
</li>
{% endfor %}
</ul>
{% include "combo/soundscell.html" with include_search_input=True count=20 %}
</div>
</div>
</div>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment