Orbit/app/models/asset.rb

14 lines
201 B
Ruby

class Asset
include Mongoid::Document
include Mongoid::Timestamps
mount_uploader :data, AssetUploader
field :filename
field :description
validates_presence_of :filename, :data
end