Custom simple grails constraints

I would like to create a custom simple constraint (like display and edit) that I can use in the Domain class. Can the ConstrainedProperty class be extended?

class City {
    String title
    BigDecimal latitude
    BigDecimal longitude
    Country country

    static constraints = {
        title       ( blank: false, customConstraint: true )  // filter can be also be applied as attributes: [customConstraint: true]
    }
}

      

Anyone familiar with this case?

+3


source to share


1 answer


+3


source







All Articles