Class: SolidusContent::Entry
Class Method Summary
collapse
Instance Method Summary
collapse
#provider_based_attr_reader
Class Method Details
.data_for(type, slug) ⇒ Object
21
22
23
|
# File 'app/models/solidus_content/entry.rb', line 21
def self.data_for(type, slug)
by_type(type).by_slug(slug).data
end
|
Instance Method Details
#content ⇒ Object
29
30
31
|
# File 'app/models/solidus_content/entry.rb', line 29
def content
@content ||= entry_type.content_for(self)
end
|
#data ⇒ Object
25
26
27
|
# File 'app/models/solidus_content/entry.rb', line 25
def data
content[:data]
end
|
#entry_fields ⇒ Object
33
34
35
36
37
|
# File 'app/models/solidus_content/entry.rb', line 33
def entry_fields
return unless entry_type_id?
entry_type.provider_class.entry_fields
end
|