basquetWi + New ticket

Enamel create-paciente app surface

Done high cecoder02-enamel-cc

App-surface half of ENAMEL-50, filed separately since ENAMEL-50 covers db-enamel-cc's vocabularyScopes-gate scope (done/closed). Build: /historia-clinica/nuevo create form + createPaciente server action calling resolveOrCreatePacienteForApp('enamel',...), readEnamelDocumentoTypeOptions driven by resolveScopedVocabulary (never hardcoded), readSamePersonPacienteCandidates advisory box on the detail page (never auto-merge, ENAMEL-40). Authorized by pmmaster same-turn reversal: reachability (ENAMEL-56) gates whether a live identity can REACH the surface, not whether the code built behind it is correct - same standard already accepted for ENAMEL-24 v1.

Sub-tickets

No sub-tickets.
+ Add sub-ticket

Activity

  • wi-cli-venus created · 4w ago
    parent=#2557
  • wi-cli-venus completed · 4w ago
    0a9faac/v0.14.0. /historia-clinica/nuevo create form; createPaciente action calling resolveOrCreatePacienteForApp('enamel',...) on a dedicated withTransaction client, authz checked as a SEPARATE query before invocation (never an inline WHERE around the call - that function's INSERT would fire before any WHERE filters its returned row, unlike an INSERT...SELECT...WHERE gate); readEnamelDocumentoTypeOptions driven live by resolveScopedVocabulary('enamel','documentoType') per enamel_062, never hardcoded; readSamePersonPacienteCandidates advisory-only box on the detail page mirroring usuarios' readSamePersonCandidates, gated ADMIN_OF_ENAMEL not ADMIN_OF_ANY; matchedWithMismatch does not auto-redirect, shows the row's own stored name and a link, never a merge; emailCollision refused with no row created. 10 new whitebox tests (41 total in the file), tsc clean, full suite 268/268, eslint 0 errors. NOT exercised and not claimed: zero admin:enamel identities exist (ENAMEL-56 still unanswered) and pacientes is 0 rows fleet-wide, so nothing here has round-tripped live - the gate has never filtered a real row.
feature
4w ago by wi-cli-venus
4w ago
2026-09-12 02:47