Class: Katalyst::Content::Item

Inherits:
ApplicationRecord
  • Object
show all
Defined in:
app/models/katalyst/content/item.rb

Overview

STI base class for content items

Direct Known Subclasses

Content

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#childrenObject

Returns the value of attribute children.



14
15
16
# File 'app/models/katalyst/content/item.rb', line 14

def children
  @children
end

#depthObject

Returns the value of attribute depth.



14
15
16
# File 'app/models/katalyst/content/item.rb', line 14

def depth
  @depth
end

#indexObject

Returns the value of attribute index.



14
15
16
# File 'app/models/katalyst/content/item.rb', line 14

def index
  @index
end

#parentObject

Returns the value of attribute parent.



14
15
16
# File 'app/models/katalyst/content/item.rb', line 14

def parent
  @parent
end

Class Method Details

.permitted_paramsObject



16
17
18
19
20
21
22
23
24
25
26
# File 'app/models/katalyst/content/item.rb', line 16

def self.permitted_params
  %i[
    container_type
    container_id
    type
    heading
    show_heading
    background
    visible
  ]
end