Vadim Gritsenko wrote:

Sylvain Wallez wrote:

Having validators on all widgets seems to be a must have since it allows to perform higher-level validation on e.g. repeaters, forms, etc. Currently, a validation rule is supposed to return a ValidationError which is attached to the widget invoking the validation rule.

This has several problems:
- not all widgets can provide visual feedback for a validation error, i.e. a form, a repeater or a class.


It can be fixed with styling change, and/or with a patch I suggested a while ago. I can commit it, I still have it (<wd:validation-error/> tag)


Mmmh... it may make sense for _some_ widgets other than fields, but does it make sense for _all_ widgets, like non-visual widgets like "class", "switch", etc?

My "ValidationErrorAware" proposal allows us to add validation errors on the widgets we want to, but doesn't _require_ it. So I think I'll go that way, which will allow us to progressively add validation errors on widgets where it makes sense.

Sylvain

--
Sylvain Wallez                                  Anyware Technologies
http://www.apache.org/~sylvain           http://www.anyware-tech.com
{ XML, Java, Cocoon, OpenSource }*{ Training, Consulting, Projects }
Orixo, the opensource XML business alliance  -  http://www.orixo.com




Reply via email to