Commit Graph

15 Commits

Author SHA1 Message Date
Romain bogdanovic f7fb9aa6cd fix: use npx next build in cupadev build command
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-31 20:46:02 +02:00
Romain bogdanovic 6459d0cfba fix: use npx prisma in cupadev build command
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-31 20:34:38 +02:00
Romain bogdanovic 371bc7305b fix: run prisma db push before build in cupadev deployment
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 22:03:54 +02:00
Romain bogdanovic da94d44de1 feat: full LMS — learning paths, improved admin editor, student detail
Learning Paths (Parcours):
- New LearningPath, LearningPathCourse, LearningPathEnrollment Prisma models
- Admin CRUD: /admin/paths (list, create, edit, publish/draft, delete)
- Admin PathCourseManager: add/remove courses from a path with ordering
- Student pages: /paths (browse all paths), /paths/[slug] (detail + enroll)
- Enrolling in a path auto-enrolls the student in each individual course
- Enrollment API: POST /api/paths/enroll

Admin Module/Lesson/Quiz editor (ModuleManager rewrite):
- Replaced browser prompt()/confirm() with proper inline modals
- Modal dialogs for add module, add lesson, delete confirmation
- Module renaming (PUT /api/admin/modules/[id])
- Full multilingual editing for lessons (FR/EN/ES) with per-tab content
- Full multilingual quiz editing (FR/EN/ES) for questions and options
- Lesson type selection (TEXT / VIDEO) with clear button UI

Admin dashboard:
- 4-stat grid including Parcours count
- Quick actions for paths (new path, manage paths)

Students:
- Student list rows now link to /admin/students/[id] detail page
- Student detail: enrollment table with progress bars, learning paths, quiz attempts

Navigation:
- "Parcours" link added to main nav for all visitors

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 21:55:28 +02:00
Romain bogdanovic 8f78cbf25d feat: user registration, password auth, and profile settings
- Add email+password registration at /auth/register (free, self-service)
- Add CredentialsProvider to NextAuth for password-based login
- Login page now has two tabs: magic link and password
- Add /profile settings page: update name, password, and email
- Auto-promote rbogdanovic@owlcub.com to ADMIN role on sign-in
- Add bcryptjs for secure password hashing
- Prisma: add optional password field to User model

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 20:34:03 +02:00
Romain bogdanovic 0c3f375a4b fix: remove Prisma from edge middleware — use page-level auth guards instead 2026-03-29 12:15:43 +02:00
Romain bogdanovic e1433d3bb7 fix: trustHost true for nextauth behind reverse proxy 2026-03-28 20:52:15 +01:00
Romain bogdanovic 913c8a6aaf fix: nextauth v5 redirectTo, email provider signIn without redirect:false 2026-03-28 20:27:50 +01:00
Romain bogdanovic bf454b58a3 fix: setRequestLocale in all server pages, update i18n/request.ts API 2026-03-28 19:46:46 +01:00
Romain bogdanovic 547083ed91 fix: add .gitignore, remove node_modules from tracking 2026-03-28 19:18:58 +01:00
Romain bogdanovic 23febeebd4 fix: use client directive order, remove unused useTranslations import 2026-03-28 19:18:03 +01:00
Romain bogdanovic 5922e9998d fix: update prisma to v6 (auto-updated by postinstall) 2026-03-28 18:57:56 +01:00
Romain bogdanovic f8a76f2819 fix: prisma binaryTargets for Alpine, postinstall generate only 2026-03-28 18:54:49 +01:00
Romain bogdanovic 9d75855817 fix: force-dynamic on all pages, add postinstall prisma generate+push 2026-03-28 18:46:18 +01:00
Romain bogdanovic 7a8f6d0cc7 feat: initial OwlCub Academy e-learning platform 2026-03-28 18:09:38 +01:00