Sha256: 73266b371ebe95927376eed325322bf779af47348dc576f164e0afeae1887832

Contents?: true

Size: 723 Bytes

Versions: 45

Compression:

Stored size: 723 Bytes

Contents

module Hyrax
  module Actors
    class Environment
      # @param [ActiveFedora::Base] curation_concern work to operate on
      # @param [Ability] current_ability the authorizations of the acting user
      # @param [ActionController::Parameters] attributes user provided form attributes
      def initialize(curation_concern, current_ability, attributes)
        @curation_concern = curation_concern
        @current_ability = current_ability
        @attributes = attributes.to_h.with_indifferent_access
      end

      attr_reader :curation_concern, :current_ability, :attributes

      # @return [User] the user from the current_ability
      def user
        current_ability.current_user
      end
    end
  end
end

Version data entries

45 entries across 45 versions & 1 rubygems

Version Path
hyrax-2.9.6 app/actors/hyrax/actors/environment.rb
hyrax-2.9.5 app/actors/hyrax/actors/environment.rb
hyrax-2.9.4 app/actors/hyrax/actors/environment.rb
hyrax-2.9.3 app/actors/hyrax/actors/environment.rb
hyrax-2.9.2 app/actors/hyrax/actors/environment.rb
hyrax-2.9.1 app/actors/hyrax/actors/environment.rb
hyrax-2.9.0 app/actors/hyrax/actors/environment.rb
hyrax-2.8.0 app/actors/hyrax/actors/environment.rb
hyrax-2.7.2 app/actors/hyrax/actors/environment.rb
hyrax-2.7.1 app/actors/hyrax/actors/environment.rb
hyrax-2.7.0 app/actors/hyrax/actors/environment.rb
hyrax-2.6.0 app/actors/hyrax/actors/environment.rb
hyrax-2.5.1 app/actors/hyrax/actors/environment.rb
hyrax-2.5.0 app/actors/hyrax/actors/environment.rb
hyrax-2.4.1 app/actors/hyrax/actors/environment.rb
hyrax-3.0.0.pre.beta1 app/actors/hyrax/actors/environment.rb
hyrax-2.4.0 app/actors/hyrax/actors/environment.rb
hyrax-2.3.3 app/actors/hyrax/actors/environment.rb
hyrax-2.3.2 app/actors/hyrax/actors/environment.rb
hyrax-2.3.1 app/actors/hyrax/actors/environment.rb