Displaying 1 result from an estimated 1 matches for "ar_user".
Did you mean:
r_user
2006 May 07
1
Overwriting setters for associated objects
Hi all,
I''m trying to overwrite a setter method, but am running into some
difficulties. This is normally really easy when overwriting a setter for
a table column, but in this case it is the setter for an associated
object.
Here''s a hypothetical example:
class User < ActiveRecord::Base
has_many :posts
end
class Post < ActiveRecord::Base
belongs_to :user