From 977b8630fbaf794f96d45bedeb715707c67a8a22 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Gruszczy=C5=84ski?= Date: Fri, 15 Aug 2025 13:01:00 +0200 Subject: [PATCH] zmiany w edycji listy przez usera --- static/js/move_to_month.js | 10 ++++++++++ templates/edit_my_list.html | 37 +++++++++++++++++++++++++------------ 2 files changed, 35 insertions(+), 12 deletions(-) create mode 100644 static/js/move_to_month.js diff --git a/static/js/move_to_month.js b/static/js/move_to_month.js new file mode 100644 index 0000000..6cffa99 --- /dev/null +++ b/static/js/move_to_month.js @@ -0,0 +1,10 @@ + function updateMoveToMonth() { + const year = document.getElementById('move_to_month_year').value; + const month = document.getElementById('move_to_month_month').value; + document.getElementById('move_to_month').value = `${year}-${month}`; + } + + document.getElementById('move_to_month_year').addEventListener('change', updateMoveToMonth); + document.getElementById('move_to_month_month').addEventListener('change', updateMoveToMonth); + + updateMoveToMonth(); \ No newline at end of file diff --git a/templates/edit_my_list.html b/templates/edit_my_list.html index a77821f..bce7adf 100644 --- a/templates/edit_my_list.html +++ b/templates/edit_my_list.html @@ -55,19 +55,31 @@ - -
-
- - - {{ list.created_at.strftime('%Y-%m-%d') }} - +
+
+ + + {{ list.created_at.strftime('%Y-%m-%d') }} + +
+
+ +
+ + +
+ + +
-
- - -
-
@@ -197,4 +209,5 @@ + {% endblock %} \ No newline at end of file