From 5d1b4ff87568b64a8ee4471903efd4da0bfdded6 Mon Sep 17 00:00:00 2001 From: Fridolyn SOMERS Date: Tue, 8 Oct 2013 16:46:55 +0200 Subject: [PATCH 2/2] Bug 11009 - Add hardcoded limit to OPAC reading records Each reading record will fetch from database all columns of biblio, biblioitems (including marcxml), items and issues or old_issues. So if there are a great number of reading records, the page may create a heavy load on server. Considering it is at OPAC, this may be used to overload the server. This patch adds an hardcoded limit on OPAC reading records : 500. Test plan : - Connect on OPAC with a borrower having less than 500 reading records - Go to "my reading hystory" : opac-readingrecord.pl => Tab "Showing last 50 items" is selected and you see 50 records - Click on "Show all items" tab => You see all records - Connect on OPAC with a borrower having more than 500 reading records - Go to "my reading hystory" : opac-readingrecord.pl => Tab "Showing last 50 items" is selected and you see 50 records - Click on "Show all items" tab => You see 500 records --- koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt | 4 ++-- opac/opac-readingrecord.pl | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt index 7ee7e12..ab9bb53 100644 --- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt +++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt @@ -32,7 +32,7 @@ You have never borrowed anything from this library.
-[% UNLESS ( limit ) %][% END %] +[% IF ( limit == 'full' ) %][% END %]