msupply-foundation / mobile

Open source mobile app for medical inventory control
http://msupply.org.nz/mobile
Other
42 stars 27 forks source link

App crashes when vaccination history of patient (with no additional details) is viewed #4857

Closed nishaDangol-Sussol closed 2 years ago

nishaDangol-Sussol commented 2 years ago

Describe the bug

When we enter vaccination event for a patient and skip the Step 3(additional vaacination details). This is possible if you follow steps here.

To reproduce

Steps to reproduce the behaviour:

  1. Folllow steps here
  2. Now go to Vaccinations>Select that patient history and edit
  3. Notice that Page 2: Additional Details data are missing and the Save Changes button changes to disabled real quick, i.e., it won't let us change the additional details like dose number, vaccination date, anatomical site, etc
  4. Click that patient history again and quickly edit some details, like anatomical site maybe, and save it, before the Save changes button become disabled (you've to do this fast, within 3 seconds if you wanna recreate the crash! )
  5. Now try viewing that patient history again
  6. See error: the app crashes everytime you try to view that patient vaccination history Recording: https://user-images.githubusercontent.com/59193490/183346273-e90b11e8-4f90-4268-bd19-5f4843ec4f86.mp4

Expected behaviour

No crash! I believe this should not be replicable as long as #4820 is fixed!

Proposed Solution

Leave if you don't know how to fix/implement. Edit this issue description and explain here if you know the best path of implementing the fix within the codebase.

Version and device info

Additional context

Pretty much from #4820

sworup commented 2 years ago

@nisha-dangol Might get fixed by #4859 pelase check.

nishaDangol-Sussol commented 2 years ago

@nisha-dangol Might get fixed by #4859 pelase check.

Sure, Let know when the apk is ready and can test there!

nishaDangol-Sussol commented 2 years ago

Tested in latest apk Moving to Done(success) since #4820 cannot be replicated anymore