Migrate catalog app to Kotlin Multiplatform#2940
Open
ellykits wants to merge 27 commits intoohs-foundation:masterfrom
Open
Migrate catalog app to Kotlin Multiplatform#2940ellykits wants to merge 27 commits intoohs-foundation:masterfrom
ellykits wants to merge 27 commits intoohs-foundation:masterfrom
Conversation
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
…m factories Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
LZRS
approved these changes
Feb 9, 2026
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Contributor
Author
|
Marked this as ready for review and created an issue to track remaining features that aren't blocking testing questionnaires via catalog application here #2942 |
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Contributor
Author
DataCapture Issues ReportGenerated on: 2026-02-23 1. General
2. ComponentsSlider
Label
Not working
Help Icon
Item Answer Media
3. Layout
4. BehaviorsCalculated expression
Answer expression
Log Snippet java.lang.IllegalStateException: XFhirQueryResolver cannot be null. Please provide the XFhirQueryResolver via DataCaptureConfig.
at com.google.android.fhir.datacapture.expressions.EnabledAnswerOptionsEvaluator.resolveAnswerExpression(EnabledAnswerOptionsEvaluator.kt:200)
at com.google.android.fhir.datacapture.expressions.EnabledAnswerOptionsEvaluator.answerOptions(EnabledAnswerOptionsEvaluator.kt:133)
at com.google.android.fhir.datacapture.expressions.EnabledAnswerOptionsEvaluator.evaluate$datacapture_kmp(EnabledAnswerOptionsEvaluator.kt:92)
at com.google.android.fhir.datacapture.QuestionnaireViewModel.getQuestionnaireAdapterItems(QuestionnaireViewModel.kt:1022)
at com.google.android.fhir.datacapture.QuestionnaireViewModel.getQuestionnaireAdapterItems(QuestionnaireViewModel.kt:971)
at com.google.android.fhir.datacapture.QuestionnaireViewModel.getQuestionnaireAdapterItems$default(QuestionnaireViewModel.kt:964)
at com.google.android.fhir.datacapture.QuestionnaireViewModel.getQuestionnaireState(QuestionnaireViewModel.kt:832)
at com.google.android.fhir.datacapture.QuestionnaireViewModel.access$getQuestionnaireState(QuestionnaireViewModel.kt:104)
at com.google.android.fhir.datacapture.QuestionnaireViewModel$questionnaireStateFlow$1.invokeSuspend(QuestionnaireViewModel.kt:654)
at com.google.android.fhir.datacapture.QuestionnaireViewModel$questionnaireStateFlow$1.invoke(Unknown Source:9)
at com.google.android.fhir.datacapture.QuestionnaireViewModel$questionnaireStateFlow$1.invoke(Unknown Source:20)Skip logic
Log Snippet Process: com.google.android.fhir.catalog, PID: 5853
java.lang.IllegalStateException: Unknown variable: %has
at com.google.fhir.fhirpath.FhirPathEvaluator.visitExternalConstantTerm(FhirPathEvaluator.kt:360)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitExternalConstantTerm(FhirPathEvaluator.kt:62)
at com.google.fhir.fhirpath.parsers.fhirpathParser$ExternalConstantTermContext.accept(fhirpathParser.kt:985)
at org.antlr.v4.kotlinruntime.tree.AbstractParseTreeVisitor.visitChildren(AbstractParseTreeVisitor.kt:41)
at com.google.fhir.fhirpath.parsers.fhirpathBaseVisitor.visitTermExpression(fhirpathBaseVisitor.kt:91)
at com.google.fhir.fhirpath.parsers.fhirpathParser$TermExpressionContext.accept(fhirpathParser.kt:573)
at org.antlr.v4.kotlinruntime.tree.AbstractParseTreeVisitor.visit(AbstractParseTreeVisitor.kt:11)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitAdditiveExpression(FhirPathEvaluator.kt:164)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitAdditiveExpression(FhirPathEvaluator.kt:62)
at com.google.fhir.fhirpath.parsers.fhirpathParser$AdditiveExpressionContext.accept(fhirpathParser.kt:284)
at org.antlr.v4.kotlinruntime.tree.AbstractParseTreeVisitor.visit(AbstractParseTreeVisitor.kt:11)
at com.google.fhir.fhirpath.FhirPathEngine.evaluateExpression(FhirPathEngine.kt:82)
at com.google.android.fhir.datacapture.fhirpath.ExpressionEvaluator.evaluateExpression(ExpressionEvaluator.kt:150)
at com.google.android.fhir.datacapture.enablement.EnablementEvaluator.evaluate(EnablementEvaluator.kt:150)
at com.google.android.fhir.datacapture.QuestionnaireViewModel.getQuestionnaireAdapterItems(QuestionnaireViewModel.kt:988)
at com.google.android.fhir.datacapture.QuestionnaireViewModel.getQuestionnaireAdapterItems(QuestionnaireViewModel.kt:971)
at com.google.android.fhir.datacapture.QuestionnaireViewModel.getQuestionnaireAdapterItems$default(QuestionnaireViewModel.kt:964)Dynamic question
Questionnaire constraint
Log Snippet FATAL EXCEPTION: main (Fix with AI)
Process: com.google.android.fhir.catalog, PID: 5918
java.lang.IllegalStateException: Unknown variable: %context
at com.google.fhir.fhirpath.FhirPathEvaluator.visitExternalConstantTerm(FhirPathEvaluator.kt:360)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitExternalConstantTerm(FhirPathEvaluator.kt:62)
at com.google.fhir.fhirpath.parsers.fhirpathParser$ExternalConstantTermContext.accept(fhirpathParser.kt:985)
at org.antlr.v4.kotlinruntime.tree.AbstractParseTreeVisitor.visitChildren(AbstractParseTreeVisitor.kt:41)
at com.google.fhir.fhirpath.parsers.fhirpathBaseVisitor.visitTermExpression(fhirpathBaseVisitor.kt:91)
at com.google.fhir.fhirpath.parsers.fhirpathParser$TermExpressionContext.accept(fhirpathParser.kt:573)
at org.antlr.v4.kotlinruntime.tree.AbstractParseTreeVisitor.visit(AbstractParseTreeVisitor.kt:11)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitInvocationExpression(FhirPathEvaluator.kt:110)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitInvocationExpression(FhirPathEvaluator.kt:62)
at com.google.fhir.fhirpath.parsers.fhirpathParser$InvocationExpressionContext.accept(fhirpathParser.kt:487)
at org.antlr.v4.kotlinruntime.tree.AbstractParseTreeVisitor.visit(AbstractParseTreeVisitor.kt:11)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitInvocationExpression(FhirPathEvaluator.kt:110)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitInvocationExpression(FhirPathEvaluator.kt:62)
at com.google.fhir.fhirpath.parsers.fhirpathParser$InvocationExpressionContext.accept(fhirpathParser.kt:487)
at org.antlr.v4.kotlinruntime.tree.AbstractParseTreeVisitor.visit(AbstractParseTreeVisitor.kt:11)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitEqualityExpression(FhirPathEvaluator.kt:218)
at com.google.fhir.fhirpath.FhirPathEvaluator.visitEqualityExpression(FhirPathEvaluator.kt:62)
at com.google.fhir.fhirpath.parsers.fhirpathParser$EqualityExpressionContext.accept(fhirpathParser.kt:516)
at org.antlr.v4.kotlinruntime.tree.AbstractParseTreeVisitor.visit(AbstractParseTreeVisitor.kt:11)
at com.google.fhir.fhirpath.FhirPathEngine.evaluateExpression(FhirPathEngine.kt:82)
at com.google.android.fhir.datacapture.fhirpath.ExpressionEvaluator.evaluateExpression(ExpressionEvaluator.kt:150)
at com.google.android.fhir.datacapture.fhirpath.ExpressionEvaluator.evaluateExpression$default(ExpressionEvaluator.kt:145)
at com.google.android.fhir.datacapture.validation.ConstraintItemExtensionValidator.validate(ConstraintItemExtensionValidator.kt:77)
at com.google.android.fhir.datacapture.validation.QuestionnaireResponseItemValidator.validate(QuestionnaireResponseItemValidator.kt:55) |
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
7 tasks
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Move all the evaluate and support functions to a utility object to be reused. Also handle exceptions thrown by the Kotlin fhir path if evaluation fails. Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
* Multiple fixes - Fix slider moving maximum set value - Update answer extension validators to correctly check evaluated cqf-calculatedValue expressions - Include FileKit in LicenseeConfig * Fix population of questionnaire initial value * Replace help icon to outlined * Fix submit button not accepting subsequent clicks * Fix ReadOnly review screen * Fix validation error message dialog not showing * Update MaxValueValidatorTest and address PR comments * Remove redundant TestExpressionEvaluator
Delete xml layout, color, style and theme files Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
…hir into catalog-kmp-migration Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
* Fix validation on group based questionnaires * Use LaunchedEffect Unit to set onsubmitclicklistener * Use layout_review for layout readonly item * Remove reflection-api based message for sliderviewfactory
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Contributor
Author
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
Signed-off-by: Elly Kitoto <junkmailstoelly@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



IMPORTANT: All PRs must be linked to an issue (except for extremely trivial and straightforward changes).
Fixes #2941
Description
Clear and concise code change description.
Alternative(s) considered
Have you considered any alternatives? And if so, why have you chosen the approach in this PR?
Type
Choose one: (Bug fix | Feature | Documentation | Testing | Code health | Builds | Releases | Other)
Screenshots (if applicable)
Checklist
./gradlew spotlessApplyand./gradlew spotlessCheckto check my code follows the style guide of this project../gradlew checkand./gradlew connectedCheckto test my changes locally.