Bugzilla – Attachment 77752 Details for
Bug 21001
OpenLibrary book covers broken
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 21001: Add missing format=json to openlibrary calls
Bug-21001-Add-missing-formatjson-to-openlibrary-ca.patch (text/plain), 1.72 KB, created by
Jonathan Druart
on 2018-08-13 14:34:07 UTC
(
hide
)
Description:
Bug 21001: Add missing format=json to openlibrary calls
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2018-08-13 14:34:07 UTC
Size:
1.72 KB
patch
obsolete
>From c4281a8d718639c4682a8ca23778661c48381c5f Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 13 Aug 2018 11:05:18 -0300 >Subject: [PATCH] Bug 21001: Add missing format=json to openlibrary calls > >See https://github.com/internetarchive/openlibrary/issues/1014 > >Test plan: >Turn on OpenLibraryCovers and OpenLibrarySearch >Do a search at the OPAC >You should see the covers from OpenLibrary as well as the "Searching >Open Library... " and "Found XXX results in OpenLibrary collection" >info >--- > koha-tmpl/opac-tmpl/bootstrap/js/openlibrary.js | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/js/openlibrary.js b/koha-tmpl/opac-tmpl/bootstrap/js/openlibrary.js >index 1c2a9f26cf..9e8ad824e1 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/js/openlibrary.js >+++ b/koha-tmpl/opac-tmpl/bootstrap/js/openlibrary.js >@@ -26,7 +26,7 @@ KOHA.OpenLibrary = new function() { > scriptElement.setAttribute("id", "jsonScript"); > scriptElement.setAttribute("src", > "https://openlibrary.org/api/books?bibkeys=" + escape(bibkeys) + >- "&callback=KOHA.OpenLibrary.olCallBack&jscmd=data"); >+ "&callback=KOHA.OpenLibrary.olCallBack&jscmd=data&format=json"); > scriptElement.setAttribute("type", "text/javascript"); > document.documentElement.firstChild.appendChild(scriptElement); > } >@@ -72,7 +72,7 @@ KOHA.OpenLibrary = new function() { > > var search_url_json = 'https://openlibrary.org/search.json'; > this.search = function( q, page_no, callback ) { >- var params = {q: q}; >+ var params = {q: q, 'format': 'json'}; > if (page_no) { > params.page = page_no; > } >-- >2.11.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 21001
: 77752