Sha256: 6c32c45625f65d83c1f1326ca2d69da4729fbfdbbc222912bdd5cd35fc87b6ad
Contents?: true
Size: 438 Bytes
Versions: 2
Compression:
Stored size: 438 Bytes
Contents
class NestedFieldTest include Mongoid::Document field :title, :type => String belongs_to :field_test, :inverse_of => :nested_field_tests belongs_to :another_field_test, :inverse_of => :nested_field_tests include Mongoid::Timestamps has_one :comment, :as => :commentable, :autosave => true accepts_nested_attributes_for :comment, :allow_destroy => true, :reject_if => proc { |attributes| attributes["content"].blank? } end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
rails_admin-0.6.0 | spec/dummy_app/app/mongoid/nested_field_test.rb |
rails_admin-0.5.0 | spec/dummy_app/app/mongoid/nested_field_test.rb |