changed: returned group display names with user reads #3

Merged
jak merged 1 commit from review/user-group-displays into groups-capabilities 2026-10-20 15:37:50 -04:00
Owner

User reads now return each group's display name along with its name. service.User.Groups is now []service.UserGroup{Name, Display}, filled by joining "group" in every user query.

  • The home page uses the user read directly. The extra ListGroups call is gone.
  • The admin users list shows display names as badges, with the group name as the title.
  • API: each entry in groups on /admin/users responses is now {"name", "display"}, matching the userinfo groups. The CLI prints the JSON, so it needed no change.

Four existing tests had their element comparisons changed from Groups[0] to Groups[0].Name because of the type change. Their assertions are otherwise unchanged. New tests cover display names at the database, service, API, and web layers.

🤖 Generated with Claude Code

User reads now return each group's display name along with its name. `service.User.Groups` is now `[]service.UserGroup{Name, Display}`, filled by joining `"group"` in every user query. - The home page uses the user read directly. The extra `ListGroups` call is gone. - The admin users list shows display names as badges, with the group name as the title. - API: each entry in `groups` on `/admin/users` responses is now `{"name", "display"}`, matching the userinfo groups. The CLI prints the JSON, so it needed no change. Four existing tests had their element comparisons changed from `Groups[0]` to `Groups[0].Name` because of the type change. Their assertions are otherwise unchanged. New tests cover display names at the database, service, API, and web layers. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
User reads now join each membership's group, so 'service.User.Groups' carries
name and display instead of bare names. The home page uses that directly and no
longer lists every group to look up display names. The admin users list shows
display names as badges, with the group name as the badge title.

The admin users API changed shape. Each entry in a user's "groups" is now an
object with "name" and "display", matching the userinfo groups. API clients
that read group names as strings need to read the "name" field instead.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
jak merged commit 12032be4fd into groups-capabilities 2026-10-20 15:37:50 -04:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
pollinator/consent!3
No description provided.