From 9dbd3cbd5fe09cc527f9cd456fcdf41c3e561c7b Mon Sep 17 00:00:00 2001 From: Lars Date: Wed, 6 May 2026 07:25:11 +0200 Subject: [PATCH] feat: enhance TrainingPlanningPage with template application functionality - Added a new function to apply selected training templates, improving user experience in the training planning process. - Introduced modal display logic to enhance interaction when applying templates. - Updated the state management to handle template ID selection more effectively. --- frontend/src/pages/TrainingPlanningPage.jsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/frontend/src/pages/TrainingPlanningPage.jsx b/frontend/src/pages/TrainingPlanningPage.jsx index 057b05d..6576d58 100644 --- a/frontend/src/pages/TrainingPlanningPage.jsx +++ b/frontend/src/pages/TrainingPlanningPage.jsx @@ -507,7 +507,11 @@ function TrainingPlanningPage() { trainer_notes: '', sections: [defaultSection('Hauptteil')], ...sessionAssignDefaults() - }) = async (templateId) => { + }) + setShowModal(true) + } + + const applyTemplateFromSelect = async (templateId) => { setDraftPlanTemplateId(templateId) if (!templateId) return try {