Issue Bug Closed

#65227TCE-Form validation behaviour is incomplete for range

Christian Herberger 02/23/15, 10:33 updated 07/30/15, 15:30

Description

When you use a TCA field type select with multiple, minItems 1 and maxItems n, the indicator for the validity of the form field is behaving incorrect:

- You have an empty field: The icon is there (correct)
- You select an element: The icon does not disappear (incorrect)
- You select a second element: The icon does disappear (correct, but too late)
- You remove both selected elements: The icon stays hidden (incorrect)
- You select an element: The icon does appear again (incorrect)

In 4.5 the behaviour was correct.

Research/Debugging showed that in 4.5 there was an onclick event on the Remove Element cross icon, which validated the field instantly and displayed the icon if the field was empty. Also, in 4.5 the event which validates the field after selecting an element was triggered after the element is taken into the selected elements, in 6.2 the validation is run before that moment (thus, the validation runs on an empty list, displays the icon, then the element is selected)

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.