Class: OnlineDocumentSection
Constant Summary
WebsiteSection::KNIT_KIT_ROOT, WebsiteSection::WEBSITE_SECTIONS_TEMP_LAYOUT_PATH
Instance Method Summary
collapse
#articles, #child_by_path, #create_layout, #get_published_layout, #get_tags, #get_topics, #iid, #is_document_section?, #is_section?, #is_secured?, #paths, #positioned_children, register_type, #render_base_layout?, #secure, #should_generate_new_friendly_id?, #type, #update_path!, #website
Instance Method Details
#build_section_hash ⇒ Object
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
# File 'app/models/online_document_section.rb', line 18
def build_section_hash
section_hash = {
:name => self.title,
:has_layout => false,
:use_markdown => self.use_markdown,
:type => self.class.to_s,
:in_menu => self.,
:path => self.path,
:permalink => self.permalink,
:internal_identifier => self.internal_identifier,
:position => self.position,
:online_document_sections => self.children.each.map{|child| child.build_section_hash},
:articles => [],
:documented_item => {
:name => documented_item_content.title,
:display_title => documented_item_content.display_title,
:internal_identifier => documented_item_content.internal_identifier
}
}
section_hash
end
|
#documented_item_content_html ⇒ Object
6
7
8
9
10
|
# File 'app/models/online_document_section.rb', line 6
def documented_item_content_html
documented_item_content.body_html
rescue
nil
end
|
#documented_item_published_content_html(active_publication) ⇒ Object
12
13
14
15
16
|
# File 'app/models/online_document_section.rb', line 12
def documented_item_published_content_html(active_publication)
documented_item_published_content(active_publication).body_html
rescue
nil
end
|