Skip to content

fix(admin): one clear way to create a course for school admins (#665) - #666

Open
guillermoscript wants to merge 2 commits into
masterfrom
fix/admin-create-course-cta-665
Open

fix(admin): one clear way to create a course for school admins (#665)#666
guillermoscript wants to merge 2 commits into
masterfrom
fix/admin-create-course-cta-665

Conversation

@guillermoscript

@guillermoscript guillermoscript commented Sep 2, 2026

Copy link
Copy Markdown
Owner

Summary

Fixes #665 · Sentry user feedback LMS-FRONT-9N

A school admin on prod wrote "je ne vois pas comment faire cree des cours" after 1m18s of wandering between settings pages, no errors and no rage clicks.

Before: the admin Courses page had no Create button, and admins had two creation paths that behaved differently:

  • Teacher course form (/dashboard/teacher/courses/new) → lands in the course editor.
  • "Create Product" quick create (/dashboard/admin/products/new) → creates course + price, then drops you on the Products list with no next step. The getting-started checklist pointed here.

After: one page, /dashboard/admin/courses/new, reachable from every admin surface, and it ends in the course editor where lessons get added.

Changes

  • New /dashboard/admin/courses/new: quick create (title, free/paid, price, publish or draft) + AI starter generator. Breadcrumb Admin → Courses → New Course.
  • Quick create lands in the course editor (/dashboard/teacher/courses/<id>), not the products list. "More options" opens the full product wizard.
  • /dashboard/admin/products/new is the product wizard only. The ?advanced=1 split is removed; old ?advanced=1 links still land on the wizard.
  • Every entry point points at the one page: sidebar (new "Create Course" sub-item under Courses), Courses page header button, courses table empty state, admin home getting-started checklist, onboarding wizard "skip to create".
  • i18n en/es for the new page, breadcrumb, and empty state.
  • Specs: admin-pages (checklist href + new CTA assertion), admin-product-course-creation (paths + quick-create now asserts the editor URL, then checks the product exists), plan-limit-surfaces (AI cap test on the new page). admin-crud's expectation that /products/new shows the wizard is true again.

Uses base-ui render={<Link/>} on Buttons, not a wrapping <Link>.

QA

  • npm run typecheck ✅ · eslint on changed files ✅
  • Playwright not run locally (Docker daemon was down, no local Supabase). Relevant specs, --workers=1:
    npx playwright test admin-pages admin-product-course-creation admin-crud plan-limit-surfaces --workers=1
    
  • Manual, as owner@e2etest.com on default.lvh.me:3005:
    1. Sidebar → Courses → "Create Course" → lands on /dashboard/admin/courses/new.
    2. Type a title, leave Free, "Create & publish" → toast, then the course editor opens.
    3. /dashboard/admin/products/new → multi-step wizard, no quick form.
    4. Admin home checklist "Create your first course" → same new page.

🤖 Generated with Claude Code

https://claude.ai/code/session_01D6TeYjJcqunFTZ5FR52SDA

…bar (#665)

A school admin left Sentry feedback "je ne vois pas comment faire cree
des cours" (LMS-FRONT-9N) after wandering the settings pages for over a
minute with no errors. The admin Courses page was a read-only stats +
table view with no Create button, and the only creation entry point
(/dashboard/teacher/courses/new) sat behind a "My Courses" sub-item that
nothing labels as the place to create.

- "Create Course" button in the admin Courses page header
- Real empty state in the admin courses table with a create CTA when the
  school has no courses at all (filtered-to-empty keeps the plain message)
- "Create Course" sub-item under Sidebar > Courses for admins
- en/es copy; regression assertion in admin-pages.spec.ts

Fixes LMS-FRONT-9N

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01D6TeYjJcqunFTZ5FR52SDA
@guillermoscript guillermoscript added the bug Something isn't working label Sep 2, 2026
…mes wizard-only (#665)

Admins had two creation paths that led to different places: the teacher
course form (lands in the course editor) and the "Create Product" quick
create (creates course + price, then dumps you on the Products list with
no next step). The getting-started checklist pointed at the second one.

- New /dashboard/admin/courses/new: quick create (title, free/paid,
  publish) + AI starter generator, breadcrumbed under Courses
- Quick create now lands in the course editor so adding lessons is the
  obvious next step; "More options" opens the full product wizard
- /dashboard/admin/products/new is the product wizard only (the
  ?advanced=1 split is gone; old links still land on the wizard)
- Sidebar, Courses page, empty state, getting-started checklist and the
  onboarding wizard all point at the one page
- Specs follow the routes; admin-crud's wizard-at-/products/new
  expectations are true again

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01D6TeYjJcqunFTZ5FR52SDA
@guillermoscript guillermoscript changed the title fix(admin): expose course creation on the admin Courses page and sidebar (#665) fix(admin): one clear way to create a course for school admins (#665) Sep 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Admins can't find how to create a course (Sentry LMS-FRONT-9N)

1 participant