A domain maps its own studies to FHIR; TEA's served resources pass the validator
This commit is contained in:
@@ -310,7 +310,12 @@ def _studies(domain: Domain, persons: list[str], at: str) -> list[Resource]:
|
||||
by `at`: its DiagnosticReport (or Encounter) and Observations, in date order."""
|
||||
found: list[Resource] = []
|
||||
report_facts = _clinical(domain).REPORT_FACTS
|
||||
own = getattr(part(domain, "fhir"), "STUDIES", {}) # studies the domain maps itself
|
||||
for study in catalog.of_domain(domain.value):
|
||||
if study in own:
|
||||
found += own[study](lambda kind: reads.rows(domain.value, kind, persons=persons,
|
||||
cutoff=at)) # fmt: skip
|
||||
continue
|
||||
spec = catalog.studies()[study]
|
||||
facts = {}
|
||||
if kind := report_facts.get(study):
|
||||
|
||||
Reference in New Issue
Block a user