Grails: scaffolding creates a view for a domain with hasMany relationship

Assume the following (simplified) domain classes:

class Person { static hasMany = [stringProperties: StringProperty] static constraints = { } } 

and

 class StringProperty { String name String value static constraints = { name blank:false value blank: true } } 

When scaffolding creates a create view, there is no way in gsp to create a StringProperty from Person.

Whether there is any plugin or someone knows best practice that can display the create ui view that allows you to create hasmany relationship elements.

I just ask before I take the time to change the forest templates.

+4
source share
1 answer

This is one area where the community can welcome plug-ins or advanced scaffolding. If I had time, I would present the information presented here and create a plugin for it. I have used this approach several times and it works well.

0
source

Source: https://habr.com/ru/post/1494464/


All Articles