-
Type:
Task
-
Resolution: Unresolved
-
Priority:
Medium
-
Affects Version/s: None
-
None
Background
The Diagnostic screen has a “Referred to sputum collection” flow. Under the Referral section, the NAAT Test section captures whether sputum was collected.
Current Behavior-
We are not collecting the sputum date as of now. **
Expected Behaviour / Requirement
When “Sputum Collected” = “Yes”:
- Enable the “Sputum Sample Collection Date” field.
- Default the date to today.
- Do not allow future dates.
- Allow back dates only up to one day (yesterday).
User Story
As a field user, I want the sputum collection date to default to today and allow only valid dates, so that wrong dates are not entered.
Acceptance Criteria
- Given “Sputum Collected” = “Yes”, then the date field is enabled and pre-filled with today’s date.
- Given the date field, when I pick today or yesterday, then it is accepted.
- Given the date field, when I try to pick a future date, then it is blocked.
- Given the date field, when I try to pick a date older than yesterday, then it is blocked.
- Given “Sputum Collected” is not “Yes”, then the date field stays disabled.
Business Rules / Validations
- Allowed range: yesterday to today.
- Default value: today.
- Enabled only when “Sputum Collected” = “Yes”.