From d78139a5b3fb6b2a2d535371166e18bd633cdd26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Kucharczyk?= Date: Mon, 20 Nov 2023 21:56:16 +0100 Subject: [PATCH] Display finished DLCs in stats better --- games/templates/stats.html | 8 +++++++- games/templates/view_game.html | 1 - games/views.py | 6 +++--- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/games/templates/stats.html b/games/templates/stats.html index d2dd1c4..3faf56c 100644 --- a/games/templates/stats.html +++ b/games/templates/stats.html @@ -136,7 +136,13 @@ {{ purchase.edition.name }} + href="{% url 'edit_purchase' purchase.id %}"> + {% if purchase.type == 'dlc' %} + {{ purchase.name }} ({{ purchase.edition.name }} DLC) + {% else %} + {{ purchase.edition.name }} + {% endif %} + {{ purchase.date_finished | date:"d/m/Y" }} diff --git a/games/templates/view_game.html b/games/templates/view_game.html index b28cba5..c8fb77a 100644 --- a/games/templates/view_game.html +++ b/games/templates/view_game.html @@ -61,7 +61,6 @@ {% url 'start_game_session' game.id as add_session_link %} {% include 'components/button.html' with title="Start new session" text="New" link=add_session_link %} and Notes ({{ sessions_with_notes_count }}) -