Skip to content

MongoMapper plugin for nested attributes(accepts_nested_attributes_for)

Notifications You must be signed in to change notification settings

corewebdesign/mm-nested-attrs

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation


MongoMapper extension for accepts_nested_attributes


Installation:

gem install mm-nested-attrs

Using:

In your parent class:

class Parent
  include MongoMapper::Document
  plugin MongoMapper::Plugins::Associations::NestedAttributes
  accepts_nested_attributes_for :images, :allow_destroy => true, :reject_if => lambda { |t| t['img'].blank? }
end

In Gemfile

 gem 'mm-nested-attrs'

About

MongoMapper plugin for nested attributes(accepts_nested_attributes_for)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 100.0%