-
Notifications
You must be signed in to change notification settings - Fork 250
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add fhirpath supplements #2346
Add fhirpath supplements #2346
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hi maimoona - thanks for this great work!
datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/FhirPathUtil.kt
Show resolved
Hide resolved
...ture/src/test/java/com/google/android/fhir/datacapture/enablement/EnablementEvaluatorTest.kt
Outdated
Show resolved
Hide resolved
datacapture/src/test/java/com/google/android/fhir/datacapture/QuestionnaireViewModelTest.kt
Outdated
Show resolved
Hide resolved
datacapture/src/main/java/com/google/android/fhir/datacapture/mapping/ResourceMapper.kt
Outdated
Show resolved
Hide resolved
datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/FhirPathUtil.kt
Outdated
Show resolved
Hide resolved
datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt
Outdated
Show resolved
Hide resolved
datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt
Outdated
Show resolved
Hide resolved
datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt
Show resolved
Hide resolved
datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/FhirPathUtil.kt
Show resolved
Hide resolved
datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt
Outdated
Show resolved
Hide resolved
…fhirpath/ExpressionEvaluator.kt Co-authored-by: Jing Tang <[email protected]>
…fhirpath/ExpressionEvaluator.kt Co-authored-by: Jing Tang <[email protected]>
i don't hink this pr builds with the latest changes. can you fix please @maimoonak? thanks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please double-check the code paths going through evaluateExpression
and evaluateVariable
and see if there's any more unification you can do.
Thanks for this PR! Great job!
...apture/src/test/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluatorTest.kt
Outdated
Show resolved
Hide resolved
Head branch was pushed to by a user without write access
…fhirpath/ExpressionEvaluatorTest.kt Co-authored-by: Jing Tang <[email protected]>
#2373 The methods are covered by a good amount of test which indeed is important to ensure complex variable evaluation validation. We need to figureout a way to keep unit tests. (VisibleForTesting annotation not working) |
* Add fhirpath supplements * Add unit tests * Update datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt Co-authored-by: Jing Tang <[email protected]> * Update datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt Co-authored-by: Jing Tang <[email protected]> * Resolve feedback and test issues * Fix compile issue * Update datacapture/src/test/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluatorTest.kt Co-authored-by: Jing Tang <[email protected]> * Rename tests --------- Co-authored-by: Jing Tang <[email protected]>
* Add fhirpath supplements * Add unit tests * Update datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt Co-authored-by: Jing Tang <[email protected]> * Update datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt Co-authored-by: Jing Tang <[email protected]> * Resolve feedback and test issues * Fix compile issue * Update datacapture/src/test/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluatorTest.kt Co-authored-by: Jing Tang <[email protected]> * Rename tests --------- Co-authored-by: Jing Tang <[email protected]>
* Update questionnaire buttons in xml fragment * Add fhirpath supplements (#2346) * Add fhirpath supplements * Add unit tests * Update datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt Co-authored-by: Jing Tang <[email protected]> * Update datacapture/src/main/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluator.kt Co-authored-by: Jing Tang <[email protected]> * Resolve feedback and test issues * Fix compile issue * Update datacapture/src/test/java/com/google/android/fhir/datacapture/fhirpath/ExpressionEvaluatorTest.kt Co-authored-by: Jing Tang <[email protected]> * Rename tests --------- Co-authored-by: Jing Tang <[email protected]> * Update the Button style * Update styles.xml * Fix styles.xml * Update datacapture/src/main/res/values/styles.xml Co-authored-by: santosh-pingle <[email protected]> * Update datacapture/src/main/res/values/styles.xml Co-authored-by: santosh-pingle <[email protected]> * Run spotlesss --------- Co-authored-by: Maimoona Kausar <[email protected]> Co-authored-by: Jing Tang <[email protected]> Co-authored-by: santosh-pingle <[email protected]>
Fixes ##2163
Description
Support fhirpath supplement %questionnaire, and %qItem literal. This allow to get current questionnaire and item into fhirpath expressions on questionnaire items when doing evaluation. Details for spec defined here https://build.fhir.org/ig/HL7/sdc/expressions.html#fhirpath-supplements .
Type
Choose one: Feature
Checklist
./gradlew spotlessApply
and./gradlew spotlessCheck
to check my code follows the style guide of this project../gradlew check
and./gradlew connectedCheck
to test my changes locally.