Module: MongoMapper::Plugins::Userstamps::ClassMethods

Defined in:
lib/mongo_mapper/plugins/userstamps.rb

Instance Method Summary collapse

Instance Method Details

#userstamps!Object



5
6
7
8
9
10
# File 'lib/mongo_mapper/plugins/userstamps.rb', line 5

def userstamps!
  key :creator_id, ObjectId
  key :updater_id, ObjectId
  belongs_to :creator, :class_name => 'User'
  belongs_to :updater, :class_name => 'User'
end