Phase 13, part 7: the platform's own admin

The people running the multi-tenant service (SUPERMARKET_PLATFORM_ADMINS,
with two-factor sign-in) see every team at /platform with its size, people
and what failed lately, and can suspend or restore a team, resend its
invitations and release its domain. They don't see a team's data unless
they view as it: with a reason, for at most an hour, read-only, recorded in
the team's own audit log.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-25 12:35:53 -07:00
co-authored by Claude Opus 5.5
parent 76407cdea8
commit d35ed7cbb2
15 changed files with 459 additions and 10 deletions
+3
View File
@@ -40,6 +40,7 @@ var routeAreas = map[string]string{
"=/profile": areaSignedIn, "=/core": areaSignedIn,
"/settings": areaAdmin,
"/platform": areaPlatform,
// Signing in to a posting account: admins for the company's, anyone
// with Content for their own (oauthStart checks which).
"/auth": areaSignedIn,
@@ -91,6 +92,8 @@ func (v *viewer) can(area string, write bool) bool {
return v.User != nil || v == localOwner
case areaAdmin:
return v.Member.Admin()
case areaPlatform:
return v.Platform
}
return v.Member.Can(area, write)
}