Class: Decidim::Plans::ContentPresenter

Inherits:
SimpleDelegator
  • Object
show all
Includes:
RichPresenter, TranslatableAttributes
Defined in:
app/presenters/decidim/plans/content_presenter.rb

Overview

Decorator for contents

Instance Method Summary collapse

Methods included from RichPresenter

#plain_content, #rich_content

Instance Method Details

#bodyObject



21
22
23
# File 'app/presenters/decidim/plans/content_presenter.rb', line 21

def body
  rich_content(translated_attribute(content.body))
end

#contentObject



13
14
15
# File 'app/presenters/decidim/plans/content_presenter.rb', line 13

def content
  __getobj__
end

#titleObject



17
18
19
# File 'app/presenters/decidim/plans/content_presenter.rb', line 17

def title
  plain_content(translated_attribute(content.title))
end