constraint in grails

Solutions on MaxInterview for constraint in grails by the best coders in the world

showing results for - "constraint in grails"
Carlos
01 Oct 2019
1class User {
2    ...
3
4    static constraints = {
5        login shared: "myShared"
6    }
7}
Alessandro
05 Nov 2018
1class User {
2    String firstName
3    String lastName
4    String passwordHash
5
6    static constraints = {
7        firstName blank: false, nullable: false
8        lastName blank: false, nullable: false
9        passwordHash blank: false, nullable: false
10    }
11}
Juan Manuel
15 Aug 2016
1grails.gorm.default.constraints = {
2    '*'(nullable: true, size: 1..20)
3    myShared(nullable: false, blank: false)
4}