diff --git a/containers/ecr-viewer/src/app/api/fhirPath.yml b/containers/ecr-viewer/src/app/api/fhirPath.yml index 7f6034ff56..6361e79e1d 100644 --- a/containers/ecr-viewer/src/app/api/fhirPath.yml +++ b/containers/ecr-viewer/src/app/api/fhirPath.yml @@ -2,6 +2,7 @@ patientNameList: "Bundle.entry.resource.where(resourceType = 'Patient').name" patientAddressList: "Bundle.entry.resource.where(resourceType = 'Patient').address" patientTelecom: "Bundle.entry.resource.where(resourceType = 'Patient').telecom" patientCounty: "Bundle.entry.resource.where(resourceType = 'Patient').address.first().county" +patientCountry: "Bundle.entry.resource.where(resourceType = 'Patient').address.first().country" patientIds: "Bundle.entry.resource.where(resourceType = 'Patient').identifier.where(system != 'urn:ietf:rfc:3986').value.join('\n')" patientDOB: "Bundle.entry.resource.where(resourceType = 'Patient').birthDate" diff --git a/containers/ecr-viewer/src/app/services/evaluateFhirDataService.ts b/containers/ecr-viewer/src/app/services/evaluateFhirDataService.ts index c4ab05bce7..646e4fe616 100644 --- a/containers/ecr-viewer/src/app/services/evaluateFhirDataService.ts +++ b/containers/ecr-viewer/src/app/services/evaluateFhirDataService.ts @@ -347,6 +347,10 @@ export const evaluateDemographicsData = ( title: "County", value: evaluate(fhirBundle, mappings.patientCounty)[0], }, + { + title: "Country", + value: evaluate(fhirBundle, mappings.patientCountry)[0], + }, { title: "Contact", value: formatContactPoint(evaluate(fhirBundle, mappings.patientTelecom)), diff --git a/containers/ecr-viewer/src/app/tests/components/Demographics.test.tsx b/containers/ecr-viewer/src/app/tests/components/Demographics.test.tsx index 020f6465cd..d7a39cb759 100644 --- a/containers/ecr-viewer/src/app/tests/components/Demographics.test.tsx +++ b/containers/ecr-viewer/src/app/tests/components/Demographics.test.tsx @@ -35,6 +35,10 @@ describe("Demographics", () => { title: "County", value: "test", }, + { + title: "Country", + value: "USA", + }, { title: "Contact", value: "test contact" }, { title: "Emergency Contact", diff --git a/containers/ecr-viewer/src/app/tests/components/__snapshots__/AccordionContent.test.tsx.snap b/containers/ecr-viewer/src/app/tests/components/__snapshots__/AccordionContent.test.tsx.snap index 2a54fe1720..20fddbc244 100644 --- a/containers/ecr-viewer/src/app/tests/components/__snapshots__/AccordionContent.test.tsx.snap +++ b/containers/ecr-viewer/src/app/tests/components/__snapshots__/AccordionContent.test.tsx.snap @@ -439,6 +439,25 @@ exports[`Snapshot test for Accordion Content Given no data, info message for emp class="section__line_gray" /> +