From 56d2d68fa002f59d5b400af70a0e8955660afcce Mon Sep 17 00:00:00 2001 From: Ivo Oskamp Date: Sat, 3 Jan 2026 13:40:56 +0100 Subject: [PATCH] Auto-commit local changes before build (2026-01-03 13:40:56) --- .last-branch | 2 +- containers/backupchecks/src/templates/main/reports.html | 4 +++- docs/changelog.md | 8 ++++++++ 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.last-branch b/.last-branch index 0e6cd83..a7825bb 100644 --- a/.last-branch +++ b/.last-branch @@ -1 +1 @@ -v20260103-05-reports-date-import-fix +v20260103-06-reports-delete-button-fix diff --git a/containers/backupchecks/src/templates/main/reports.html b/containers/backupchecks/src/templates/main/reports.html index ab7e847..2bb1d55 100644 --- a/containers/backupchecks/src/templates/main/reports.html +++ b/containers/backupchecks/src/templates/main/reports.html @@ -387,7 +387,7 @@ openRawModal(id); }); }); - } + body.querySelectorAll('.rep-delete-btn').forEach(function (btn) { btn.addEventListener('click', function () { @@ -395,6 +395,8 @@ deleteReport(id, btn); }); }); + } + function loadReports() { setTableLoading('Loading…'); fetch('/api/reports', { credentials: 'same-origin' }) diff --git a/docs/changelog.md b/docs/changelog.md index 694d21e..08bb81b 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -35,6 +35,14 @@ - Fixed a crash on the Reports page caused by missing datetime imports. - Added the required `date` and `timedelta` imports to prevent a NameError when determining the default report period. +--- + +## v20260103-06-reports-delete-button-fix + +- Fixed an issue where the Delete button on the Reports page did not perform any action. +- Resolved a JavaScript block/brace error that prevented the delete handler from executing. +- Ensured the DELETE API call is correctly triggered and the reports list is refreshed after deletion. +- Restored correct CSS classes for the server-rendered Delete button to ensure proper binding. ================================================================================================================================================