Closed nanometrenat closed 4 years ago
Note that (strangely) the other way is fine - but shouldn't be! By that I mean, there is nothing to stop me submitting figures but without selecting a source. If I do that I can submit the FR but the figures I've input just completely disappear.
Suggest also adding validation such that if the user inputs a figure then they MUST select a source.
In addition Health would like the following logic for Numeric details on the epi Field Report: EPI Field Report Form design (page 2)
Issue
I can't replicate this in Staging however saw for myself that the problem was happening in Production, when a colleague was trying to submit a field report last night.
User was getting the error "Error: Could not submit field report" and could not figure out why - country was valid and all data looked valid.
I looked in user's console and could see that create_field_report was returning a 400 error, with the message {other_num_displaced: ["A valid integer is required"!}
Looking back through the screens of the user's in-progress field report I could see that the user had selected a "source" radio button for the Affected on the Situation screen, but had not input a number. As the user cannot de-select a radio button once they have selected one, they must put in a figure (e.g. 0) or they cannot submit.
Possible fixes could be:
Steps to reproduce
Related feature
Several other field report tickets open but don't think related.
Impact
Low incidence
Severity
Users cannot submit field report if they hit this, and don't know why
Is there a workaround?
Can put a dummy zero in (if they know to do that)