From 2c2d3a4db3f650461fdb1691a34c7ea409a9ace4 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Tue, 24 Oct 2017 14:44:19 +0200 Subject: [PATCH] Bug 19298: (QA follow-up) Remove GetBiblioData call Content-Type: text/plain; charset=utf-8 In order to do at least something for performance, we could replace the call to GetBiblioData since we are already fetching biblio data with Koha::Biblios. Note that the fields bnotes and bi_notforloan are not used in shelves. Signed-off-by: Marcel de Rooy Tested that notes are also displayed now in non-xslt view. Got the best results in performance with this change say 640ms; with the first patch 740ms and without both 690ms. --- opac/opac-shelves.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/opac/opac-shelves.pl b/opac/opac-shelves.pl index 1feaf57..d8e535c 100755 --- a/opac/opac-shelves.pl +++ b/opac/opac-shelves.pl @@ -270,10 +270,10 @@ if ( $op eq 'view' ) { my @items; while ( my $content = $contents->next ) { my $biblionumber = $content->biblionumber; - my $this_item = GetBiblioData($biblionumber); + my $biblio = Koha::Biblios->find( $biblionumber ); + my $this_item = $biblio->unblessed; my $record = GetMarcBiblio({ biblionumber => $biblionumber }); my $framework = GetFrameworkCode( $biblionumber ); - my $biblio = Koha::Biblios->find( $biblionumber ); $record_processor->options({ interface => 'opac', frameworkcode => $framework -- 2.1.4