Displaying 1 result from an estimated 1 matches for "groups_manag".
Did you mean:
groups_man
2006 Aug 14
0
Save fails due to HATBM relationship... but only if not saved before?
I think this is a pretty weird bug, and would appreciate assistance in
figuring it out.
I have the following model:
class Group < ActiveRecord::Base
has_and_belongs_to_many :managers, :class_name => "User", :join_table =>
''groups_managers''
end
When I create a new Group object, assign a manager, and save, I get an
error:
$ ruby script/console
Loading development environment.
>> @group = Group.new(:name => ''test'')
=> #<Group:0x4081b908>
>> @group.managers << User.find(1)
=&...