Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

Populating drop-down options in FHIR Core from Resources in DB #2463

Closed
allan-on opened this issue Jun 15, 2023 · 0 comments
Closed

Populating drop-down options in FHIR Core from Resources in DB #2463

allan-on opened this issue Jun 15, 2023 · 0 comments
Labels
Discussion This is an open discussion that may or may not lead to actionable points Help Wanted Extra attention is needed Scoping Ongoing

Comments

@allan-on
Copy link
Contributor

Feature request

Syncing location (hierarchy) data from the server and populating drop-down options in a Questionnaire

Context

In Questionnaires where the user needs to input location-related data such as the name of a physical location or Health Facility tied to a jurisdiction, a selection from a list would offer the best UX.

Implementation

Server-side implementation

The implementation should provide syncing of location data from the server added through location hierarchy or practitioner assignments on FHIR Web.

Android FHIR SDK SDC Support

  • Currently, it is only possible to use answerExpressions with an expression that takes a query and populates a drop-down item control. Support was added here Support for answerExpression extension google/android-fhir#1039

  • This means that we can query against a Resource and use the values in a drop-down. This happens on loading of the Questionnaire and doesn't support multi-level selections. For instance, in a Questionnaire with multiple (multi-level) location selection options, a prior location selection within the same Questionnaire would not result in a change in the options in the next drop-down

  • With initialExpression x-fhir-query support that will be introduced in Initial expression with x-fhir-query support google/android-fhir#2036 it'll be possible to Query for and set an initially selected option

FHIR Core implementation

  • On FHIR Core we'd need to sync & persist the Location data using the location/practitioner details API.
    • We'll also need a menu option to trigger syncing of locations/hierarchy manually whenever assignment updates are done on FHIR Web
    • There might be performance implications depending on the amount of data that is being synced.
      • Might be beneficial to be able to define which locations to sync in the hierarchy defined

a) Drop-down selection

b) Multi-level selections

  • To implement multi-level selections that facilitate This would need SDK support for answerExpressions to work with an already loaded Questionnaire

Additional Context

See Loading of data on SDC widgets meeting notes

@allan-on allan-on added Help Wanted Extra attention is needed Discussion This is an open discussion that may or may not lead to actionable points Scoping Ongoing labels Jun 15, 2023
@opensrp opensrp locked and limited conversation to collaborators Jun 16, 2023
@allan-on allan-on converted this issue into discussion #2467 Jun 16, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
Discussion This is an open discussion that may or may not lead to actionable points Help Wanted Extra attention is needed Scoping Ongoing
Projects
None yet
Development

No branches or pull requests

1 participant