forked from rc/aircox
cfr #121 Co-authored-by: Christophe Siraut <d@tobald.eu.org> Co-authored-by: bkfox <thomas bkfox net> Co-authored-by: Thomas Kairos <thomas@bkfox.net> Reviewed-on: rc/aircox#131 Co-authored-by: Chris Tactic <ctactic@noreply.git.radiocampus.be> Co-committed-by: Chris Tactic <ctactic@noreply.git.radiocampus.be>
This commit is contained in:
35
aircox/templates/aircox/widgets/logs.html
Normal file
35
aircox/templates/aircox/widgets/logs.html
Normal file
@ -0,0 +1,35 @@
|
||||
{% comment %}
|
||||
Context:
|
||||
- object_list: list of logs
|
||||
- timetable: defaults to False
|
||||
- widget: defaults to "item"
|
||||
{% endcomment %}
|
||||
{% load aircox %}
|
||||
|
||||
{% with timetable|default:False as timetable %}
|
||||
{% with widget|default:"item" as widget %}
|
||||
{% for object in object_list %}
|
||||
{% if object.episode %}
|
||||
{% page_widget widget object.episode diffusion=object timetable=True %}
|
||||
{% elif object|is_log %}
|
||||
{% include "./track_item.html" with object=object.track log=object timetable=True %}
|
||||
{% else %}
|
||||
<div class="preview list-item logs">
|
||||
<header class="headings">
|
||||
<span class="heading title">
|
||||
<span class="icon pr-2">
|
||||
<i class="fas fa-music"></i>
|
||||
</span>
|
||||
{{ station.music_stream_title }}
|
||||
</span>
|
||||
</header>
|
||||
<div class="media d-block content">
|
||||
{% for obj in object %}
|
||||
{% include "./track_item.html" with object=obj.track log=obj timetable=True %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endwith %}
|
||||
{% endwith %}
|
Reference in New Issue
Block a user