Sha256: 1512598903b20a4e3f86baf3cd61c7d954411146ebc6d75a419eaff964839b57

Contents?: true

Size: 837 Bytes

Versions: 33

Compression:

Stored size: 837 Bytes

Contents

# frozen_string_literal: true

document_url = polymorphic_url(@document)
doc_presenter = document_presenter(@document)

json.links do
  json.self document_url
end

json.data do
  json.id @document.id
  json.type doc_presenter.display_type.first
  json.attributes do
    json.title doc_presenter.heading unless doc_presenter.fields_to_render.any? { |field_name, _field, _field_presenter| field_name.to_s == 'title' }

    doc_presenter.fields_to_render.each do |field_name, field, field_presenter|
      json.partial! 'field', field: field,
                             field_name: field_name,
                             document_url: document_url,
                             doc_presenter: doc_presenter,
                             field_presenter: field_presenter,
                             view_type: 'show'
    end
  end
end

Version data entries

33 entries across 32 versions & 2 rubygems

Version Path
blacklight-8.6.1 app/views/catalog/show.json.jbuilder
blacklight-7.40.0 app/views/catalog/show.json.jbuilder
blacklight-8.6.0 app/views/catalog/show.json.jbuilder
blacklight-8.5.1 app/views/catalog/show.json.jbuilder
blacklight-8.5.0 app/views/catalog/show.json.jbuilder
blacklight-7.39.0 app/views/catalog/show.json.jbuilder
blacklight-8.4.0 app/views/catalog/show.json.jbuilder
blacklight-7.38.0 app/views/catalog/show.json.jbuilder
blacklight-spotlight-3.6.0.beta8 vendor/bundle/ruby/3.2.0/gems/blacklight-7.37.0/app/views/catalog/show.json.jbuilder
blacklight-spotlight-3.6.0.beta8 vendor/bundle/ruby/3.2.0/gems/blacklight-8.3.0/app/views/catalog/show.json.jbuilder
blacklight-8.3.0 app/views/catalog/show.json.jbuilder
blacklight-8.2.2 app/views/catalog/show.json.jbuilder
blacklight-8.2.1 app/views/catalog/show.json.jbuilder
blacklight-8.2.0 app/views/catalog/show.json.jbuilder
blacklight-7.37.0 app/views/catalog/show.json.jbuilder
blacklight-7.36.2 app/views/catalog/show.json.jbuilder
blacklight-7.36.1 app/views/catalog/show.json.jbuilder
blacklight-7.36.0 app/views/catalog/show.json.jbuilder
blacklight-7.35.0 app/views/catalog/show.json.jbuilder
blacklight-8.1.0 app/views/catalog/show.json.jbuilder