When submitting the general information form, the audit_period_other_months field expects two digits. So a user with an audit period of seven months is expected to enter 07, and not just 7. This results in an error on schema validation that is hard to interpret.
We should either:
Update the regex for audit_period_other_months validation to accept a single character, non-zero response. See here.
Append a zero to the front of single digit values so that they pass schema validation. This can be done either at the form cleaning step, the view post step, or in the general information validation step.
Steps to reproduce the bug
Navigate to the general information form
Select Audit period -> Other
Enter a single digit audit period, such as 7
Verify that an error occurs, and the form comes back with:
a. No/wrong inputted information
b. Incorrectly formatted dates
Expected Behavior
Navigate to the general information form
Select Audit period -> Other
Enter a single digit audit period, such as 7
The form submits and the information is saved, whether it is a single or padded double digit value.
Describe the bug
An example from ZenDesk: https://fac-gov.zendesk.com/agent/tickets/3749
When submitting the general information form, the
audit_period_other_months
field expects two digits. So a user with an audit period of seven months is expected to enter07
, and not just7
. This results in an error on schema validation that is hard to interpret.We should either:
audit_period_other_months
validation to accept a single character, non-zero response. See here.OR
OR
Steps to reproduce the bug
7
Expected Behavior
7
Screenshots
Does not validate, but should.![image](https://github.com/GSA-TTS/FAC/assets/91098850/bfbb6c1c-5c9d-403a-97b0-de90330923c4)
System setup
No response
Additional context
No response
Code of Conduct