Skip to content

Commit

Permalink
Bug fix: Add units to lab component values (#2920)
Browse files Browse the repository at this point in the history
* update fhir path to include units of value for labs

* add to snapshot test bundle

* fix mistake in lab bundle for snapshot test

* one more nit

* update path to dynamically add spaces btwn units, add comment

* Update comment location for observationValue

Co-authored-by: Mary McGrath <[email protected]>

---------

Co-authored-by: Mary McGrath <[email protected]>
  • Loading branch information
angelathe and mcmcgrath13 authored Nov 19, 2024
1 parent 70735e9 commit 0d45dfb
Show file tree
Hide file tree
Showing 3 changed files with 138 additions and 2 deletions.
3 changes: 2 additions & 1 deletion containers/ecr-viewer/src/app/api/fhirPath.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,8 @@ specimenReceivedTime: "Observation.extension[0].extension.where(url = 'specimen
specimenSource: "Observation.extension[0].extension.where(url = 'specimen source').valueString"
observationReferenceValue: "Observation.extension[0].extension.where(url = 'observation entry reference value').valueString"
observationComponent: "code.coding.display.first()"
observationValue: (valueQuantity.value.toString() | valueString | valueCodeableConcept.coding.display | iif(interpretation.coding.display.exists(), ' (' | interpretation.coding.display | ')', '')).join('')
# observationValue logic: <value> <units> (<interpretation>)
observationValue: (valueQuantity.value.toString() | valueString | valueCodeableConcept.coding.display | iif(valueQuantity.unit.exists(), iif(valueQuantity.unit = '%', valueQuantity.unit, ' ' | valueQuantity.unit), '') | iif(interpretation.coding.display.exists(), ' (' | interpretation.coding.display | ')', '')).join('')
observationReferenceRange: "referenceRange.text"
observationDeviceReference: "device.reference"
observationNote: "note.text"
Expand Down
Loading

0 comments on commit 0d45dfb

Please sign in to comment.