Sha256: c5238bb8d7c00cf07884b99ddef79b3065e123f2e3c2e1b509cc686c3b4e0d59
Contents?: true
Size: 928 Bytes
Versions: 6
Compression:
Stored size: 928 Bytes
Contents
# frozen_string_literal: true module Arclight ## # Arclight specific methods for the Catalog module Catalog extend ActiveSupport::Concern included do before_action only: :index do if (params.dig(:f, :collection_sim) || []).any?(&:blank?) params[:f][:collection_sim].delete_if(&:blank?) params[:f].delete(:collection_sim) if params[:f][:collection_sim].blank? end end end ## # Overriding the Blacklight method so that the hierarchy view does not start # a new search session def start_new_search_session? !%w[online_contents collection_context].include?(params[:view]) && super end ## # Overriding the Blacklight method so that hierarchy does not get stored as # the preferred view def store_preferred_view return if %w[online_contents collection_context].include?(params[:view]) super end end end
Version data entries
6 entries across 6 versions & 1 rubygems