History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: GRAILS-2741
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Graeme Rocher
Reporter: James Cook
Votes: 11
Watchers: 6
Operations

If you were logged in you would be able to see more operations.
Grails

Cascade validation fails with embedded domain objects when they have a custom validator

Created: 28/Mar/08 05:22 AM   Updated: 11/Aug/08 02:05 PM
Component/s: Scaffolding
Affects Version/s: 1.0.1
Fix Version/s: 1.0.4

Time Tracking:
Not Specified

File Attachments: 1. Zip Archive cascadeValidation.zip (233 kb)

Environment: Windows XP

Testcase included: yes


 Description  « Hide
There is a problem with cascading validation when using custom validation in conjunction with embedded objects.

The attached project has a test with four scenarios:

A one-to-one relationship where the child object is 'embedded' and has in-line validation
A one-to-one relationship where the child object has in-line validation
A one-to-one relationship where the child object has custom validation
A one-to-one relationship where the child object is 'embedded' and has custom validation

In all of the above scenarios, calling validate() on the parent object should return false if the child object is invalid, however, the last scenario does not.



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Peter Ledbrook - 11/Aug/08 02:05 PM
Fixed in r7279.