feat: enhance SQL query handling and UI components for exercise management
Deploy Development / deploy (push) Successful in 36s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 5s
Test Suite / playwright-tests (push) Has been cancelled

- Introduced a new utility function to streamline SQL query construction for active status filtering, improving code reusability across multiple endpoints.
- Updated existing query logic in the catalogs and skills routers to utilize the new utility function, ensuring consistent handling of active status.
- Refactored the ExerciseFormPage to remove deprecated age group handling, simplifying the form structure.
- Enhanced the RichTextEditor component with improved link handling and formatting options for better user experience.
- Updated API utility functions to support new AI features for exercise suggestions and regeneration, expanding the capabilities of the exercise management system.
This commit is contained in:
Lars committed 2026-04-27 15:01:47 +02:00
1 parent d8f439a3e5
commit 0ad096e483
7 files changed
+129 -84

No files matched your search

+7 -4
View File
@@ -53,11 +53,14 @@ def list_skills(
params.append(category)
if status:
where.append("status = %s")
params.append(status)
if status == "active":
where.append("(status = 'active' OR status IS NULL)")
else:
where.append("status = %s")
params.append(status)
else:
# Default: only active skills
where.append("status = 'active'")
# Default: nur aktive (NULL = Legacy, wie Kataloglisten)
where.append("(status = 'active' OR status IS NULL)")
if where:
query += " WHERE " + " AND ".join(where)