Bug 15388 - Show Syndetics covers by UPC in search results
authorNick Clemens <nick@bywatersolutions.com>
Fri, 26 Aug 2016 19:20:34 +0000 (19:20 +0000)
committerBrendan Gallagher <brendan@bywatersolutions.com>
Tue, 11 Oct 2016 13:23:15 +0000 (13:23 +0000)
Syndetics code accepts UPC and OCLC numbers, however, we were only passing this if there
was an ISBN. This patch alters the code to search if either an ISBN or
UPC is present

To test:
Enable syndetics (will need an account)
Search for items with UPCs or OCLC numbers and no ISBN (DVDs)
Note there are no images in search results but there are in details
Apply patch
Note that items with images in details now also have images in results

Signed-off-by: Barbara.Johnson@bedfordtx.gov
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-results.tt

index 7301d70..7cd6b7a 100644 (file)
                                                         [% END %]
 
                                                         [% IF ( SyndeticsEnabled && SyndeticsCoverImages ) %]
-                                                            [% IF SEARCH_RESULT.normalized_isbn %]
+                                                            [% IF ( SEARCH_RESULT.normalized_isbn || SEARCH_RESULT.normalized_upc || SEARCH_RESULT.normalized_oclc ) %]
                                                                     [% IF ( using_https ) %]
                                                                         <span title="[% SEARCH_RESULT.biblionumber %]" id="syndetics-thumbnail[% loop.count %]"><img src="https://secure.syndetics.com/index.aspx?isbn=[% SEARCH_RESULT.normalized_isbn %]/SC.GIF&amp;client=[% SyndeticsClientCode %]&amp;type=xw10&amp;upc=[% SEARCH_RESULT.normalized_upc %]&amp;oclc=[% SEARCH_RESULT.normalized_oclc %]" alt="" class="item-thumbnail" /></span>
                                                                     [% ELSE %]