class Book {
String name
String author
static constraints = { name(nullable:true)
}
}
The above seems to work, however when i put in constraints for multiple fields the server does not start up
class Book {
String name
String author
static constraints = { name(nullable:true) author(nullabe:false)
}
}
With the above code ... I get the below exception
Caused by: groovy.lang.MissingMethodException: No signature of method: org.codehaus.groovy.grails.validation.ConstrainedPrope rty.call() is applicable for argument types: (org.codehaus.groovy.grails.validation.ConstrainedProperty) values: [org.codehau s.groovy.grails.validation.ConstrainedProperty@3343e5[class com.nthdimenzion.domain.Book,author,class java.lang.String,{nulla ble=org.codehaus.groovy.grails.validation.NullableConstraint@1aea6e2[false]}]] Possible solutions: wait(), any(), wait(long), each(groovy.lang.Closure), any(groovy.lang.Closure), isUrl() at com.nthdimenzion.domain.Book$_clinit_closure1.doCall(Book.groovy:16) at com.nthdimenzion.domain.Book$_clinit_closure1.doCall(Book.groovy) ... 23 more
Any ideas ?