-
Notifications
You must be signed in to change notification settings - Fork 25
Description
Describe the bug
3 items in the CVD risk section of the Aboriginal and Torres Straight Islander Health Check are not populating correctly according to their calculatedExpressions. The items affected have the following linkIds:
- cvdrisk-bmi-weight-decimal
- cvdrisk-bmi-height-decimal
- 818ce640-c8dd-457d-b607-3aaa8da38524
Their calculated expressions should be populated with a newly added value from another item if it exists, otherwise populate with a different value from another item.
E.g. iif(%weight.exists() and %CVDWeightNewResultDate > (now() - 12 months), %weight, %bmiWeightDecimalPrepop)
This expression does not result in the item being populated with %weight value even though the conditional criteria is met. Instead %bmiWeightDecimalPrepop is used.
To Reproduce
- Open Aboriginal and Torres Straight Islander Health Check in playground
- Prepop using patient "CVDRisk-DS-AdamPopper-Patient"
- Go to "Absolute cardiovascular disease risk calculation" section
- Observe values of items: Systolic blood pressure, Weight and Height. These are the last result values of the examination section items: Blood pressure (systolic), Height and Weight. This is correct behaviour.
- Now, in the examination section, add new results for items: Blood pressure (systolic), Height and Weight.
- Go back to "Absolute cardiovascular disease risk calculation" section and note the values have not been updated with these new values as expected.
- If you look at the fhirPathContext tab in the Playground's advanced properties, you will see the variables are being correctly updated, however in the calculatedExpressions tab you can see, the expression is not returning the expected result.
Expected behavior
New values entered should update the CVD risk section items: Systolic blood pressure, Weight and Height