[Koha-bugs] [Bug 28709] Fetching biblio objects for custom covers is inefficient
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Tue Jul 20 13:43:49 CEST 2021
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28709
Nick Clemens <nick at bywatersolutions.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #122835|0 |1
is obsolete| |
--- Comment #6 from Nick Clemens <nick at bywatersolutions.com> ---
Created attachment 122962
-->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=122962&action=edit
Bug 28709: Refactor Koha::Biblio->custom_cover_image_url to allow passing
parameters
Currently the search result template receive a Koha::Biblio object and call the
method.
The searchResults routine already has the isbn, issn, and normalized_isbn
calculated.
Rather than fetching the object and passing to the template we can pass the
parameters,
generate the url, and pass only the URL to the template
To test:
1 - Set the system preferences:
CustomCoverImages : Display
OPACCustomCoverImages: Display
CustomCoverImagesURL:
https://images-na.ssl-images-amazon.com/images/P/{normalized_isbn}.01.LZZZZZZZ.jpg
2 - Search on staff and opac for a term that returns titles with covers, e.g.
'shuffle'
3 - Confirm the covers show
4 - Apply patch
5 - Restart all
6 - Confirm covers still show
7 - prove -v t/db_dependent/Koha/Biblios.t
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list