Sha256: 22e8215d9604084359e64a721cf05e306aed0fd8a602b1a75e5d80cbf7d447d5

Contents?: true

Size: 592 Bytes

Versions: 7

Compression:

Stored size: 592 Bytes

Contents

# frozen_string_literal: true

document_url = polymorphic_url(@document)
json.links do
  json.self document_url
end

json.data do
  json.id @document.id
  json.type @document[blacklight_config.view_config(:show).display_type_field]
  json.attributes do
    doc_presenter = show_presenter(@document)

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

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
blacklight-7.3.0 app/views/catalog/show.json.jbuilder
blacklight-7.2.0 app/views/catalog/show.json.jbuilder
blacklight-7.1.0 app/views/catalog/show.json.jbuilder
blacklight-7.1.0.alpha app/views/catalog/show.json.jbuilder
blacklight-7.0.1 app/views/catalog/show.json.jbuilder
blacklight-7.0.0 app/views/catalog/show.json.jbuilder
blacklight-7.0.0.rc2 app/views/catalog/show.json.jbuilder