From 740c02b42bd4a7cd51d36a76d077cd0128cada1a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Gruszczy=C5=84ski?= Date: Tue, 12 Aug 2025 22:55:52 +0200 Subject: [PATCH] dropbna poprawka w stringu --- templates/admin/admin_panel.html | 96 +++++++++++++++++--------------- 1 file changed, 52 insertions(+), 44 deletions(-) diff --git a/templates/admin/admin_panel.html b/templates/admin/admin_panel.html index 8f53e60..614ee61 100644 --- a/templates/admin/admin_panel.html +++ b/templates/admin/admin_panel.html @@ -127,49 +127,55 @@ -{% if not show_all %} - {% set current_date = now.replace(day=1) %} - {% set prev_month = (current_date - timedelta(days=1)).strftime('%Y-%m') %} - {% set next_month = (current_date + timedelta(days=31)).replace(day=1).strftime('%Y-%m') %} +{# panel wyboru miesiąca zawsze widoczny #} +
-
+ {# LEWA STRONA — przyciski ← → TYLKO gdy nie show_all #} +
+ {% if not show_all %} + {% set current_date = now.replace(day=1) %} + {% set prev_month = (current_date - timedelta(days=1)).strftime('%Y-%m') %} + {% set next_month = (current_date + timedelta(days=31)).replace(day=1).strftime('%Y-%m') %} + + {% if prev_month in month_options %} + + ← {{ prev_month }} + + {% else %} + + {% endif %} - {# LEWA STRONA - Przyciski #} -
- {% if prev_month in month_options %} - - ← {{ prev_month }} - - {% else %} - - {% endif %} - - {% if next_month in month_options %} - - {{ next_month }} → - - {% else %} - - {% endif %} -
+ {% if next_month in month_options %} + + {{ next_month }} → + + {% else %} + + {% endif %} + {% else %} + {# Tryb wszystkie miesiące — możemy pokazać skrót do bieżącego miesiąca #} + + 📅 Przejdź do bieżącego miesiąca + + {% endif %} +
- {# PRAWA STRONA - Picker #} -
-
- 📅 - -
-
+ {# PRAWA STRONA — picker miesięcy zawsze widoczny #} +
+
+ 📅 +
-{% endif %} +
+
@@ -193,8 +199,8 @@ Utworzono Właściciel Produkty - Wypełnienie - Komentarze + Progress + Koment. Paragony Wydatki Akcje @@ -257,10 +263,10 @@
- ✏️ Edytuj + ✏️ 🗑️ Usuń + onclick="return confirm('Na pewno usunąć tę listę?')">🗑️
@@ -268,7 +274,9 @@
- +
+ +