[jboss-jira] [JBoss JIRA] Commented: (JBSEAM-340) Streamline use of i18n validation error messages
Manfred Moser (JIRA)
jira-events at jboss.com
Thu Sep 7 12:09:43 EDT 2006
[ http://jira.jboss.com/jira/browse/JBSEAM-340?page=comments#action_12343028 ]
Manfred Moser commented on JBSEAM-340:
--------------------------------------
It is great that specifiying the resource bundle actually works however it is a bit counter intuitive when developing. You have to have it in the EJBs but you dont have to have it in other seam components. This should maybe be streamlined. At least there should be an example in the actual distro. And yes .. I agree that the hibnerate like variables should work too. In fact my entity unit tests test the validation with the hibernate validator assuming it would work in Seam.
> Streamline use of i18n validation error messages
> -------------------------------------------------
>
> Key: JBSEAM-340
> URL: http://jira.jboss.com/jira/browse/JBSEAM-340
> Project: JBoss Seam
> Issue Type: Bug
> Components: Core
> Affects Versions: 1.0.1
> Environment: Seam 1.0.1.GA
> Reporter: Manfred Moser
>
> As described in the forum post referenced introducing i18n error message from validation of an entity bean does not have an example anywhere and actually only works nicely with a bit of a work around. The situation is that the hibernate validation needs the error message in ValidatorMessages_*.properties and Seam has its properties in messages_*.properties. For the entity bean to work without Seam (e.g. in a unit test that verifies the validation settings) the messages have to exist in the hibnerate resource bundle. For usage in Seam they have to exist in the Seam bundle. For a Seam app to actually start up all properties related to exist in the Hibnerate and the Seam bundles .. which leads to ugly duplication. A fix is to keep all properties in the seam bundles and copy them into the hibernate bundle at build time. The forum post has a ant task. It would however be better if Seam could somehow manage to pass the resources to hibernate or otherwise just automatically include the hibernate bundle. An example of the i18n of the validation message and other annotation based messages should be included in the examples.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list