Feat/organizations backend#5
Merged
Merged
Conversation
…esolution and server permission check
…er, remove, get) + last-owner guard
…ver add-by-id + multi-owner guard
…eate on organizations_enabled; add i18n key
…e dash Switch every page/section title from the Fraunces serif to the existing Geist sans stack and remove the magenta rule mark that preceded titles. - theme: drop --font-serif var; MuiDialogTitle uses var(--font-sans) - index.html: remove Fraunces from the Google Fonts import - replace var(--font-serif) -> var(--font-sans) across all title usages - remove the 28x2 dash in PageHeader (covers all PageHeader pages), the inline dash in AppUsers, and the rule in NotFound Kept: eyebrow accent dots and the active-tab indicator.
The 'Organizations enabled' toggle now applies to every app in a project instead of a single app. The flag stays a per-app column (no schema change); the value is duplicated across the project's apps and kept in sync, so all read/enforcement paths are unchanged. - repo: add SetProjectOrganizationsEnabled (bulk-update every app in a project, scoped to workspace+project); persist organizations_enabled in InsertApp; remove the now-unused single-app UpdateAppOrganizationsEnabled - api: HandleUpdateAppOrganizationsEnabled validates the addressed app, bulk-sets the whole project, and returns that app; new apps inherit the project value (any sibling enabled -> enabled) - ui: toggle help copy + success toast reflect project scope
Add an ID column (with copy-to-clipboard) between Name and Slug in the app organizations admin table. Slug is retained as-is; the ID display mirrors the existing App ID pattern in AppDetail.
ServerUpdateOrganization now silently re-derives the slug from the new name (or honors an explicit slug), running it through a collision-safe -2/-3 loop via the new UpdateOrganizationWithUniqueSlug repo method. Renaming to the same name is idempotent (a row's own slug is not a collision), so no spurious suffix is appended. Slug collisions resolve to a suffix instead of a 409. The admin rename endpoint is unchanged and still preserves the slug. Pier (which sends name-only on rename) gets silent re-slugging with no client changes.
ServerDeleteOrganization now requires ?actorUserId and verifies that user is an active owner of the org: 400 if absent, 403 if not an owner, 204 on success. The auth server becomes the referee, so a backend can't let an admin-tier member delete a tenant.
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.
No description provided.