- Generate unique quiz for each lesson using OpenRouter API
- Parse lesson content (TipTap JSON) and send to AI for question generation
- Cache quiz in database to avoid regeneration
- Hide Edit/Delete buttons if current user is not course author
- Add backendUser to auth context for proper authorization checks
- Show certificate button prominently when course is completed
Co-authored-by: Cursor <cursoragent@cursor.com>
Backend changes:
- Add Certificate generation service with beautiful HTML templates
- Add CourseGroup, GroupMember, GroupMessage models for group collaboration
- Add Homework and HomeworkSubmission models with AI + teacher grading
- Add SupportTicket and TicketMessage models for help desk
- Add Moderation API for admin/moderator course approval workflow
- All new modules: CertificatesModule, GroupsModule, SupportModule, ModerationModule
Frontend changes:
- Add certificate download button when course completed
- Update course page to load enrollment progress from backend
- Integrate lesson completion with backend API
Database schema now supports:
- Course groups with chat functionality
- Homework assignments with dual AI/human grading
- Support ticket system with admin responses
- Full moderation workflow (PENDING_REVIEW -> PUBLISHED/REJECTED)
Co-authored-by: Cursor <cursoragent@cursor.com>