That must be the point, of course.

But why are form fields implemented in different ways?

There are fields like ie TextField, that record their input value into the trackings, even if there was no error.

On the other side, PropertySelection or Checkbox, record only errors into the trackings.

This is an inconsistent behaviour for elements, that are - in my opinion - supposed to work similar.

It would be nice to know, in which direction the development of Tapestry is heading. Will there be a "default behaviour" some time?

Christian

P.S. I've extended all form elements that I needed and changed some methods, so that all form elements always register with ValidationDelegate.


Am 01.02.2006 um 15:03 schrieb Ivano:

My guess is that you won't need those fields unless you have some error to show and you want to tell the user which field was wrong. If this is the idea for the most common use of field validation, the consequence is that you don't want to take note of unused data.

Ivano Pagano.

Christian Mittendorf wrote:

Am 01.02.2006 um 01:56 schrieb Christian Mittendorf:

That might be a solution: do ValidPropertySelection and ValidCheckbox record their input values to the ValidationDelegate in any case, even if no error occured?


Thanks for the hints!

I've implemented both classes and added the following code:

rotected void rewindFormComponent(IMarkupWriter writer, IRequestCycle cycle)
{
[...]
IValidationDelegate delegate = getForm().getDelegate();
if(delegate != null)
{
    delegate.recordFieldInputValue(value);
}
[...]

Now every input value is also stored in the FieldTrackings and every validated FormField
is on the list, wether it stores an error or not.

Is there a reason why this is not the "normal" behaviour of these standard components?

Christian




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: tapestry-user- [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to