[Koha-bugs] [Bug 25007] New: Script to deal with Amazon images in detail.tt causes problem

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Mar 27 21:30:34 CET 2020


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25007

            Bug ID: 25007
           Summary: Script to deal with Amazon images in detail.tt causes
                    problem
 Change sponsored?: ---
           Product: Koha
           Version: master
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P5 - low
         Component: Staff Client
          Assignee: koha-bugs at lists.koha-community.org
          Reporter: lucas at bywatersolutions.com
        QA Contact: testopia at bugs.koha-community.org
                CC: gmcharlt at gmail.com

In detail.tt there is a verify_images() function. It checks to see if images
from Amazon are 1px X 1px, if they are it removes the image but also updates
the bootstrap class from col-xs-9 to col-xs-12.

We build the Amazon cover images like this:
<img src="https://images-na.ssl-images-amazon.com/images/P/[% normalized_isbn |
html %].01.MZZZZZZZ.jpg" alt="" />

Any record without a ISBN ends up looking like this:
https://images-na.ssl-images-amazon.com/images/P/.01.MZZZZZZZ.jpg

Which turns out to be a 1px X 1px image.

If you also have local images on it then forces the image down and into a weird
place.

TO RECREATE:
-Have Amazon images turned on and local images too.
-Have a record with a local cover image
-Make sure the record has no ISBN in 020 field. 
-Load detail page of that record and see that the local cover images is not on
the right hand side like it should be but forced underneath
'catalogue_detail_biblio' in an odd spot.

-- 
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.


More information about the Koha-bugs mailing list