On 1 Jul 2009, at 15:58, Mathias Böttcher wrote:
> Regarding the error message. You can retrieve possible from a  
> validator
> using its getErrorMessage method. The validator can be accessed by  
> using
> getChild method of the ValidationManager. I'm not sure if that's the  
> way
> the problem should be solved... especially with translation in mind.

Would a solution to this be at actually save the record with with the  
unique field *inside* the validator code? Therefore any database  
exception can be caught in the validator and "thrown" as an Agavi  
validation error. Therefore all validation messages and code is in the  
same place.

This seems to cross the validation/action boundary however: it doesn't  
feel right for something "permanent" to actually happen inside the  
validator.

Michal.
_______________________________________________
users mailing list
[email protected]
http://lists.agavi.org/mailman/listinfo/users

Reply via email to