Hi, I have a page with several validation constraints : Required,
NumberValidator.minimum(...), ... and a FeedBackPanel to display
corresponding error messages.
When not overriding the default submission method, the validation works
perfectly and the error messages are displayed upon submission on the
FeedBackPanel.
The issue is that I have to call a custom business code when the form is
submitted, and then redirect to another page. So I overrid the onSubmit()
method like this :
Button uploadButton = new Button("uploadButton") {
private static final long serialVersionUID = 1L;
@Override
public void onSubmit() {
// The business code call
setResponsePage(ThePageAfterSubmission.class);
}
}.setDefaultFormProcessing(false);
The problem is that now the form doesn't go through validation anymore.
What's the solution?
--
View this message in context:
http://www.nabble.com/Form-validation-when-using-custom-onSubmit%28%29-tp17315177p17315177.html
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]