Skip to content

UIEUS-523: Show 'Please enter a valid date' instead of 'Required' for invalid periodic harvesting start date#632

Merged
slaemmer merged 1 commit into
masterfrom
UIEUS-523
Jun 11, 2026
Merged

UIEUS-523: Show 'Please enter a valid date' instead of 'Required' for invalid periodic harvesting start date#632
slaemmer merged 1 commit into
masterfrom
UIEUS-523

Conversation

@slaemmer

Copy link
Copy Markdown
Contributor

Fixes UIEUS-523.

On the periodic harvesting form, entering an invalid start date such as 2026-10-77 showed the validation message "Required" even though the field was not empty. The Datepicker commits an unparseable entry as an empty value, so the required validator could not distinguish an invalid entry from an empty field.

Changes

  • Add requiredValidDate validator that returns a localized "Please enter a valid date" for an empty/invalid value and use it on the start-date field
  • Add translation key errors.enterValidDate
  • Add unit tests for the validator and the form's invalid-date case

@slaemmer slaemmer requested a review from a team as a code owner June 10, 2026 10:19
@github-actions

github-actions Bot commented Jun 10, 2026

Copy link
Copy Markdown

Jest Unit Test Results

219 tests  +3   219 ✅ +3   2m 47s ⏱️ +12s
 39 suites ±0     0 💤 ±0 
  1 files   ±0     0 ❌ ±0 

Results for commit 7e04816. ± Comparison against base commit de7ca35.

♻️ This comment has been updated with latest results.

@sonarqubecloud

Copy link
Copy Markdown

@alb3rtino alb3rtino changed the title UIEUS-513: Show 'Please enter a valid date' instead of 'Required' for invalid periodic harvesting start date UIEUS-523: Show 'Please enter a valid date' instead of 'Required' for invalid periodic harvesting start date Jun 10, 2026
@slaemmer slaemmer merged commit 9e562cb into master Jun 11, 2026
24 checks passed
@slaemmer slaemmer deleted the UIEUS-523 branch June 11, 2026 06:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants