Sha256: 6b0f0fc038dbd109acd63f4378c973e425f3d0fff4b7087a9eac71d08018494d

Contents?: true

Size: 426 Bytes

Versions: 58

Compression:

Stored size: 426 Bytes

Contents

module Hyrax
  module SingularSubresourceController
    extend ActiveSupport::Concern
    include DenyAccessOverrideBehavior

    included do
      before_action :find_work, only: :work
      load_and_authorize_resource :work, only: :work
      load_and_authorize_resource :file, class: 'FileSet', only: :file, id_param: :id
    end

    def find_work
      @work = Hyrax::WorkRelation.new.find(params[:id])
    end
  end
end

Version data entries

58 entries across 58 versions & 2 rubygems

Version Path
hyrax-2.3.3 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.3.2 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.3.1 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-1.1.1 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.3.0 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.0.3 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.2.4 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.2.3 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.2.2 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.2.1 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.2.0 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.1.0 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.1.0.rc4 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.1.0.rc3 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.1.0.rc2 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.1.0.rc1 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-1.1.0 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.1.0.beta2 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.0.2 app/controllers/concerns/hyrax/singular_subresource_controller.rb
hyrax-2.1.0.beta1 app/controllers/concerns/hyrax/singular_subresource_controller.rb