Class: Decidim::Pages::Page

Inherits:
ApplicationRecord show all
Includes:
HasComponent, Loggable, Resourceable, Traceable, TranslatableResource
Defined in:
app/models/decidim/pages/page.rb

Overview

The data store for a Page in the Decidim::Pages component. It stores a title, description and any other useful information to render a custom page.

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.log_presenter_class_for(_log) ⇒ Object



18
19
20
# File 'app/models/decidim/pages/page.rb', line 18

def self.log_presenter_class_for(_log)
  Decidim::Pages::AdminLog::PagePresenter
end

Instance Method Details

#titleObject

Public: Pages do not have title so we assign the component one to it.



23
24
25
# File 'app/models/decidim/pages/page.rb', line 23

def title
  component.name
end