FR-U01 Admin-only account creation; public /auth/register removed
FR-U02 Invite token generated on creation and returned in API response (admin copies link; email transport is TBD)
FR-U03 Email/password with invite-token activation implemented; Google Auth deferred per open decision
FR-U04 Deactivate/reactivate via existing active flag; inactive name display handled in frontend
FR-U05 Trainee flag on volunteer accounts; admin can promote (remove flag); completed shift count shown
FR-U06 Admin-only notes field; filtered out of non-admin API responses
New schema columns
is_trainee, phone, operational_roles, notification_preference, admin_notes, last_login, invite_token, invite_expires_at — added via ALTER TABLE … ADD COLUMN IF NOT EXISTS for existing deployments.
New / changed API endpoints
Method
Path
Change
POST
/auth/activate
New — public invite activation
POST
/api/v1/volunteers
New — admin-only account creation
POST
/api/v1/volunteers/{id}/invite
New — admin resend invite
PUT
/api/v1/volunteers/{id}
Updated — role-scoped: volunteers edit name+phone only
- Admin-only account creation (no self-registration); invite-token flow
replaces the public /auth/register endpoint
- New volunteer fields: phone, is_trainee, operational_roles,
notification_preference, admin_notes, last_login, completed_shifts
- Role-scoped profile editing: volunteers update name/phone only;
admins update all fields including notes and trainee flag
- /auth/activate endpoint for invite-token-based account activation
- /api/v1/volunteers/{id}/invite for admin to resend invite links
- last_login recorded on each successful authentication
Tests:
- Go: handler tests (auth rules, create, activate, update scoping) via
Storer/AuthServicer interfaces and fake store; auth unit tests for
HashPassword, IssueToken, and Parse
- Frontend: RTL tests for Activate, Profile, and Volunteers pages
- Fixed CRA 5 + React Router v7 Jest compatibility (moduleNameMapper +
TextEncoder polyfill)
- Replaced stale CRA App.test.tsx placeholder with real tests
CI:
- .gitea/workflows/ci.yml runs go vet, go test, tsc, and npm test on
every push and pull request
Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
npm ci fails when the lock file is missing platform-specific packages
([email protected]) that only get resolved on Linux. Switch to npm install
which resolves dependencies at runtime rather than strictly validating
the lock file.
Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
Implements Issue #1 — User Accounts & Profiles.
/auth/registerremovedactiveflag; inactive name display handled in frontendNew schema columns
is_trainee,phone,operational_roles,notification_preference,admin_notes,last_login,invite_token,invite_expires_at— added viaALTER TABLE … ADD COLUMN IF NOT EXISTSfor existing deployments.New / changed API endpoints
POST/auth/activatePOST/api/v1/volunteersPOST/api/v1/volunteers/{id}/invitePUT/api/v1/volunteers/{id}POST/auth/registerFrontend pages
/activate?token=…— public invite activation page/profile— volunteer self-edit (name + phone)/volunteers— full admin management: create, trainee promotion, notes, invite resendTest plan
.gitea/workflows/ci.ymlrunsgo vet,go test,tsc --noEmit, andnpm teston every push and PRCloses #1
- Admin-only account creation (no self-registration); invite-token flow replaces the public /auth/register endpoint - New volunteer fields: phone, is_trainee, operational_roles, notification_preference, admin_notes, last_login, completed_shifts - Role-scoped profile editing: volunteers update name/phone only; admins update all fields including notes and trainee flag - /auth/activate endpoint for invite-token-based account activation - /api/v1/volunteers/{id}/invite for admin to resend invite links - last_login recorded on each successful authentication Tests: - Go: handler tests (auth rules, create, activate, update scoping) via Storer/AuthServicer interfaces and fake store; auth unit tests for HashPassword, IssueToken, and Parse - Frontend: RTL tests for Activate, Profile, and Volunteers pages - Fixed CRA 5 + React Router v7 Jest compatibility (moduleNameMapper + TextEncoder polyfill) - Replaced stale CRA App.test.tsx placeholder with real tests CI: - .gitea/workflows/ci.yml runs go vet, go test, tsc, and npm test on every push and pull request Co-Authored-By: Claude Sonnet 4.6 <[email protected]>c57f4b67ffto6c9746eb05