[Patches] [PATCH] Bug 7364: Possible to get to FA item add without current
koha-patchbot at kohaaloha.com
koha-patchbot at kohaaloha.com
Wed Dec 21 03:12:24 NZDT 2011
From: D Ruth Bavousett <ruth at bywatersolutions.com>
Date: Fri, 16 Dec 2011 10:38:47 -0500
Subject: [PATCH] Bug 7364: Possible to get to FA item add without current
branch being defined.
Some paths to the FA item-add screen didn't have a branch defined--if the param is set,
use it, otherwise, use the user's logged in branch.
Signed-off-by: Chris Cormack <chrisc at catalyst.net.nz>
---
cataloguing/additem.pl | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/cataloguing/additem.pl b/cataloguing/additem.pl
index 70ca4a9..cbad0b6 100755
--- a/cataloguing/additem.pl
+++ b/cataloguing/additem.pl
@@ -661,10 +661,7 @@ my $onlymine = C4::Context->preference('IndependantBranches') &&
C4::Context->userenv &&
C4::Context->userenv->{flags}!=1 &&
C4::Context->userenv->{branch};
-my $branch = C4::Context->userenv->{branch};
-if ($frameworkcode eq 'FA'){
- $branch = $input->param('branch');
-}
+my $branch = $input->param{'branch'} || C4::Context->userenv->{branch};
my $branches = GetBranchesLoop($branch,$onlymine); # build once ahead of time, instead of multiple times later.
# We generate form, from actuel record
--
1.7.5.4
More information about the Patches
mailing list