Sha256: b52a848dcf91adffc1a0211747567dc6311f5f6436719112bd286e940bbd8a2b
Contents?: true
Size: 936 Bytes
Versions: 19
Compression:
Stored size: 936 Bytes
Contents
# frozen_string_literal: true require "active_support/concern" module Decidim module Consultations module Admin # This concern is meant to be included in all controllers that are scoped # into an question's admin panel. It will override the layout so it shows # the sidebar, preload the consultation, etc. module QuestionAdmin extend ActiveSupport::Concern included do include NeedsQuestion include Decidim::Admin::ParticipatorySpaceAdminContext participatory_space_admin_layout def current_participatory_space return current_consultation if params.has_key? :consultation_slug current_question end def permission_class_chain [ Decidim::Consultations::Permissions, Decidim::Admin::Permissions ] end end end end end end
Version data entries
19 entries across 19 versions & 1 rubygems