Class: Cms::AbstractFileBlock
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- Cms::AbstractFileBlock
- Defined in:
- app/models/cms/abstract_file_block.rb
Direct Known Subclasses
Class Method Summary collapse
Instance Method Summary collapse
-
#parent ⇒ Cms::Section
Return the parent section for this block.
- #path ⇒ Object
- #set_attachment_path ⇒ Object
- #set_attachment_section ⇒ Object
Class Method Details
.publishable? ⇒ Boolean
24 25 26 |
# File 'app/models/cms/abstract_file_block.rb', line 24 def self.publishable? true end |
Instance Method Details
#parent ⇒ Cms::Section
Return the parent section for this block.
16 17 18 |
# File 'app/models/cms/abstract_file_block.rb', line 16 def parent .parent end |
#path ⇒ Object
20 21 22 |
# File 'app/models/cms/abstract_file_block.rb', line 20 def path end |
#set_attachment_path ⇒ Object
28 29 30 31 32 |
# File 'app/models/cms/abstract_file_block.rb', line 28 def if @attachment_file_path && @attachment_file_path != .file_path .file_path = @attachment_file_path end end |
#set_attachment_section ⇒ Object
34 35 36 37 38 |
# File 'app/models/cms/abstract_file_block.rb', line 34 def if @attachment_section_id && @attachment_section_id != .section .section_id = @attachment_section_id end end |