Details
-
Bug
-
Resolution: Fixed
-
Major
-
3.0.1
-
None
Description
Currently, dialog controls marked as required can still be empty.
Patches have been provided by MAGNOLIA-1119 and MAGNOLIA-1361 and are summarized/improved in the attached patch.
One of the problems with these patches is that the validation code was called during rendering: as a result mandatory fields were immediately marked "red", and the user did not have any indication of what was wrong anymore after a failed validation, since nothing changed visually. It also removed the alert box, which while not being the most sexy device was a way of saying to the user that something was wrong. (if the missing required field was in another tab, the user would just see nothing)
To fix this, I introduced the "wasValidatedOrNotSaved" field in DialogControlImpl.
Another problem is that a file control would loose its file upon failed validation and the user would thus have to reselect and reupload it. while that's viable with simple dialogs, it is not in more complex scenarios where multiple files are involved.
Checklists
Attachments
Issue Links
- supersedes
-
MAGNOLIA-1361 validation check for missing required field stops after first field
-
- Closed
-