mirror of https://github.com/krateng/maloja.git
33 lines
881 B
Django/Jinja
33 lines
881 B
Django/Jinja
{% macro row(entity,counting=[]) %}
|
||
|
||
{% import 'snippets/links.jinja' as links %}
|
||
|
||
{% if entity is mapping and 'artists' in entity %}
|
||
{% set img = images.get_track_image(entity) %}
|
||
{% else %}
|
||
{% set img = images.get_artist_image(entity) %}
|
||
{% endif %}
|
||
|
||
<td class='icon'>
|
||
{% if settings['DISPLAY_ART_ICONS'] %}
|
||
<div class="lazy" data-bg="{{ img }}"></div>
|
||
{% endif %}
|
||
</td>
|
||
{% if entity is mapping and 'artists' in entity %}
|
||
{% if settings['TRACK_SEARCH_PROVIDER'] %}
|
||
<td class='searchProvider'>{{ links.link_search(entity) }}</td>
|
||
{% endif %}
|
||
<td class='track'>
|
||
<span class='artist_in_trackcolumn'>{{ links.links(entity.artists) }}</span> – {{ links.link(entity) }}
|
||
</td>
|
||
{% else %}
|
||
<td class='artist'>{{ links.link(entity) }}
|
||
{% if counting != [] %}
|
||
<span class='extra'>incl. {{ links.links(counting) }}</span>
|
||
{% endif %}
|
||
</td>
|
||
|
||
{% endif %}
|
||
|
||
{% endmacro %}
|