Hi,
an other solution is to add a NullAcceptingValidator to your Textfield.
Thus wicket will pass to IValidator.validate(IValidatable)
See
http://ci.apache.org/projects/wicket/apidocs/6.0.x/org/apache/wicket/validation/INullAcceptingValidator.html
Cheers Fred
Am 14.02.2013 00:55, schrieb
Thanks Fred, that's what I found yesterday night after hours of
searching, too. However, I think I'll go with Sebastiens approach,
because it unifies converter and validation check.
Thanks to both of you!
2013/2/14 Fred!!! schreibf...@googlemail.com:
Hi,
an other solution is to add a
I have a TextField which overrides it's getConverter method to add a
Joda time converter instead:
new TextFieldP(id) {
@Override
public P IConverterP getConverter(ClassP type) {
return (IConverterP) new JodaDateTimeConverter();
}
};
The converter returns null if input was
Hi,
Well, the required flag ensures that the input is not empty, not that it is
of the correct type...
If the conversion fails, is it supposed (I guessed) to throw a
ConversionException.
As it seems to not be the case, I would have overridden convert input as
follow (not tested):
class