views:

57

answers:

1

I have some Domain classes inheriting from a base class. However when I generate the scaffolding, the view does not contain any elements of the base class.

The behaviour is the same regardless of table per hierarchy (default), or table per subclass.

Is this a bug or am I doing something wrong?

A: 

the code below works for me with dynamic and static scaffolding:

package p

class Person {
    String toString() { name
    }
    static constraints={
        name(blank:false,unique:true)
    }
    String name
}

package p

class Vip extends Person {
    static constraints={
        money(min:1000)
    }
    int money
}
Ray Tayek
Yes it does..Not sure what I did wrong. I think there may have been some caching issues with my test code. When I created a new project and added the inheritance everything worked as expected.
khylo
do a grails clean often. if you have a real mysteriousity, delete ~/.grails and ~/.ivy2
Ray Tayek