feat: enhance role permissions and UI for clubs and training planning
Deploy Development / deploy (push) Successful in 35s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 6s
Test Suite / playwright-tests (push) Failing after 1m55s

- Updated role permissions to allow trainers and users to create clubs and training groups.
- Modified database insertion logic to reflect the correct role for trainers during registration.
- Enhanced frontend components to display appropriate messages and buttons based on user roles.
- Improved user guidance in the Clubs and Training Planning pages, emphasizing the need for clubs and groups before planning training sessions.
This commit is contained in:
Lars committed 2026-04-28 19:46:09 +02:00
1 parent 1f2a4595cd
commit 69b26fc928
5 files changed
+136 -50

No files matched your search

+1 -1
View File
@@ -245,7 +245,7 @@ async def register(req: RegisterRequest, request: Request):
id, name, email, pin_hash, auth_type, role, tier,
email_verified, verification_token, verification_expires,
trial_ends_at, created_at
) VALUES (%s, %s, %s, %s, 'email', 'user', 'free', FALSE, %s, %s, %s, CURRENT_TIMESTAMP)
) VALUES (%s, %s, %s, %s, 'email', 'trainer', 'free', FALSE, %s, %s, %s, CURRENT_TIMESTAMP)
""", (profile_id, name, email, pin_hash, verification_token, verification_expires, trial_ends))
# Send verification email