In the layout file we can have "contents" (for editable content) and "layout_parts" (for when the layout is created from scratch)
19 lines
253 B
Ruby
19 lines
253 B
Ruby
class LayoutPart
|
|
|
|
include Mongoid::Document
|
|
include Mongoid::Timestamps
|
|
|
|
field :name
|
|
field :id_tag
|
|
field :editable, :type => Boolean
|
|
field :class_tag
|
|
field :content
|
|
|
|
embedded_in :layout
|
|
|
|
def editable?
|
|
self.editable
|
|
end
|
|
|
|
end
|