hasErrors
Purpose
Check if a domain class instance has validation errors following a call to validate or save, or following Data Binding
Examples
def b = new Book(title: "The Shining") b.validate() if (b.hasErrors()) { b.errors.each { println it } }
(Quick Reference)
hasErrorsPurposeCheck if a domain class instance has validation errors following a call to validate or save, or following Data Binding Examplesdef b = new Book(title: "The Shining") b.validate() if (b.hasErrors()) { b.errors.each { println it } } |
Command LineConstraintsControllersDatabase MappingDomain ClassesPlug-insServicesServlet APITag LibrariesTags |