google / android-fhir

The Android FHIR SDK is a set of Kotlin libraries for building offline-capable, mobile-first healthcare applications using the HL7® FHIR® standard on Android.
https://google.github.io/android-fhir/
Apache License 2.0
485 stars 288 forks source link

Adding the option to have the 'Submit' button in the questionnaire instead of outside the questionnaire #1150

Closed PallaviGanorkar closed 2 years ago

PallaviGanorkar commented 2 years ago

Describe the bug In Complete Survey flow, every form has submit button enabled as app is not allowing user to submit input with error message 'inputs are missing' though the data is field on present screen which is quit confusing for user. This behavior is observed till last form. So, submit button is expected to be disabled or submit button should not be there in UI for previous forms, it should only be present on last form where user is actually allowed to submit survey.

Component SDC library, reference app

To Reproduce Steps to reproduce the behavior:

  1. Install and launch the Demo App
  2. let the data download from server and patient list displayed
  3. Select one patient from list where the survey is not yet completed
  4. Click on 'Complete Survey' button
  5. it will onpen Symptoms form for Patient Card
  6. Here 'SUBMIT' button is enabled
  7. Now select option for Symptoms
  8. Click 'SUBMIT' button
  9. See error : 'inputs are missing'

Expected behavior Submit button is expected to be disabled or submit button should not be there in UI for previous forms as user is not allowed to submit survey, it should only be present on last form where user is actually allowed to submit survey.

Screenshots SubmitButtonNotAllowToSubmit

Smartphone (please complete the following information):

PallaviGanorkar commented 2 years ago

@jingtang10 @aditya-07

As discussed with @aditya-07 , Submit button should be removed from SDC and it will be handled in Application by application developer. But issue 1211 and PR 1201 are contradicting with the discussion.

Could you please clarify the requirement to fix this.

jingtang10 commented 2 years ago

is this a duplicate of #1088

jingtang10 commented 2 years ago

@jingtang10 @aditya-07

As discussed with @aditya-07 , Submit button should be removed from SDC and it will be handled in Application by application developer. But issue 1211 and PR 1201 are contradicting with the discussion.

Could you please clarify the requirement to fix this.

discused with @PallaviGanorkar @aditya-07 and @santosh-pingle - we agreed that the option to have submit button inside the qustionnaire is useful, and santosh is working on this as part of #1088. once that change is merged, we will look at removing the submit button in the demo app so that it's using the in-questionnaire submit button. fyi @shelaghm