1. Users
id (PK)
email (Unique, CSV se aata hai)
name (Optional, profile mein update kar sakta hai)
avatar (Email/name-based auto-generated, e.g., "ND" for "Nikhil Dubey")
is_admin BOOLEAN DEFAULT FALSE
created_at, updated_at
- Purpose:
- Sirf CSV mein listed emails se hi signup/login hoga.
- Admin (ChaiCode) bhi isi table mein hoga (with
is_admin flag).
2. Cohorts
id (PK)
name (e.g., "WebDev Jan 2024")
description
created_by (FK → users.id, admin)
- Purpose:
- CSV upload karke cohorts create honge.
- Student login ke time cohort select karega.
3. UserCohorts
user_id (FK → users.id)
cohort_id (FK → cohorts.id)
joined_at
- Purpose:
- Ek student multiple cohorts ka part ho sakta hai.
- Login ke baad saare cohorts dikhayenge.
4. Groups