Answers for "relationship in grails"

0

relationship in grails

//One-to-many
class Book {
    static belongsTo = Author
    static hasMany = [authors:Author]
    String title
}
//Other domain
class Author {
    static hasMany = [books:Book]
    String name
}
Posted by: Guest on February-11-2021

Code answers related to "relationship in grails"

Browse Popular Code Answers by Language