Sha256: 959e337bd2b84d467bba5d2fd3eb075ccf77daa4db733eb02b898a7e4091885f

Contents?: true

Size: 758 Bytes

Versions: 25

Compression:

Stored size: 758 Bytes

Contents

# frozen_string_literal: true

module Blacklight
  module Document
    # Render the 'more like this' results from the response
    class GroupComponent < Blacklight::Component
      with_collection_parameter :group

      # @param [Blacklight::Solr::Response::Group] group
      # @param [Integer] group_limit
      def initialize(group:, group_limit: -1)
        @group = group
        @group_limit = group_limit
      end

      def grouped_documents
        helpers.render_document_index @group.docs
      end

      def add_group_facet_params_and_redirect(group)
        Deprecation.silence(Blacklight::UrlHelperBehavior) do
          helpers.search_action_path(helpers.add_group_facet_params_and_redirect(group))
        end
      end
    end
  end
end

Version data entries

25 entries across 25 versions & 2 rubygems

Version Path
blacklight-7.40.0 app/components/blacklight/document/group_component.rb
blacklight-7.39.0 app/components/blacklight/document/group_component.rb
blacklight-7.38.0 app/components/blacklight/document/group_component.rb
blacklight-spotlight-3.6.0.beta8 vendor/bundle/ruby/3.2.0/gems/blacklight-7.37.0/app/components/blacklight/document/group_component.rb
blacklight-7.37.0 app/components/blacklight/document/group_component.rb
blacklight-7.36.2 app/components/blacklight/document/group_component.rb
blacklight-7.36.1 app/components/blacklight/document/group_component.rb
blacklight-7.36.0 app/components/blacklight/document/group_component.rb
blacklight-7.35.0 app/components/blacklight/document/group_component.rb
blacklight-7.34.0 app/components/blacklight/document/group_component.rb
blacklight-7.33.1 app/components/blacklight/document/group_component.rb
blacklight-7.33.0 app/components/blacklight/document/group_component.rb
blacklight-7.32.0 app/components/blacklight/document/group_component.rb
blacklight-7.31.0 app/components/blacklight/document/group_component.rb
blacklight-7.30.0 app/components/blacklight/document/group_component.rb
blacklight-7.29.0 app/components/blacklight/document/group_component.rb
blacklight-7.28.0 app/components/blacklight/document/group_component.rb
blacklight-7.27.1 app/components/blacklight/document/group_component.rb
blacklight-7.27.0 app/components/blacklight/document/group_component.rb
blacklight-7.26.1 app/components/blacklight/document/group_component.rb