Skip to content
  • Owen Leonard's avatar
    Bug 34026: Move translatable cover-handling strings out of opac-bottom.inc · 85a4779f
    Owen Leonard authored and Tomas Cohen Arazi's avatar Tomas Cohen Arazi committed
    
    
    This patch removes several instances from opac-bottom.inc where we
    define strings for translation and use in separate JavaScript files. The
    JavaScript files are updated to use the __() function to mark strings
    for translation.
    
    Note: Definition of the variable NO_COCE_JACKET is removed because it is
    unused.
    
    To test, apply the patch and clear your browser cache if necessary.
    
    - In the staff interface, enable OPAC cover image services:
      - OPACAmazonCoverImages
      - BakerTaylorEnabled
      - GoogleJackets
      - OpenLibraryCovers
    
    - In the OPAC, perform a search and confirm that there are no JS errors
      on the search results page related to cover images.
    - Check the bibliographic detail page as well.
    
    To confirm that the strings are being picked up for translation, run the
    update process for another language, e.g.
    
    perl misc/translator/translate update fr-FR
    
    Then check the newly-built po file: fr-FR-messages-js.po. It should
    list the updated files:
    
     koha-tmpl/opac-tmpl/bootstrap/js/amazonimages.js:8
     koha-tmpl/opac-tmpl/bootstrap/js/amazonimages.js:10
     koha-tmpl/opac-tmpl/bootstrap/js/bakertaylorimages.js:7
     koha-tmpl/opac-tmpl/bootstrap/js/google-jackets.js:77
     koha-tmpl/opac-tmpl/bootstrap/js/openlibrary.js:63
    
    Signed-off-by: default avatarDavid Nind <david@davidnind.com>
    Signed-off-by: default avatarKatrin Fischer <katrin.fischer.83@web.de>
    Signed-off-by: Tomas Cohen Arazi's avatarTomas Cohen Arazi <tomascohen@theke.io>
    85a4779f