I have a database with :collection has_many :books, :through => :collbooks.
I have a show page that shows the collection and a table_plus of all books.
I would like to include the "remove" action with <controls/>, but I want the remove action to only delete the :collbooks table and leave the :book intact.
As things are now, the remove will actually remove the book entirely.
Thanks in advance!
Mike
I have a show page that shows the collection and a table_plus of all books.
I would like to include the "remove" action with <controls/>, but I want the remove action to only delete the :collbooks table and leave the :book intact.
As things are now, the remove will actually remove the book entirely.
Thanks in advance!
Mike
Discussion
-
kevinpfromnm Says:
Is the collbooks table just a join table? If so, use that as your object and change the view to show what you need out of the books item. Then, as long as the context is the collbooks object, the remove will just remove the join.