module MongoMapper::AcceptsNestedAttributes::ClassMethods
Public Instance Methods
accepts_nested_attributes_for(*associations)
click to toggle source
# File lib/mongo_mapper/accepts_nested_attributes.rb, line 6 def accepts_nested_attributes_for(*associations) (associations||[]).each do |association| # should do a fake nested attributes define_method :"#{association}_attributes=" do |*args| self.send :"#{association}=", *args end end end