Sha256: a6176205a6c079a8dce6c2ec151992e28aa847041a50a175e7c3c11149c6c53e
Contents?: true
Size: 810 Bytes
Versions: 16
Compression:
Stored size: 810 Bytes
Contents
# frozen_string_literal: true module Hyrax module ManagesEmbargoes extend ActiveSupport::Concern included do attr_accessor :curation_concern helper_method :curation_concern base_class = Hyrax.config.use_valkyrie? ? Hyrax::Resource : ActiveFedora::Base load_and_authorize_resource class: base_class, instance_name: :curation_concern, except: [:index] end # This is an override of Hyrax::ApplicationController def deny_access(exception) redirect_to root_path, alert: exception.message end def edit; end private def work_has_file_set_members?(work) case work when Valkyrie::Resource Hyrax.custom_queries.find_child_file_set_ids(resource: work).any? else work.file_sets.present? end end end end
Version data entries
16 entries across 16 versions & 1 rubygems