Class: Protozoa::Views::Create
Instance Attribute Summary collapse
Instance Method Summary
collapse
Methods included from Editable
#categories
Methods inherited from Layout
#edit_url, #escaped_name, #view_url
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
6
7
8
|
# File 'lib/amiba/frontend/views/create.rb', line 6
def name
@name
end
|
#page ⇒ Object
Returns the value of attribute page.
6
7
8
|
# File 'lib/amiba/frontend/views/create.rb', line 6
def page
@page
end
|
Instance Method Details
20
21
22
23
|
# File 'lib/amiba/frontend/views/create.rb', line 20
def format
@format = (@page.format || false) if @format.nil? && @page
@format.to_s.downcase
end
|
39
40
41
|
# File 'lib/amiba/frontend/views/create.rb', line 39
def formats
super(:markdown)
end
|
25
26
27
28
|
# File 'lib/amiba/frontend/views/create.rb', line 25
def
@footer = (@page. || false) if @footer.nil? && @page
!!@footer
end
|
30
31
32
33
|
# File 'lib/amiba/frontend/views/create.rb', line 30
def
@sidebar = (@page. || false) if @sidebar.nil? && @page
!!@sidebar
end
|
#is_create_page ⇒ Object
12
13
14
|
# File 'lib/amiba/frontend/views/create.rb', line 12
def is_create_page
true
end
|
#is_edit_page ⇒ Object
16
17
18
|
# File 'lib/amiba/frontend/views/create.rb', line 16
def is_edit_page
false
end
|
#page_name ⇒ Object
35
36
37
|
# File 'lib/amiba/frontend/views/create.rb', line 35
def page_name
@name.gsub('-', ' ')
end
|
#title ⇒ Object
8
9
10
|
# File 'lib/amiba/frontend/views/create.rb', line 8
def title
"Create a new page"
end
|