users@woodstock.java.net

Re: How to handle validation errors in a Table custom filter panel

From: Brett M. Bergquist <bbergquist_at_canoga.com>
Date: Thu, 21 Aug 2008 11:06:24 -0400

 From the server side ManagedBean, is there a way to cause the Faces
Filter Panel to be opened? If I can do that, I can cause the panel to
be displayed as opened if there is validation errors.

Brett M. Bergquist wrote:
> I have defined a custom filter panel and setup a Table to display this
> panel using the proper facets of the table. This is working okay.
> The problem that I am having is that inside the panel I have various
> fields that are subject to conversion and validation. For example, I
> have a text input field with an integer conversion and a range
> validator associated with it.
>
> If the user enters a non-integer value or one out of range and then
> hits my submit button on the custom filter panel, the panel closes but
> the form now has validation errors. The drop down shows "Custom
> Filter" but there is no place for the user to figure out that the
> panel has errors and has to change the drop down to some other value
> and then back to "Custom Filter" to get the custom filter panel to
> display again and show the field validation errors.
>
> Now since the custom filter panel is part of the main form, none of
> the actions on the form work since the custom filter panel has
> validation errors.
>
> I really need to do the validation on the server side and not the
> client side.
>
> So what is the proper way to handle this. I really would like the
> user to see that there is field validation errors and either correct
> them.
>
> Any suggestions will be welcome!
>
> Brett
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_woodstock.dev.java.net
> For additional commands, e-mail: users-help_at_woodstock.dev.java.net
>
>
>