You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
2.1 KiB
HTML

{% import "macros.htm" as macros %}
<!DOCTYPE html>
<html>
{% set title = collection_list | length | string + " Collections known" %}
<head>
<meta charset="utf-8"/>
<title>{{ title }}</title>
{{ macros.shared_style() }}
</head>
<body>
{{ macros.body_header() }}
<h1>{{ title }}</h1>
<table class="collection_table_list">
<tr>
<th>Date</th>
<th>Count</th>
<th>To Watch</th>
<th>Actions</th>
<th>Thumbnail</th>
<th>Title</th>
<th>Tags</th>
</tr>
{% for collection in collection_list %}
{% set api_uri = "/api/collection/" + collection.id|string %}
{% set fragment = "collection_element_" + collection.id|string %}
<tr id="{{ fragment }}">
<td>
{% if collection.release_date %}
{{ collection.release_date.strftime("%d.%m.%Y") }}
{% else %}
unknown
{% endif %}
</td>
<td>{{ collection.count }}</td>
<td>{{ collection.to_watch_count }}</td>
<td class="button-list">
{{ macros.post_form(api_uri, "watch_in_order", collection.watch_in_order | tenary("false", "true"), collection.watch_in_order | tenary("watch in order", "watch random"), fragment) }}
</td>
<td>
{% set e = (collection.next_episode or collection.first_episode).element %}
<img class="thumbnail_img" src="{{ e.info_link }}/thumbnail" alt="Thumbnail for {{ e.title }}" loading="lazy" />
</td>
<td><a href="{{ collection.info_link }}">{{ collection.title }}</a></td>
<td>
{{ collection.assigned_tags | map(attribute="title") | sort | join(" | ") }}
</td>
</tr>
{% endfor %}
</table>
</body>
</html>