By "changing" or "updating" the form fields I do *NOT* mean entering some
values into them of course, but I mean reloading the fields using ajax, to
load a whole another set of fields.

On Mon, Nov 19, 2012 at 5:37 PM, Muhammad Gelbana <m.gelb...@gmail.com>wrote:

> I use <t:error> for each field.
>
> Here is some more enlightening investigation results, based on the fact
> that the form's fields are changed using ajax, once the fields are updated,
> the fields errors are shown only after the first submission and the same
> happens every time the form field's are changed. So it has something to do
> with binding the fields with the "validation tracker on the client side".
>
> In another words, on the second submission, the page is fully loaded so
> the "client side validation tracker" is setup right and bound to the
> fields. But when I update the form's fields using ajax, it's broken. I have
> a feeling this could be wrong but its my very best guess so far.
>
>
> On Mon, Nov 19, 2012 at 5:33 PM, Ivan Khalopik <ikhalo...@gmail.com>wrote:
>
>> Do you use <t:errors> component to show errors for whole form or just use
>> separate <t:error> components to show errors for particular field?
>>
>> On Mon, Nov 19, 2012 at 6:28 PM, Muhammad Gelbana <m.gelb...@gmail.com
>> >wrote:
>>
>> > When I first load my page, some form's fields are changed through ajax
>> and
>> > then I submit the form (Without ajax) with empty fields to force it into
>> > validation errors. But no errors are shown. If just submit the form
>> again,
>> > exactly as it was the last time, the errors are shown !
>> >
>> > That's how I inject my components
>> > private static final int MULTIPLE_BRAS_LOOP_END = 20;
>> >
>> > >     @InjectComponent
>> > >     private TextField dnsServerField, domainNameField;
>> > >     @InjectComponent("testConfigurationForm")
>> > >     private Form testForm;
>> >
>> >
>> > I checked the form using .getHasErrors() and it returned true on both
>> > submits. It's only that on the first submit, nothing is shown for the
>> > client !
>> >
>> > I also forced the form into 2 different validation errors and only the
>> > second submission's error was shown, so its not like showing validation
>> > errors for previous submissions. Even more, this strange behavior stops
>> > after the first submission, everything works as expected !
>> >
>>
>>
>>
>> --
>> BR
>> Ivan
>>
>
>

Reply via email to