Class: Decidim::Consultations::ConsultationsController

Inherits:
ApplicationController show all
Includes:
NeedsConsultation, Orderable, FilterResource, Paginable, ParticipatorySpaceContext
Defined in:
app/controllers/decidim/consultations/consultations_controller.rb

Overview

A controller that holds the logic to show consultations in a public layout.

Instance Method Summary collapse

Methods included from NeedsConsultation

enhance_controller, extended, included

Instance Method Details

#indexObject



26
27
28
# File 'app/controllers/decidim/consultations/consultations_controller.rb', line 26

def index
  enforce_permission_to :read, :consultation_list
end

#showObject



30
31
32
# File 'app/controllers/decidim/consultations/consultations_controller.rb', line 30

def show
  enforce_permission_to :read, :consultation, consultation: current_consultation
end