From 752ce30ddb65db78ca8ceeb9c51b4d3768ec26c6 Mon Sep 17 00:00:00 2001 From: Chris Cormack Date: Sat, 2 May 2009 09:39:25 +1200 Subject: [PATCH] Adding warnings, fixing a bug that meant the title of an item that had a fine was never printed Signed-off-by: Galen Charlton Signed-off-by: Henri-Damien LAURENT --- C4/Members.pm | 1 + koha-tmpl/opac-tmpl/prog/en/modules/opac-account.tmpl | 4 ++-- opac/opac-account.pl | 6 +----- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/C4/Members.pm b/C4/Members.pm index b4b0e751d6..8cc32bdc64 100644 --- a/C4/Members.pm +++ b/C4/Members.pm @@ -1169,6 +1169,7 @@ sub GetMemberAccountRecords { while ( my $data = $sth->fetchrow_hashref ) { my $biblio = GetBiblioFromItemNumber($data->{itemnumber}) if $data->{itemnumber}; $data->{biblionumber} = $biblio->{biblionumber}; + $data->{title} = $biblio->{title}; $acctlines[$numlines] = $data; $numlines++; $total += int(100 * $data->{'amountoutstanding'}); # convert float to integer to avoid round-off errors diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-account.tmpl b/koha-tmpl/opac-tmpl/prog/en/modules/opac-account.tmpl index 37bb4b6244..395bf032e0 100644 --- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-account.tmpl +++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-account.tmpl @@ -37,7 +37,7 @@ - + $ $ @@ -59,4 +59,4 @@ - \ No newline at end of file + diff --git a/opac/opac-account.pl b/opac/opac-account.pl index 95df84224c..43a1e0cd50 100755 --- a/opac/opac-account.pl +++ b/opac/opac-account.pl @@ -25,6 +25,7 @@ use C4::Circulation; use C4::Auth; use C4::Output; use C4::Dates qw/format_date/; +use warnings; my $query = new CGI; my ( $template, $borrowernumber, $cookie ) = get_template_and_user( @@ -59,11 +60,6 @@ for ( my $i = 0 ; $i < $numaccts ; $i++ ) { if ( $accts->[$i]{'amountoutstanding'} >= 0 ) { $accts->[$i]{'amountoutstandingcredit'} = 1; } - if ( $accts->[$i]{'accounttype'} ne 'F' - && $accts->[$i]{'accounttype'} ne 'FU' ) - { - $accts->[$i]{'print_title'}; # FIXME: Useless use of hash element in void context - } } # add the row parity -- 2.39.5