Show instructor real name or nickname in group-class views, not the login
CI / Tests (PHP 8.2) (pull_request) Successful in 46s
CI / Tests (PHP 8.1) (pull_request) Successful in 46s
CI / No Debug Code (pull_request) Successful in 2s
CI / PHPStan (pull_request) Successful in 2m47s
CI / Coding Standards (pull_request) Successful in 2m51s
CI / Tests (PHP 8.3) (pull_request) Successful in 2m41s
CI / Build Plugin Zip (pull_request) Skipped
CI / Tests (PHP 8.2) (pull_request) Successful in 46s
CI / Tests (PHP 8.1) (pull_request) Successful in 46s
CI / No Debug Code (pull_request) Successful in 2s
CI / PHPStan (pull_request) Successful in 2m47s
CI / Coding Standards (pull_request) Successful in 2m51s
CI / Tests (PHP 8.3) (pull_request) Successful in 2m41s
CI / Build Plugin Zip (pull_request) Skipped
Add Auth\UserName::format(), which prefers a user's first + last name, then their nickname, avoiding display_name (which can be the login/username). Route the instructor name through it in both the front-end offerings response (instructor_name) and the back-end group-class summary and details views. Tests: composer test (513), composer lint, composer cs all pass. Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
@@ -22,8 +22,10 @@ A group class offering carries `term_start`/`term_end` plus a `class_time` and a
|
||||
owning `instructor_id` (see `offerings.md`): one-off classes end the day they
|
||||
start; weekly classes run a set number of sessions, all at `class_time`. The class
|
||||
card on the enrolment page shows **when** the class meets (the date or date range
|
||||
plus the start time) and **who** teaches it (the assigned instructor's display
|
||||
name, surfaced as `instructor_name` on the `GET /offerings` response).
|
||||
plus the start time) and **who** teaches it (the assigned instructor's name,
|
||||
surfaced as `instructor_name` on the `GET /offerings` response). Instructor names
|
||||
in the group-class views (front and back end) use the instructor's real name
|
||||
(first + last) or nickname, never their login — see `Auth\UserName::format()`.
|
||||
|
||||
Assigning an instructor to a scheduled class removes that instructor's open
|
||||
booking slots at the class time and flags any already-booked lesson that clashes;
|
||||
|
||||
Reference in New Issue
Block a user