From 39f88e650f2ff2bd82691e701d7e20cba0940a3a Mon Sep 17 00:00:00 2001 From: Paul POULAIN Date: Mon, 8 Oct 2007 14:24:35 -0500 Subject: [PATCH] #1456, automatically suggest user branch as pickup branch Signed-off-by: Chris Cormack Signed-off-by: Joshua Ferraro --- koha-tmpl/opac-tmpl/prog/en/opac-reserve.tmpl | 9 +++++++-- opac/opac-reserve.pl | 4 ++++ 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/koha-tmpl/opac-tmpl/prog/en/opac-reserve.tmpl b/koha-tmpl/opac-tmpl/prog/en/opac-reserve.tmpl index e4c1485337..ae1745e329 100644 --- a/koha-tmpl/opac-tmpl/prog/en/opac-reserve.tmpl +++ b/koha-tmpl/opac-tmpl/prog/en/opac-reserve.tmpl @@ -139,8 +139,13 @@ " />

Pick up from:

diff --git a/opac/opac-reserve.pl b/opac/opac-reserve.pl index 2b59c461cc..90008f31a5 100755 --- a/opac/opac-reserve.pl +++ b/opac/opac-reserve.pl @@ -90,6 +90,10 @@ foreach my $branch ( keys %$branches ) { my %line; $line{branch} = $branches->{$branch}->{'branchname'}; $line{value} = $branch; + warn "===>".$line{value}." eq ".C4::Context->userenv->{'branch'}; + if ($line{value} eq C4::Context->userenv->{'branch'}) { + $line{selected} = 1; + } push @CGIbranchlooparray, \%line; } } -- 2.39.5