[Koha-bugs] [Bug 26587] detail.pl is very slow for records with many items
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Sat Nov 6 17:01:33 CET 2021
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26587
Joonas Kylmälä <joonas.kylmala at iki.fi> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #120401|0 |1
is obsolete| |
Attachment #120402|0 |1
is obsolete| |
--- Comment #18 from Joonas Kylmälä <joonas.kylmala at iki.fi> ---
Created attachment 127411
-->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=127411&action=edit
Bug 26587: Cache libraries in Koha/Template/Plugins/Branches.pm to improve
performance
This patch caches the Koha::Library object in a hashmap in the Branches object
(GetName, GetURL)
to avoid multiple database lookups while looping many items.
To test:
1. Have a biblio with many items (1000's).
2. View in staff (detail.pl) and opac (opac-detail.pl). Note how long it takes
to load.
3. Apply patch.
4. Repeat 2. Note that pages load faster.
Sponsored-by: Lund University Library
JK: replaced tab indendation with spaces
Signed-off-by: Joonas Kylmälä <joonas.kylmala at iki.fi>
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list