feat: tutor workload visibility, richer assignment detail context - #69
Merged
Merged
Conversation
Surface tutor caseload before assigning, and give the detail page real
context instead of just a hero and a field grid:
- Tutor picker options now show active student count ("2 active
students" / "No students yet") next to subjects, computed client-side
from the assignments list already fetched -- no new endpoint.
- Assignment schema gains a denormalized `assignedBy: { id, name }`
(repository/controller/types), shown as "Assigned by X on <date>" under
the detail page's pairing hero.
- AssignmentDetail redesigned per the approved stacked-sections mockup:
hero -> a bordered facts row (Subjects/Assigned/Ended) -> "<tutor> is
also tutoring" (their other active students, cross-referenced from the
full assignments list) -> "History for <student>" (a timeline of every
assignment that student has had, not just the one being viewed).
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Selectoptions now show active student count ("2 active students" / "No students yet") alongside subjects, so an admin can see caseload before assigning another student. Computed client-side from theassignmentslist the create form already fetches -- no new endpoint.assignedByon Assignment: schema/repository/controller/types gain a denormalizedassignedBy: { id, name }(the relation already existed on the Prisma model, just wasn't joined/exposed). Shown as "Assigned by X on <date>" under the detail page's hero.GET /assignmentslist, cross-referenced client-side -- same pattern as the reassignment warning from the last PR.Test plan
pnpm -r typecheck/pnpm -r lintclean across the whole monorepopnpm --filter web test-- 109/109 passing (new coverage for workload meta, assignedBy, the "also tutoring" card, and the history timeline)pnpm --filter api test-- 127/127 passing (assignedBy join covered in service/route tests)pnpm --filter web build/pnpm --filter api buildclean