【发布时间】:2015-01-22 13:21:17
【问题描述】:
我正在处理一个项目并且有一个当前为hasOne=[billingAddress:Address] 的Invoice 域类当我尝试启动我的服务器时,我收到以下错误:
hasOne property [Invoice.billingAddress] is not bidirectional. Specify the other side of the relationship!
虽然我不想分配关系的另一方...发票有一个帐单地址,但地址不属于发票。地址属于用户!!!
处理这种情况的正确方法是什么?
【问题讨论】:
-
改用
Address billingAddress?
标签: hibernate grails grails-orm