docs(adr): accept ADR-0026 + ADR-0027 #219
Reference in New Issue
Block a user
Delete Branch "docs/adr-0026-0027-accept"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Promotes ADR-0026 and ADR-0027 from
proposedtoaccepted. Both shipped asproposedin #217 after the cascade / acteurs_plus source-of-truth audit reshaped the org-hierarchy model. No open questions left on either.No code changes — same shape as #205 (ADR-0025 acceptance).
What lands
docs/decisions/0026-person-user-portal-data-model.mdstatus: proposed → accepted.docs/decisions/0027-portal-side-organisational-hierarchy.mdstatus: proposed → accepted.docs/decisions/README.mdaccepted.CLAUDE.md0001 → 0027 accepted; two new Architecture bullets ("Portal-side identity model" and "Portal-side organisational hierarchy") added after the ADR-0025 bullet; ADR-0025's bullet adjusted to clarify the scope literaletablissement:<structure-code>(with a pointer to ADR-0027 for theStructure.codesemantics); the@RequireScopePrisma-resolver roadmap entry now references both ADRs as accepted with the two-schema-then-resolver phasing.Notes for the reviewer
etablissement:<finess>, which was accurate when ADR-0025 shipped but is now superseded by ADR-0027'sStructure.codesemantics (FINESS for medico-social rows, internal slugs otherwise). The change is<finess>→<structure-code>+ asee ADR-0027parenthetical. No actual decision in ADR-0025 changes.entraOid-only v1 dedup and the non-uniquePerson.email(both decisions made during the split rework); the "Portal-side organisational hierarchy" bullet calls out theStructure.coderound-trip semantics and the deferred-to-ADR-0028 items (Pole,Service, arbitrary nesting, per-source enrichment, full cascade sync).pnpm ci:checkimpact.pnpm exec prettier --checkclean on the four touched files.Test plan
pnpm exec prettier --check— clean on the four touched files.ADR-0028dangling marker left intentional for the future sync ADR).What's next
Now unblocked — per ADR-0026 §"Phasing" and ADR-0027 §"Phasing":
Region/Delegation/StructurePrisma schema + inline reference-data migration (Région Nouvelle-Aquitaine + Délégation 33 + a handful of test-tenant structures) +Structure.kindcatalogue + drift-gate extension. Independent of (2) at the schema level.Person/User/UserScopePrisma schema +PersonAndUserProvisionercalled fromSessionEstablisher+Person.sourcecatalogue + drift-gate extension + updatedPrincipalBuilderpopulatingPrincipal.user.{id, personId}from the real rows. Can ship in parallel with (1).PrismaScopeResolverreplacingStubScopeResolver+/admin/users/:id/scopesadmin-app screen +prisma/seed.tspopulating the 19 test personas'user_scopespernotes/test-tenant-role-assignments.md. Depends on both (1) and (2).Pole,Service, per-source enrichment).