Class: Decidim::InitiativePresenter

Inherits:
ResourcePresenter
  • Object
show all
Defined in:
app/presenters/decidim/initiative_presenter.rb

Overview

Decorator for initiatives

Instance Method Summary collapse

Instance Method Details

#authorObject



8
9
10
# File 'app/presenters/decidim/initiative_presenter.rb', line 8

def author
  @author ||= super.presenter
end

#initiativeObject



12
13
14
# File 'app/presenters/decidim/initiative_presenter.rb', line 12

def initiative
  __getobj__
end

#title(html_escape: false, all_locales: false) ⇒ Object



16
17
18
19
20
# File 'app/presenters/decidim/initiative_presenter.rb', line 16

def title(html_escape: false, all_locales: false)
  return unless initiative

  super(initiative.title, html_escape, all_locales)
end