Adding branch selection if SearchMyLibraryFirst is set

Antoine .... Your turn
This commit is contained in:
hdl 2006-10-11 13:14:46 +00:00
parent cd222f1713
commit 18551e4c4e
1 changed files with 4 additions and 1 deletions

View File

@ -75,7 +75,10 @@ if (C4::Context->preference("SearchMyLibraryFirst")){
my %row =('value' => $thisbranch,
'branchname' => $branches->{$thisbranch}->{'branchname'},
);
$row{'selected'} = 1 if ($thisbranch eq C4::Context->userenv->{branch});
$row{'selected'} = C4::Context->userenv->{branch} if ($thisbranch eq C4::Context->userenv->{branch});
foreach (keys %row){
warn "$_ : $row{$_}";
}
push @branchloop, \%row;
}
$template->param("mylibraryfirst"=>1,"branchloop"=>\@branchloop);