(快速参考)

removeFrom*

目的

addTo 方法相反,可将实例从关联中移除。

示例

def author = Author.findByName("Stephen King")

def book = author.books.find { it.title == 'The Stand' }

author.removeFromBooks(book)