From df99b9b69c1bfc550002a7949efee7d093670af7 Mon Sep 17 00:00:00 2001 From: Galen Charlton Date: Sun, 14 Feb 2010 18:30:08 -0500 Subject: [PATCH] bug 1542 followup - tweak to keep handling the UI selected value out of C4 Signed-off-by: Galen Charlton --- C4/Reports/Guided.pm | 1 - reports/dictionary.pl | 5 ++++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/C4/Reports/Guided.pm b/C4/Reports/Guided.pm index 3cdd5b46fe..108d57a9c7 100644 --- a/C4/Reports/Guided.pm +++ b/C4/Reports/Guided.pm @@ -162,7 +162,6 @@ sub get_report_areas { my %hashrep; $hashrep{id} = $i + 1; $hashrep{name} = $reports[$i]; - $hashrep{selected} = 1 if $hashrep{id} == $area; push @reports2, \%hashrep; } return ( \@reports2 ); diff --git a/reports/dictionary.pl b/reports/dictionary.pl index 3fd4e520e5..4f3814e2b1 100755 --- a/reports/dictionary.pl +++ b/reports/dictionary.pl @@ -55,7 +55,10 @@ my ( $template, $borrowernumber, $cookie ) = get_template_and_user( if ($phase eq 'View Dictionary'){ # view the dictionary we use to set up abstract variables such as all borrowers over fifty who live in a certain town - my $areas = get_report_areas($area); + my $areas = get_report_areas(); + foreach (@{ $areas }) { + $_->{selected} = 1 if $_->{id} eq $area; # mark active area + } my $definitions = get_from_dictionary($area); $template->param( 'areas' => $areas , 'start_dictionary' => 1, -- 2.39.5