Bugzilla – Attachment 26015 Details for
Bug 10276
Extend IndependentBranches to support groups of libraries
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10276 [QA Followup 3] - Fix inability to change patron's branch
Bug-10276-QA-Followup-3---Fix-inability-to-change-.patch (text/plain), 2.27 KB, created by
Kyle M Hall
on 2014-03-10 15:02:37 UTC
(
hide
)
Description:
Bug 10276 [QA Followup 3] - Fix inability to change patron's branch
Filename:
MIME Type:
Creator:
Kyle M Hall
Created:
2014-03-10 15:02:37 UTC
Size:
2.27 KB
patch
obsolete
>From c389e7960007a894e8ecc006778662805b56ed3d Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Mon, 10 Mar 2014 11:02:01 -0400 >Subject: [PATCH] Bug 10276 [QA Followup 3] - Fix inability to change patron's branch > >--- > members/memberentry.pl | 31 ++++++++++++++++++++++--------- > 1 files changed, 22 insertions(+), 9 deletions(-) > >diff --git a/members/memberentry.pl b/members/memberentry.pl >index 429768a..e6ecc8d 100755 >--- a/members/memberentry.pl >+++ b/members/memberentry.pl >@@ -311,14 +311,22 @@ if ($op eq 'save' || $op eq 'insert'){ > $newdata{'surname'} = uc($newdata{'surname'}); > } > >- if (C4::Context->preference("IndependentBranches")) { >- unless ( C4::Context->IsSuperLibrarian() ){ >- $debug and print STDERR " $newdata{'branchcode'} : ".$userenv->{flags}.":".$userenv->{branch}; >- unless (!$newdata{'branchcode'} || $userenv->{branch} eq $newdata{'branchcode'}){ >- push @errors, "ERROR_branch"; >- } >+if ( C4::Context->preference("IndependentBranches") ) { >+ unless ( C4::Context->IsSuperLibrarian() ) { >+ $debug && warn " $newdata{'branchcode'} : " . $userenv->{flags} . ":" . $userenv->{branch}; >+ >+ unless ( >+ !$newdata{'branchcode'} >+ || GetIndependentGroupModificationRights( >+ { for => $newdata{'branchcode'} } >+ ) >+ ) >+ { >+ push @errors, "ERROR_branch"; >+ } > } >- } >+} >+ > # Check if the userid is unique > unless (Check_Userid($newdata{'userid'},$borrowernumber)) { > push @errors, "ERROR_login_exist"; >@@ -447,10 +455,15 @@ if ($nok or !$nodouble){ > $template->param( step_1 => 1,step_2 => 1,step_3 => 1, step_4 => 1, step_5 => 1, step_6 => 1); > } > } >-if (C4::Context->preference("IndependentBranches")) { >+if ( C4::Context->preference("IndependentBranches") ) { > my $userenv = C4::Context->userenv; > if ( !C4::Context->IsSuperLibrarian() && $data{'branchcode'} ) { >- unless ($userenv->{branch} eq $data{'branchcode'}){ >+ unless ( >+ GetIndependentGroupModificationRights( >+ { for => $data{'branchcode'} } >+ ) >+ ) >+ { > print $input->redirect("/cgi-bin/koha/members/members-home.pl"); > exit; > } >-- >1.7.2.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 10276
:
18205
|
18479
|
18519
|
18716
|
18717
|
18850
|
20773
|
21145
|
22791
|
23037
|
23484
|
23489
|
23637
|
23641
|
23953
|
23992
|
24427
|
24428
|
25722
|
25723
|
25724
|
26015
|
26026
|
26027
|
26028
|
26029
|
28354
|
28355
|
28356
|
28357
|
28358
|
28359
|
28360
|
28361
|
28365
|
28366
|
28367
|
36027
|
36028
|
36029
|
36030
|
36031
|
36032
|
41064
|
41065
|
41066
|
41067
|
41068
|
41069
|
41070