Add owner to list of collections.
When listing the collections, that a media is contained in, also show the owner of the collection. Also simplify the whole looping a lot.
This commit is contained in:
parent
96a2249bc0
commit
5a05016896
@ -21,17 +21,13 @@
|
|||||||
<h3>{% trans %}Collected in{% endtrans %}</h3>
|
<h3>{% trans %}Collected in{% endtrans %}</h3>
|
||||||
<p>
|
<p>
|
||||||
{%- for collection in media.collections %}
|
{%- for collection in media.collections %}
|
||||||
{% if loop.last %}
|
{%- if not loop.first %}
|
||||||
{# the 'and' should only appear if there is more than one collections #}
|
|
||||||
{% if media.collections|length > 1 %}
|
|
||||||
·
|
·
|
||||||
{% endif %}
|
{%- endif %}
|
||||||
<a href="{{ collection.url_for_self(request.urlgen) }}">{{ collection['title'] }}</a>
|
<a href="{{ collection.url_for_self(request.urlgen) }}">
|
||||||
{% elif loop.revindex == 2 %}
|
{{- collection.title }} (
|
||||||
<a href="{{ collection.url_for_self(request.urlgen) }}">{{ collection['title'] }}</a>
|
{{- collection.get_creator.username -}}
|
||||||
{% else %}
|
)</a>
|
||||||
<a href="{{ collection.url_for_self(request.urlgen) }}">{{ collection['title'] }}</a> ·
|
|
||||||
{% endif %}
|
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
</p>
|
</p>
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user