Sha256: cea47e73a93820b193b76323c31941737b77694c9e3fe75b999e7d487d3f9ccd
Contents?: true
Size: 504 Bytes
Versions: 25
Compression:
Stored size: 504 Bytes
Contents
# frozen_string_literal: true module Hyrax module Renderers class FacetedAttributeRenderer < AttributeRenderer private def li_value(value) link_to(ERB::Util.h(value), search_path(value)) end def search_path(value) Rails.application.routes.url_helpers.search_catalog_path("f[#{search_field}][]": value, locale: I18n.locale) end def search_field ERB::Util.h(options.fetch(:search_field, field).to_s + "_sim") end end end end
Version data entries
25 entries across 25 versions & 1 rubygems