wicket-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mscoon <msc...@gmail.com>
Subject IComponentOnBeforeRenderListener and ListView
Date Mon, 24 Nov 2014 12:50:16 GMT
Hi all,

I am using a FormErrorDecorator that implements an
IComponentOnBeforeRenderListener in order to automatically attach a css
class to form components with validation errors (see

Sometimes I want to manually add errors to form components and I was doing
that in onBeforeRender() before the call to super.onBeforeRender(). I do
this because sometimes the object being edited is in an invalid state and I
want to show the validation errors right when the form opens and not after
a submit. This is working fine for most cases as the errors are attached to
the form components before the FormErrorDecorator runs.

However, form components inside a list view are not created until the end
of ListView.onBeforeRender(). This means that I cannot attach errors before
this step because the list view items don't yet exist, and if I attach them
after onBeforeRender they are not picked up by the FormErrorDecorator.

Any ideas?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message