From 36c63bac530dd4cc5d50e6925ab4d8baee1b90fc Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Thu, 27 Sep 2012 11:27:50 -0400 Subject: [PATCH] Bug 8839 - Independant Branches - Checkout to patron belonging to another branch Adds the new system preference IndependantBranchesCirculation to control whether IndependantBranches stops one branch from viewing the patron record or issuing items to a patron from a different library. --- C4/Members.pm | 5 +---- installer/data/mysql/sysprefs.sql | 1 + installer/data/mysql/updatedatabase.pl | 7 +++++++ .../prog/en/modules/admin/preferences/admin.pref | 7 +++++++ 4 files changed, 16 insertions(+), 4 deletions(-) diff --git a/C4/Members.pm b/C4/Members.pm index f1136c2..fa40c57 100644 --- a/C4/Members.pm +++ b/C4/Members.pm @@ -252,10 +252,7 @@ sub Search { } } - # $showallbranches was not used at the time SearchMember() was mainstreamed into Search(). - # Mentioning for the reference - - if ( C4::Context->preference("IndependantBranches") ) { # && !$showallbranches){ + if ( C4::Context->preference("IndependantBranches") && C4::Context->preference("IndependantBranchesCirculation") ) { if ( my $userenv = C4::Context->userenv ) { my $branch = $userenv->{'branch'}; if ( ($userenv->{flags} % 2 !=1) && diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql index 7e9f43d..0b4f11f 100644 --- a/installer/data/mysql/sysprefs.sql +++ b/installer/data/mysql/sysprefs.sql @@ -408,3 +408,4 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES(' INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('NotesBlacklist','','List of notes fields that should not appear in the title notes/description separator of details',NULL,'free'); INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES ('SCOUserCSS', '', NULL, 'Add CSS to be included in the SCO module in an embedded