Summary: | Add data-isbn and data-title to lists for plugin cover images | ||
---|---|---|---|
Product: | Koha | Reporter: | Matt Blenkinsop <matt.blenkinsop> |
Component: | OPAC | Assignee: | Matt Blenkinsop <matt.blenkinsop> |
Status: | Pushed to main --- | QA Contact: | Martin Renvoize (ashimema) <martin.renvoize> |
Severity: | trivial | ||
Priority: | P5 - low | CC: | david, martin.renvoize, wainuiwitikapark |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: |
This enhancement adds cover images to OPAC lists, for OPAC enabled cover image sources.
(Note: This currently only displays nicely with one source of cover images. With multiple sources enabled, the images are listed vertically.)
|
Version(s) released in: |
25.05.00
|
Circulation function: | |||
Attachments: |
Bug 38422: Allow plugin cover images in OPAC lists
Bug 38422: Allow plugin cover images in OPAC lists |
Description
Matt Blenkinsop
2024-11-12 11:01:13 UTC
Created attachment 174401 [details] [review] Bug 38422: Allow plugin cover images in OPAC lists This patch updates the template to allow cover images from plugins in the OPAC list page. It adds a data-isbn and data-title attribute to the cover images element and also moves the element below the setting of the title so that we can pass that directly. It also adds the script call to allow the plugin method to work on the page Test plan: 1) View the patch diff and note that the data attributes have been added correctly 2) View the patch diff and note that the <a> tag has been moved below the setting of the img_title template variable 3) View the patch diff and note that the CoverImagePlugins variable has been set correctly (compare to the intranet file detail.tt for reference if needed) 4) Confirm that no changes have been made to any elements beyond adding the data attributes Created attachment 175412 [details] [review] Bug 38422: Allow plugin cover images in OPAC lists This patch updates the template to allow cover images from plugins in the OPAC list page. It adds a data-isbn and data-title attribute to the cover images element and also moves the element below the setting of the title so that we can pass that directly. It also adds the script call to allow the plugin method to work on the page Test plan: 1) View the patch diff and note that the data attributes have been added correctly 2) View the patch diff and note that the <a> tag has been moved below the setting of the img_title template variable 3) View the patch diff and note that the CoverImagePlugins variable has been set correctly (compare to the intranet file detail.tt for reference if needed) 4) Confirm that no changes have been made to any elements beyond adding the data attributes Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Trivial, non-invasive, addition of plugin support hook in the OPAC. Going straight for a PQA here.. we're using it in production already in 23.11.x and beyond. Pushed for 25.05! Well done everyone, thank you! Checking to see if this is an enhancement, rather than a bug. Should I add a bug for displaying multiple images nicely, like we do in other areas of the OPAC and staff interface, instead of running vertically down the page? This is in the commit log for 24.11, though not noted here yet. Not backporting to 24.05.x unless requested |