Sha256: 3165d7ffa1a2e7420d9d9ffa917939a0ed7036d6eb8107c17f45c19db73e58d4

Contents?: true

Size: 1.04 KB

Versions: 13

Compression:

Stored size: 1.04 KB

Contents

# frozen_string_literal: true

module Decidim
  module Assemblies
    module Admin
      # Controller that allows to manage the content from the assembly landing page content blocks
      class AssemblyLandingPageContentBlocksController < Decidim::Assemblies::Admin::ApplicationController
        include Decidim::Admin::ContentBlocks::LandingPageContentBlocks
        include Concerns::AssemblyAdmin

        layout "decidim/admin/assemblies"

        private

        def content_block_scope
          current_participatory_space_manifest.content_blocks_scope_name
        end

        alias scoped_resource current_participatory_space

        def enforce_permission_to_update_resource
          enforce_permission_to :update, :assembly, assembly: scoped_resource
        end

        def edit_resource_landing_page_path
          edit_assembly_landing_page_path(scoped_resource)
        end

        def resource_landing_page_content_block_path
          assembly_landing_page_content_block_path(scoped_resource, params[:id])
        end
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
decidim-assemblies-0.29.1 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.28.4 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.29.0 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.28.3 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.29.0.rc4 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.29.0.rc3 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.29.0.rc2 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.29.0.rc1 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.28.2 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.28.1 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.28.0 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.28.0.rc5 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb
decidim-assemblies-0.28.0.rc4 app/controllers/decidim/assemblies/admin/assembly_landing_page_content_blocks_controller.rb