android-fhir icon indicating copy to clipboard operation
android-fhir copied to clipboard

Refactor the UI validation code in the SDC library

Open jingtang10 opened this issue 4 years ago • 4 comments
trafficstars

Is your feature request related to a problem? Please describe. Two issues:

  1. The UI validation is done by widgets in fairly arbritrary manner. This is bad because there might be divergence in the behaviour of different widgets.
  2. There is currently no way for the application to say - please validate all the answers in the questionnaire and display error messages according before questionnaire submission. We might need a new API for this.

Describe the solution you'd like Discussed in https://github.com/google/android-fhir/issues/374.

Describe alternatives you've considered NA

Additional context Originally posted by @joiskash in https://github.com/google/android-fhir/issues/374#issuecomment-866593973

Would you like to work on the issue? NA

jingtang10 avatar Jun 23 '21 08:06 jingtang10

We should consider pagination (#186) here, too.

As captured in this TODO, we should have an option to validate individual pages when the user clicks next/previous.

However, this shouldn't be required. Eg, if the form is being filled out as a draft, filling out all fields may not be required (or possible). However, when filling out the form in a context in which it will be submitted, the app developer may want to have page 1 validated before moving on to page 2, rather than having pages 1 and 2 validated at submission time.

kevinmost avatar Jun 24 '21 21:06 kevinmost

@aditya-07 have you started working on this? If not I can take it up. Its a high priority item for us.

cc: @jingtang10

joiskash avatar Feb 03 '22 14:02 joiskash

please feel free to go ahead @joiskash and thanks for taking this on

jingtang10 avatar Feb 03 '22 14:02 jingtang10

I am currently occupied with development work related to using the FHIR android SDK. Sorry, I do not have any bandwidth to work on this for the time being.

cc: @jingtang10 @Tarun-Bhardwaj

joiskash avatar Mar 31 '22 07:03 joiskash