integrating latest dashboard changes

This commit is contained in:
Roberto Treviño Cervantes
2026-10-26 01:42:27 -06:00
parent 83c7c7f1d3
commit be9b528c5f
5 changed files with 41 additions and 5 deletions
+2 -1
View File
@@ -114,7 +114,8 @@ ENTITY_REGISTRY: dict[str, EntitySpec] = {
schema=PacientesImportSchema,
model=TeaPacientes,
repository=tea_pacientes_repository,
conflict_fields=None,
# The source's own id; TEA's child tables reference it directly.
conflict_fields=("pac_id",),
),
"cacu.OrdenesEstudio": EntitySpec(
schema=CacuOrdenesEstudioImportSchema,
+5 -1
View File
@@ -1,5 +1,8 @@
"""Import schema for `core.tea.models.Pacientes`. All fields optional, like TEA's
Core; system-managed `pac_created_at`/`pac_updated_at`/`pac_fuente_sistema` are excluded."""
Core; system-managed `pac_created_at`/`pac_updated_at`/`pac_fuente_sistema` are excluded.
`pac_id` is importable: every other TEA table references the patient by the
source system's integer id, so it has to be kept, not renumbered."""
from datetime import date
from typing import Optional
@@ -14,6 +17,7 @@ _PARENTESCO_CATALOG = Catalog(Parentesco)
class PacientesImportSchema(ImportSchema):
pac_id: Optional[int] = None
pac_id_hospital: Optional[str] = None
pac_id_titular: Optional[str] = None
pac_parentesco: CatalogValue(_PARENTESCO_CATALOG) = None