Skip to content

Feat/teacher public visibility toggle#156

Merged
Majoodeh merged 4 commits intodevelopfrom
feat/teacher-public-visibility-toggle
Mar 9, 2026
Merged

Feat/teacher public visibility toggle#156
Majoodeh merged 4 commits intodevelopfrom
feat/teacher-public-visibility-toggle

Conversation

@Alaa2019-ml
Copy link
Copy Markdown
Contributor

In this pull request

  • I added a publish toggle for teachers.
  • Teachers can only request publish if they added subjects and schedule.
  • Requested profiles go to Pending for moderator approval (not public immediately).
  • Teachers can now see their account status in profile.

Current flow:

  1. Teacher fills profile.
  2. Teacher toggles Public profile ON.
  3. Backend validates:
  • at least 1 subject
  • at least 1 schedule slot
  1. If invalid -> request fails (400), teacher's account stays private.
  2. If valid -> backend sets:
  • isPublic = true
  • status = "pending"
  1. Teacher is not visible on public teachers page yet (only active is public).
  2. Moderator opens moderator teachers page.
  • Default list excludes draft
  • sees review statuses like pending (and others)
  1. Moderator changes teacher pending -> active.
  2. Teacher becomes visible on public teachers page.
  3. If teacher toggles OFF (Private profile) -> backend sets not public and moves back to draft flow (while keeping blocked/rejected protected).

What changed:

  • Admin reviews only teacher accounts that already meet requirements and are ready for visibility.
  • Draft/incomplete accounts don’t flood the moderator queue.
  • Result: fewer accounts to review, faster moderation, and time saved.
Screenshot 2026-03-09 at 00 48 27

@HackYourFutures HackYourFutures temporarily deployed to study-bridge-feat-teach-iemcje March 8, 2026 23:52 Inactive
@Majoodeh Majoodeh merged commit 01a4937 into develop Mar 9, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants