71 lines
4.0 KiB
Markdown
71 lines
4.0 KiB
Markdown
# Makeup artistry backend
|
|
|
|
The current product teaches makeup artistry through courses, chapters, video
|
|
lessons, and chapter quizzes. Course publication, free/premium tiers, sequential
|
|
progress, and staff access use the existing backend services.
|
|
|
|
## Compatibility
|
|
|
|
`EDUCATION` remains the canonical content/subscription category. New API clients
|
|
must continue sending that value, not a new `MAKEUP` enum. Customer subscription
|
|
notifications and email package labels now describe makeup artistry access.
|
|
Historical `LEARN_ENGLISH`, `IELTS`, and `DUOLINGO` records retain their labels.
|
|
|
|
The `exam_prep` schema, Go type names, permission keys, and legacy routes remain
|
|
storage/API compatibility identifiers. Current public catalog DTOs expose courses,
|
|
chapters, lessons, and quizzes. Do not rename database schemas or bulk-change
|
|
existing subscription categories to update the product terminology. Permission
|
|
display labels now describe makeup courses; authorization keys and grants are
|
|
unchanged. Staff roles remain `SUPER_ADMIN`, `ADMIN`, and `CONTENT_MANAGER`;
|
|
makeup instructors can author through the existing Content Manager role.
|
|
|
|
## Learner profiles
|
|
|
|
Apply migration `000004_makeup_artistry_profiles` to add active options for:
|
|
|
|
- Occupation: beauty student, makeup artist, makeup educator, salon professional.
|
|
- Learning goal: personal makeup, professional artistry, bridal specialization,
|
|
and editorial portfolio development.
|
|
- Favourite topic: complexion, eye makeup, bridal looks, and editorial artistry.
|
|
|
|
These use the existing `occupation`, `learning_goal`, and `favourite_topic`
|
|
fields and option APIs. Existing language preference remains a localization
|
|
preference, not a course subject. Historical language goal/challenge fields and
|
|
custom profile choices are retained for API and stored-profile compatibility.
|
|
The migration inserts missing codes only and does not overwrite administrator
|
|
edits. Its down migration intentionally retains reference choices so saved
|
|
profiles remain valid.
|
|
|
|
## Demo curriculum
|
|
|
|
Run `go run ./cmd/demo-seed -environment development` after starting PostgreSQL
|
|
and applying migrations. The seeder adds three makeup courses, six chapters,
|
|
eighteen lessons, six chapter quizzes, and eighteen distinct MCQs with answer
|
|
explanations. The bridal course is premium; foundations and editorial are free.
|
|
A special-effects draft verifies publication filtering. Questions cover kit
|
|
selection, brush control, workstation setup, complexion, client consultation,
|
|
bridal finishing, color, and portfolio practice.
|
|
|
|
The inactive `[Demo] Makeup Academy Pass` supports the premium test learner.
|
|
It is not a publicly purchasable plan. Demo account emails/password settings
|
|
remain unchanged. The fixture never runs automatically on backend startup and
|
|
refuses production environment settings, including `ENV=production`.
|
|
|
|
See [demo setup and compatibility](demo-and-public-catalog.md) for credentials,
|
|
media fixtures, upgrade behavior, and opt-in database integration tests. The old
|
|
`db/data` and `db/dev_data` collections target historical schemas; use the current
|
|
Go demo seeder for this curriculum. Replace sample playback clips with your own
|
|
teaching recordings before using demo lessons as instructional material.
|
|
|
|
## Admin profile and analytics alignment
|
|
|
|
Apply migration `000005_makeup_artistry_focus` for artistry focus and challenge choices.
|
|
The existing `language_goal` and `language_challange` JSON/storage keys remain for compatibility;
|
|
the admin presents them as Artistry focus and Artistry challenge. New options cover makeup
|
|
foundations, professional/creative artistry, color matching, blending, symmetry, and client confidence.
|
|
Missing profile values appear as Not provided rather than invented language-learning preferences.
|
|
Custom and historical values are preserved in analytics; historical courses remain accessible.
|
|
New subscription plans use EDUCATION, displayed as Makeup Artistry. Historical subscription categories
|
|
remain available in reports, while plan creation offers only the supported makeup category.
|
|
The embedded demo seed adds the new choices and fills only empty demo profile fields.
|