You need to save Foo before you can assign the polymorph to it. Otherwise, has_many_polymorphs doesn't know which foo_id to assign.
Related topics
Topic | Replies | Views | Activity | |
---|---|---|---|---|
Polymorphic many-to-many relationship? | 0 | 122 | September 6, 2009 | |
has_many_polymorphs | 0 | 97 | February 29, 2008 | |
Polymorphic has_and_belongs_to_many association | 0 | 148 | September 10, 2012 | |
has_many :through a polymorphic has_many - Broken Again | 0 | 108 | April 10, 2008 | |
has_many :through with self-referencial AND polymorphism | 1 | 131 | January 21, 2008 |