From 5cac1fe1094748db777837faa1fa7dbfe7145b3d Mon Sep 17 00:00:00 2001 From: Colin Powell Date: Thu, 11 Sep 2025 09:41:12 -0400 Subject: [PATCH] [templates] Fix food templates and such --- vrobbler/templates/foods/food_detail.html | 33 +++++++++++++++++++ vrobbler/templates/foods/food_list.html | 23 +++++++++++++ .../templates/scrobbles/scrobble_detail.html | 2 ++ .../templates/webpages/webpage_detail.html | 2 +- 4 files changed, 59 insertions(+), 1 deletion(-) create mode 100644 vrobbler/templates/foods/food_detail.html create mode 100644 vrobbler/templates/foods/food_list.html diff --git a/vrobbler/templates/foods/food_detail.html b/vrobbler/templates/foods/food_detail.html new file mode 100644 index 0000000..89c3b41 --- /dev/null +++ b/vrobbler/templates/foods/food_detail.html @@ -0,0 +1,33 @@ +{% extends "base_list.html" %} +{% load static %} + +{% block title %}{{object.title}}{% endblock %} + +{% block lists %} +
+ +
+
+
+

Last scrobbles

+
+ + + + + + + + {% for scrobble in scrobbles.all %} + + + + {% endfor %} + +
Date
{{scrobble.local_timestamp}}
+
+
+
+{% endblock %} diff --git a/vrobbler/templates/foods/food_list.html b/vrobbler/templates/foods/food_list.html new file mode 100644 index 0000000..71167a3 --- /dev/null +++ b/vrobbler/templates/foods/food_list.html @@ -0,0 +1,23 @@ +{% extends "base_list.html" %} + +{% block title %}Foods{% endblock %} + +{% block head_extra %} + +{% endblock %} + +{% block lists %} +
+ +
+
+ {% include "_scrobblable_list.html" %} +
+
+
+{% endblock %} diff --git a/vrobbler/templates/scrobbles/scrobble_detail.html b/vrobbler/templates/scrobbles/scrobble_detail.html index 213606e..f245792 100644 --- a/vrobbler/templates/scrobbles/scrobble_detail.html +++ b/vrobbler/templates/scrobbles/scrobble_detail.html @@ -12,7 +12,9 @@

{{ object.media_obj }} - {{object.media_type}}

+{% if object.logdata.avg_seconds_per_page %}

Rate: {{object.logdata.avg_seconds_per_page}}s per page

+{% endif %}

Edit Log

diff --git a/vrobbler/templates/webpages/webpage_detail.html b/vrobbler/templates/webpages/webpage_detail.html index 3b12ab1..c82945f 100644 --- a/vrobbler/templates/webpages/webpage_detail.html +++ b/vrobbler/templates/webpages/webpage_detail.html @@ -53,7 +53,7 @@ {% for scrobble in scrobbles.all %} - {{scrobble.local_timestamp}} + {{scrobble.local_timestamp}} {% endfor %}