Sha256: 8fb0975a93964a431a12c1bd22fd6a77d2f4c26c5c49f170a93ae708437ebc0f

Contents?: true

Size: 620 Bytes

Versions: 11

Compression:

Stored size: 620 Bytes

Contents

# frozen_string_literal: true
module Decidim
  module Budgets
    module Admin
      # Controller that allows managing all the attachments for a participatory
      # process.
      #
      class AttachmentsController < Admin::ApplicationController
        include Decidim::Admin::Concerns::HasAttachments

        def after_destroy_path
          projects_path
        end

        def attached_to
          project
        end

        def project
          @project ||= projects.find(params[:project_id])
        end

        def authorization_object
          project.feature
        end
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 2 rubygems

Version Path
decidim-budgets-0.1.0 app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-0.1.0 decidim-budgets/app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-budgets-0.0.8.1 app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-0.0.8.1 decidim-budgets/app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-budgets-0.0.7 app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-0.0.7 decidim-budgets/app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-budgets-0.0.6 app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-0.0.6 decidim-budgets/app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-budgets-0.0.5 app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-0.0.5 decidim-budgets/app/controllers/decidim/budgets/admin/attachments_controller.rb
decidim-0.0.4 decidim-budgets/app/controllers/decidim/budgets/admin/attachments_controller.rb