feat(lessons): «Быстрый урок» — одиночный урок без ручного создания курса
Учитель жмёт «Быстрый урок» в каталоге (theory.html) → урок создаётся в скрытом личном курсе-контейнере и сразу открывается редактор. Возни с курсом нет. - Миграция 059: courses.is_personal (ADD COLUMN). - POST /api/lessons/quick (teacher/admin): get-or-create личный контейнер (is_personal=1, один на учителя, опубликован) + создаёт урок, возвращает lessonId. - Каталог курсов скрывает личные контейнеры от всех, кроме владельца (courseController.list). - Свои быстрые уроки учитель видит как курс «Мои материалы» (открыв его в каталоге). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
-- ═══════════════════════════════════════════════════════════════
|
||||
-- 059: Personal "container" course for standalone quick lessons
|
||||
--
|
||||
-- A teacher who just wants to author a single lesson (without manually
|
||||
-- creating a whole course) gets a hidden personal container course
|
||||
-- (is_personal = 1, one per teacher). Quick lessons are added there.
|
||||
-- The course catalog hides personal containers from everyone except their
|
||||
-- owner (see courseController.list).
|
||||
-- ═══════════════════════════════════════════════════════════════
|
||||
|
||||
ALTER TABLE courses ADD COLUMN is_personal INTEGER NOT NULL DEFAULT 0;
|
||||
Reference in New Issue
Block a user