Hi,
You can stick the message in app.properties and it will be used whenever
a message isn't found in the component's messages.
-Filip
Julien skrev:
Hi,
I've created a custom validator, and i'd like to customize the message
key, to create generic validation messages.
For example, if I use my "email" validator, tapestry will look for
"<fieldId>-email-message" key, so I have to copy my message text in
every page... arrg
The Javadoc of AbstractValidator (
http://tapestry.formos.com/nightly/tapestry5/apidocs/org/apache/tapestry5/validator/AbstractValidator.html
) say that we can set the message key in the constructor, like this:
public EmailValidator() {
super(null, String.class, "mykey");
}
Well, did it, Tapestry still looking for "<fieldId>-email-message"...
What did I missed ?
One more thing; I use my own MessageSource (
http://www.nabble.com/T5-%3A-Expanding-Messages-Catalog-for-localization-from-arbitrary-source-td16608683.html#a16611882
)
Thx
Julien
---------------------------------------------------------------------
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]