[hibernate-issues] [Hibernate-JIRA] Created: (HV-60) Need Property names along with validation messages (as an option)
Priya M (JIRA)
noreply at atlassian.com
Mon Jun 2 14:15:33 EDT 2008
Need Property names along with validation messages (as an option)
-----------------------------------------------------------------
Key: HV-60
URL: http://opensource.atlassian.com/projects/hibernate/browse/HV-60
Project: Hibernate Validator
Issue Type: New Feature
Reporter: Priya M
Forum Tracking.
htthttp://www.seamframework.org/Community/ValidationMessagesWithActualPropertyNamesWithSvalidateAll
Currently, the validation messages don't point to the property name(s) making it too generic and hard to understand. For example, let's say I have 10 properties on the page and there were 3 validations thrown by Hibernate Validator. I get the following messages
. value is required
. value is required
. length should be 20
The above messages is only useful for simple forms where each field is wrapped by an error tag. While working with complex UI (datatables with large rows)
and Application code that works with collections, the above messages are redundant if not attached with the corresponding property name.
Ideally, it would be useful to have something like this
. foo value is required
. bar value is required
. foobar length should be 20
This could be provided as an optional hibernate attribute in the hibernate properties
hibernate.validator.include_property_names=true
The only workaround that seems now, is to override each and every validation message in all the entity objects to spit out the property name with validation maessages. (lame!)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list