-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Normal
-
None
-
Affects Version/s: 10.2.0
-
Component/s: Components
-
None
-
None
Steps to Reproduce
Use
<datebox constraint="no empty" valueInLocalDate="@bind(date)"/>
When you bind to value attribute, the constraint will only be validated on save. But for valueInLocalDate it is also validated on load.
Checkout:
https://zkfiddle.org/sample/3vrn709/1-datebox-with-constraint
Current Result
When opening the form and date is null, you'll get a
org.zkoss.zk.ui.WrongValueException: This field may not be empty or contain only spaces.
Expected Result
Not to validate the constraint on loading the data. but on saving.
Debug Information
Workaround