your form component panel should check if any of its children have
error messages as well. use a visitor.

-igor


On Wed, Jan 26, 2011 at 8:32 AM, Sam Zilverberg <samzilverb...@gmail.com> wrote:
> I have a FormComponentPanel that represents a Time object - not
> java.sql.Time but my own Time object.
> This Time object has 2 fields - hours and minutes.
> The panel has textfields for the hours and minutes that are defined as class
> type Integer.
>
> I have a behavior on the panel that whenever it has error feedback messages
> it is added a css class that show a red border around it.
> This works when I explicitly call panel.error("some error"). I do this when
> the hour field is empty and the minutes field has a value.
> But when I put an illegal Integer into the one of the textfields the
> feedback error message is registered with the textfield so the
> invalid-css-behavior doesn't trigger.
>
> Is there a simple way to tell a form component to register all of it's
> messages with some other form component -  in this case the panel?
> Are there any other suggestion to get this desired behavior?
>
> Thanks
> -Sam
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to