Sha256: cac463c52bec62f5833ef0070793d8224e74502a634995a78c7484c03b156592

Contents?: true

Size: 682 Bytes

Versions: 7

Compression:

Stored size: 682 Bytes

Contents

# frozen_string_literal: true

document_url = polymorphic_url(@document)
doc_presenter = show_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
    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

7 entries across 7 versions & 1 rubygems

Version Path
blacklight-7.11.1 app/views/catalog/show.json.jbuilder
blacklight-7.10.0 app/views/catalog/show.json.jbuilder
blacklight-7.9.0 app/views/catalog/show.json.jbuilder
blacklight-7.8.1 app/views/catalog/show.json.jbuilder
blacklight-7.8.0 app/views/catalog/show.json.jbuilder
blacklight-7.7.0 app/views/catalog/show.json.jbuilder
blacklight-7.6.0 app/views/catalog/show.json.jbuilder