flexion / ef-cms

An Electronic Filing / Case Management System.
23 stars 10 forks source link

Update Calendar Component #10428

Open mwestereng1 opened 1 month ago

mwestereng1 commented 1 month ago

As a Dawson user, so that I don’t see unnecessary error messages, I need date pickers to disallow certain dates to be selectable.

Currently, there are several fields and document types that allow a user to select a future date from the date picker for selections when a future date is not a valid option. When those dates are validated upon saving or submitting, the user receives an error message.

Link to the document detailing the future date allowed instances

A review with developers, revealed and led to the following conclusions:

Pre-Conditions:

List of everywhere we use both date picker components

Acceptance Criteria (the following acceptance criteria will apply once the date picker components are consolidated):

Pain Avoided/Frustration Saved: Prevents users from selecting an incorrect date and receiving an error message.

Breadth/Pervasiveness of Problem:

Complexity of Problem (Low, Medium, High) and Why it's Complex: Low

Mwindo commented 1 month ago

We use two very similar but distinct components: DateRangePickerComponent and SearchDateRangePickerComponent. I am not sure what the motivation underlying this distinction is, if any; I would like to consolidate them. I'll ask the team about this on Monday.

EDIT: The consensus of the team was to consolidate these components, as long as we test thoroughly.

Mwindo commented 1 month ago

An outline of where these two components are used:

DateRangePickerComponent

SearchDateRangePickerComponent (associated with DateRangeSelect)

There is also a non-range component, used anytime we are selecting a single date. Since there are so many, I have just listed the files:

DateSelector:


- web-client/src/views/CaseAssociationRequest/CaseAssociationRequestDocumentForm.tsx
- web-client/src/views/CaseDetail/CreateCaseDeadlineModalDialog.tsx
- web-client/src/views/CaseDetail/DeficiencyStatisticsForm.tsx
- web-client/src/views/CaseDetail/EditCaseDeadlineModalDialog.tsx
- web-client/src/views/CaseDetail/PetitionPaymentForm.tsx
- web-client/src/views/CaseDetailEdit/CaseInfo.tsx
- web-client/src/views/CaseWorksheet/AddEditCaseWorksheetModal.tsx
- web-client/src/views/CourtIssuedDocketEntry/CourtIssuedDocketEntry.tsx
- web-client/src/views/CourtIssuedDocketEntry/CourtIssuedNonstandardForm.tsx
- web-client/src/views/EditDocketEntry/EditDocketEntryMetaFormCourtIssued.tsx
- web-client/src/views/EditDocketEntry/EditDocketEntryMetaFormDocument.tsx
- web-client/src/views/EditDocketEntry/EditDocketEntryMetaFormNoDocument.tsx
- web-client/src/views/EditDocketEntry/PrimaryDocumentForm.tsx
- web-client/src/views/FileDocument/InclusionsForm.tsx
- web-client/src/views/FileDocument/NonstandardForm.tsx
- web-client/src/views/FileDocument/PrimaryDocumentGeneratedTypeForm.tsx
- web-client/src/views/FileDocument/SupportingDocumentInclusionsForm.tsx
- web-client/src/views/PaperFiling/Inclusions.tsx
- web-client/src/views/PaperFiling/PrimaryDocumentForm.tsx
- web-client/src/views/PendingMotion/AddEditDocketEntryWorksheetModal.tsx
- web-client/src/views/Practitioners/PractitionerForm.tsx
- web-client/src/views/StampMotion/ApplyStamp.tsx
- web-client/src/views/StartCaseInternal/CaseInformation.tsx
- web-client/src/views/StartCaseInternal/StatisticsForm.tsx
- web-client/src/views/StartCaseUpdated/IrsNoticeUploadForm.tsx
- web-client/src/views/StyleGuide/Forms.tsx
- web-client/src/views/TrialSessions/SessionInformationForm.tsx (2 instances, one for start date, one for end date)
- web-client/src/views/IRSNotice.tsx
- web-client/src/views/StatusReportOrder.tsx