Module: Blacklight::Marc::Catalog

Extended by:
ActiveSupport::Concern
Defined in:
app/controllers/concerns/blacklight/marc/catalog.rb

Instance Method Summary collapse

Instance Method Details

#librarian_viewObject



11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# File 'app/controllers/concerns/blacklight/marc/catalog.rb', line 11

def librarian_view
  if Blacklight::VERSION >= '8'
    @document = search_service.fetch(params[:id])
    @response = ActiveSupport::Deprecation::DeprecatedObjectProxy.new(@document.response, "The @response instance variable is deprecated and will be removed in Blacklight-marc 8.0")

  else
    deprecated_response, @document = search_service.fetch(params[:id])
    @response = ActiveSupport::Deprecation::DeprecatedObjectProxy.new(deprecated_response, "The @response instance variable is deprecated and will be removed in Blacklight-marc 8.0")
  end

  respond_to do |format|
    format.html do
      return render layout: false if request.xhr?
      # Otherwise draw the full page
    end
  end
end