From 571b4bd2d14115f4fccb9377df3a6c98dc8c7a1a Mon Sep 17 00:00:00 2001 From: hdl Date: Mon, 31 Jul 2006 12:51:56 +0000 Subject: [PATCH] Bug Fixing : displaying holdingbranch list --- reports/catalogue_stats.pl | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/reports/catalogue_stats.pl b/reports/catalogue_stats.pl index 02ec98e498..0c987c1e9d 100755 --- a/reports/catalogue_stats.pl +++ b/reports/catalogue_stats.pl @@ -205,7 +205,7 @@ if ($do_it) { my $branches=getbranches(); my %select_branches; $select_branches{""} = ""; - foreach my $branch (keys %$branches) { + foreach my $branch (sort keys %$branches) { push @select, $branch; $select_branches{$branch} = $branches->{$branch}->{'branchname'}; } @@ -220,9 +220,16 @@ if ($do_it) { $req->execute; undef @select; push @select,""; + my %select_location; + $select_location{""} = ""; + while (my $items =$req->fetchrow_hashref) { + push @select, $items->{"holdingbranch"}; + $select_location{$items->{'holdingbranch'}} = $branches->{$items->{'holdingbranch'}}->{'branchname'}; + } my $CGIlocation=CGI::scrolling_list( -name => 'Filter', -id => 'holdingbranch', -values => \@select, + -labels => \%select_location, -size => 1, -multiple => 0 ); -- 2.39.5