feat: Training Planning (core feature) complete
Backend: - Created migration 006_training_planning.sql - training_units table (planned vs actual, status, notes) - training_unit_exercises M:N (order, duration, modifications) - Created routers/training_planning.py with full CRUD - List with filters (group, date range, status) - Get detail with exercises - Create/Update/Delete with access control - Quick create endpoint (auto-fills from group defaults) - Permission: trainer for own groups, admin for all - Registered training_planning router in main.py Frontend: - Complete TrainingPlanningPage with full planning workflow - Group selector + date range picker - List view with status badges (planned/completed/cancelled) - Create/Edit modal with exercise management - Drag to reorder exercises (▲▼) - Quick create button (one-click with group defaults) - Durchführung section (actual date/time, attendance, status) - Public notes + trainer-only notes - Updated api.js with deleteTrainingUnit and quickCreateTrainingUnit - Added /planning route to App.jsx - Navigation already configured (Calendar icon) This is the CORE feature - trainers can now plan and document training sessions. Next: Admin routes, role system refinement, testing
This commit is contained in:
1 parent
505a8e5e38
commit
7f156ba085
6 files changed
+1188
-6
No files matched your search
@@ -9,6 +9,7 @@ import ProfilePage from './pages/ProfilePage'
|
||||
import ExercisesPage from './pages/ExercisesPage'
|
||||
import ClubsPage from './pages/ClubsPage'
|
||||
import SkillsPage from './pages/SkillsPage'
|
||||
import TrainingPlanningPage from './pages/TrainingPlanningPage'
|
||||
import './app.css'
|
||||
|
||||
// Bottom Navigation (Mobile)
|
||||
@@ -167,6 +168,14 @@ function AppRoutes() {
|
||||
</ProtectedRoute>
|
||||
}
|
||||
/>
|
||||
<Route
|
||||
path="/planning"
|
||||
element={
|
||||
<ProtectedRoute>
|
||||
<TrainingPlanningPage />
|
||||
</ProtectedRoute>
|
||||
}
|
||||
/>
|
||||
|
||||
{/* Catch all - redirect to dashboard or login */}
|
||||
<Route path="*" element={<Navigate to="/" replace />} />
|
||||
|
||||
Reference in new issue
Block a user