space/app/models/floor_unit.rb

15 lines
232 B
Ruby
Raw Permalink Normal View History

2015-09-22 05:56:02 +00:00
class FloorUnit
include Mongoid::Document
include Mongoid::Timestamps
2015-09-24 15:43:47 +00:00
include Slug
2015-09-22 05:56:02 +00:00
2015-09-24 15:43:47 +00:00
field :title, as: :slug_title
field :layout
2015-09-22 05:56:02 +00:00
belongs_to :floor
2015-09-24 15:43:47 +00:00
has_many :floor_sub_units
2015-09-22 05:56:02 +00:00
2015-09-24 15:43:47 +00:00
mount_uploader :layout_image, ImageUploader
2015-09-22 05:56:02 +00:00
end