personal-book/app/models/book_file.rb

13 lines
322 B
Ruby

class BookFile
include Mongoid::Document
include Mongoid::Timestamps
include Mongoid::Attributes::Dynamic
field :description, type: String, localize: true
field :title, type: String, localize: true
field :should_destroy, type: Boolean
mount_uploader :member_book_file, AssetUploader
belongs_to :book
end