Skip to content

Ck 7vn/class detail roster#1093

Closed
CK-7vn wants to merge 6 commits into
CK-7vn/class-detail-foundationfrom
CK-7vn/class-detail-roster
Closed

Ck 7vn/class detail roster#1093
CK-7vn wants to merge 6 commits into
CK-7vn/class-detail-foundationfrom
CK-7vn/class-detail-roster

Conversation

@CK-7vn

@CK-7vn CK-7vn commented Feb 26, 2026

Copy link
Copy Markdown
Member

Pre-Submission PR Checklist

  • No debug/console/fmt.Println statements
  • Unnecessary development comments removed
  • All acceptance criteria verified
  • Functions according to ticket specifications
  • Tested manually where applicable
  • Branch rebased with latest main
  • No business logic exists within the database layer

Description of the change

PR 2 of 4 — Introduces the refactored class detail page with the shell layout and first two tabs: Roster and Enrollment History.

Class Detail Shell (index.tsx):

  • Full page layout with breadcrumb navigation, ClassHeader with stat cards (attendance rate, enrollment, capacity, sessions, completion)
  • Header actions: Edit Class (modal), Take Attendance (modal), Delete Class (dropdown, disabled when residents enrolled)
  • Tab container wired for Roster and Enrollment History (remaining tabs added in PRs 3-4)

ClassHeader + Modals (6 files):

  • ClassHeader.tsx: class title, status badge, program link, instructor, schedule info, stat cards with attendance metrics
  • ChangeClassStatusModal.tsx: activate/complete/archive class with confirmation
  • DeleteClassModal.tsx: delete class with safety check
  • EditClassModal.tsx: full class edit form (name, instructor, room, capacity, schedule, dates)
  • TakeAttendanceModal.tsx: quick attendance launcher with event selection

Roster Tab (5 files):

  • RosterTab.tsx: resident list with search, status filter, enroll/unenroll/graduate actions
  • EnrollResidentsModal.tsx: search and enroll residents with debounced lookup
  • UnenrollResidentModal.tsx: unenroll with confirmation
  • ChangeEnrollmentStatusModal.tsx: change enrollment status with reason
  • BulkGraduateModal.tsx: graduate multiple residents at once

Enrollment History Tab (1 file):

  • EnrollmentHistoryTab.tsx: historical enrollment records with date, status, and resident info

Routing + ClassesPage (2 files):

  • program-routes.tsx: adds /program-classes/:class_id/detail route
  • ClassesPage.tsx: integrates TakeAttendanceModal for quick attendance from the classes list

@CK-7vn
CK-7vn requested a review from a team as a code owner February 26, 2026 21:22
@CK-7vn
CK-7vn requested review from carddev81 and removed request for a team February 26, 2026 21:22
@CK-7vn CK-7vn closed this Feb 26, 2026
@CK-7vn CK-7vn reopened this Feb 26, 2026
@CK-7vn
CK-7vn changed the base branch from main to CK-7vn/class-detail-foundation February 26, 2026 21:30
@github-actions github-actions Bot added documentation Improvements or additions to documentation Backend HAS_MIGRATION labels Feb 26, 2026
@corypride corypride assigned corypride and unassigned corypride Mar 2, 2026
@corypride
corypride requested review from corypride and removed request for carddev81 March 2, 2026 17:15
@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-foundation branch 3 times, most recently from 996a119 to a044ef1 Compare March 5, 2026 21:55
@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-roster branch 2 times, most recently from c84b162 to f39d26e Compare March 5, 2026 21:57

@corypride corypride left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-foundation branch from a044ef1 to beaeae9 Compare March 7, 2026 06:33
@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-roster branch 2 times, most recently from 94dd108 to abe8f5e Compare March 7, 2026 08:53
@CK-7vn

CK-7vn commented Mar 7, 2026

Copy link
Copy Markdown
Member Author

@corypride Awesome, those changes were made, you will see in the Edit Class modal I've included Credit Hours, i think that could potentially be a valuable field to keep editable. Courses and programs can lose and gain credit hours throughout their lifetime so you will see that discrepancy in this PR. Also, we have historically and do currently have "Paused" as a class status value, so that is included in this PR, but it is not included/in the prototype, I'm unsure on if it is the plan to remove the paused option (my assumption would be no) but it's included needless to say.

@CK-7vn
CK-7vn requested a review from corypride March 7, 2026 08:53

@corypride corypride left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Few small things here.

@corypride corypride left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good Work Sir!

@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-foundation branch from beaeae9 to 65379df Compare March 12, 2026 17:11
@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-roster branch 2 times, most recently from b1968ca to 883f658 Compare March 16, 2026 18:35
@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-foundation branch from 65379df to 88f399d Compare March 16, 2026 18:47
@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-roster branch from 883f658 to 990d61a Compare March 16, 2026 18:50
CK-7vn added 6 commits March 17, 2026 16:45
Backend: migration for instructor overrides, database layer updates
(class events, program classes, programs, users), handler updates
(enrollments, class events, classes), and class event model changes.

Frontend: type definitions (attendance, events, program), shared UI
components (Pagination, dialog, drawer, sheet, alert-dialog),
Breadcrumbs, attendance utilities, layout and route loader updates,
BulkCancelClassesModal, and page updates (Programs, EventAttendance,
AddClassEnrollments, ClassManagementForm, ProgramOverviewDashboard).
Adds the refactored class detail page with the new shell layout:
breadcrumbs, ClassHeader with stat cards, header actions (edit,
take attendance, delete), and the first two tabs.

Roster tab: resident list with search/filter, enroll/unenroll modals,
change enrollment status, and bulk graduate functionality.

Enrollment History tab: historical enrollment records with filtering.

Also updates ClassesPage (adds TakeAttendanceModal integration) and
program-routes (adds class detail route).
@CK-7vn
CK-7vn force-pushed the CK-7vn/class-detail-roster branch from 990d61a to 206634b Compare March 17, 2026 20:47
@CK-7vn CK-7vn closed this Mar 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Backend documentation Improvements or additions to documentation HAS_MIGRATION

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants