Sha256: e7d2e265a48259de76816711b8d9e7dc14ee7c539e4ebdb80de791f790029d2b

Contents?: true

Size: 381 Bytes

Versions: 58

Compression:

Stored size: 381 Bytes

Contents

module Hyrax
  # Injects a search builder filter to hide documents marked as suppressed
  module FilterSuppressed
    extend ActiveSupport::Concern

    included do
      self.default_processor_chain += [:only_active_works]
    end

    def only_active_works(solr_parameters)
      solr_parameters[:fq] ||= []
      solr_parameters[:fq] << '-suppressed_bsi:true'
    end
  end
end

Version data entries

58 entries across 58 versions & 2 rubygems

Version Path
hyrax-2.9.6 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.9.5 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.9.4 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.9.3 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.9.2 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.9.1 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.9.0 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.8.0 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.7.2 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.7.1 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.7.0 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.6.0 app/search_builders/hyrax/filter_suppressed.rb
hyrax-3.0.0.pre.rc1 app/search_builders/hyrax/filter_suppressed.rb
hyrax-3.0.0.pre.beta3 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.5.1 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.5.0 app/search_builders/hyrax/filter_suppressed.rb
hyrax-3.0.0.pre.beta2 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.4.1 app/search_builders/hyrax/filter_suppressed.rb
hyrax-3.0.0.pre.beta1 app/search_builders/hyrax/filter_suppressed.rb
hyrax-2.4.0 app/search_builders/hyrax/filter_suppressed.rb