From 2caffcddb3ed6abbf4f3abba617e4a2ee792feca Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Thu, 30 Oct 2014 11:07:50 -0400 Subject: [PATCH] Bug 10860 [QA Followup] - Rename system preferences --- C4/Items.pm | 4 ++-- circ/circulation.pl | 2 +- installer/data/mysql/sysprefs.sql | 4 ++-- installer/data/mysql/updatedatabase.pl | 6 +++--- .../en/modules/admin/preferences/circulation.pref | 4 ++-- .../prog/en/modules/circ/circulation.tt | 2 +- .../prog/en/modules/members/readingrec.tt | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/C4/Items.pm b/C4/Items.pm index f8c7d58..fde9d95 100644 --- a/C4/Items.pm +++ b/C4/Items.pm @@ -1301,7 +1301,7 @@ sub GetItemsInfo { home.opac_info as home_branch_opac_info "; $query .= ", issues.onsite_checkout" - if C4::Context->preference("On-site checkouts"); + if C4::Context->preference("OnSiteCheckouts"); $query .= " FROM items LEFT JOIN branches AS holding ON items.holdingbranch = holding.branchcode @@ -1311,7 +1311,7 @@ sub GetItemsInfo { LEFT JOIN itemtypes ON itemtypes.itemtype = " . (C4::Context->preference('item-level_itypes') ? 'items.itype' : 'biblioitems.itemtype'); $query .= " LEFT JOIN issues ON issues.itemnumber = items.itemnumber" - if C4::Context->preference("On-site checkouts"); + if C4::Context->preference("OnSiteCheckouts"); $query .= " WHERE items.biblionumber = ? ORDER BY home.branchname, items.enumchron, LPAD( items.copynumber, 8, '0' ), items.dateaccessioned DESC" ; my $sth = $dbh->prepare($query); $sth->execute($biblionumber); diff --git a/circ/circulation.pl b/circ/circulation.pl index 99666cd..497f16e 100755 --- a/circ/circulation.pl +++ b/circ/circulation.pl @@ -322,7 +322,7 @@ if ($barcode) { } } - unless( $query->param('onsite_checkout') and C4::Context->preference("On-site checkouts Force") ) { + unless( $query->param('onsite_checkout') and C4::Context->preference("OnSiteCheckoutsForce") ) { delete $question->{'DEBT'} if ($debt_confirmed); foreach my $impossible ( keys %$error ) { $template->param( diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql index 32b0273..db02830 100644 --- a/installer/data/mysql/sysprefs.sql +++ b/installer/data/mysql/sysprefs.sql @@ -147,8 +147,8 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('ImageLimit','5','','Limit images stored in the database by the Patron Card image manager to this number.','Integer'), ('IncludeSeeFromInSearches','0','','Include see-from references in searches.','YesNo'), ('IndependentBranches','0',NULL,'If ON, increases security between libraries','YesNo'), -('On-site checkouts','0','','Enable/Disable the on-site checkouts feature','YesNo'), -('On-site checkouts Force','0','','Enable/Disable the on-site for all cases (Even if a user is debarred, etc.)','YesNo'), +('OnSiteCheckouts','0','','Enable/Disable the on-site checkouts feature','YesNo'), +('OnSiteCheckoutsForce','0','','Enable/Disable the on-site for all cases (Even if a user is debarred, etc.)','YesNo'), ('InProcessingToShelvingCart','0','','If set, when any item with a location code of PROC is \'checked in\', it\'s location code will be changed to CART.','YesNo'), ('INTRAdidyoumean',NULL,NULL,'Did you mean? configuration for the Intranet. Do not change, as this is controlled by /cgi-bin/koha/admin/didyoumean.pl.','Free'), ('IntranetBiblioDefaultView','normal','normal|marc|isbd|labeled_marc','Choose the default detail view in the staff interface; choose between normal, labeled_marc, marc or isbd','Choice'), diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 6068b91..3f97f93 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -8957,12 +8957,12 @@ if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { $dbh->do(q{ INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) - VALUES('On-site checkouts','0','Enable/Disable the on-site checkouts feature','','YesNo'); + VALUES('OnSiteCheckouts','0','Enable/Disable the on-site checkouts feature','','YesNo'); }); $dbh->do(q{ INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) - VALUES('On-site checkouts Force','0','Enable/Disable the on-site for all cases (Even if a user is debarred, etc.)','','YesNo'); + VALUES('OnSiteCheckoutsForce','0','Enable/Disable the on-site for all cases (Even if a user is debarred, etc.)','','YesNo'); }); $dbh->do(q{ ALTER TABLE issues ADD COLUMN onsite_checkout INT(1) NOT NULL DEFAULT 0 AFTER issuedate; @@ -8970,7 +8970,7 @@ if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { $dbh->do(q{ ALTER TABLE old_issues ADD COLUMN onsite_checkout INT(1) NOT NULL DEFAULT 0 AFTER issuedate; }); - print "Upgrade to $DBversion done (Bug 10860: Add new system preference On-site checkouts + fields [old_]issues.onsite_checkout)\n"; + print "Upgrade to $DBversion done (Bug 10860: Add new system preference OnSiteCheckouts + fields [old_]issues.onsite_checkout)\n"; SetVersion($DBversion); } diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref index 34078f5..657339d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref @@ -384,13 +384,13 @@ Circulation: - "it will be updated to the right-hand value. E.g. '-1: 0' will cause an item that was set to 'Ordered' to now be available for loan." - Each pair of values should be on a separate line. - - - pref: On-site checkouts + - pref: OnSiteCheckouts choices: yes: Enable no: Disable - the on-site checkouts feature. - - - pref: On-site checkouts Force + - pref: OnSiteCheckoutsForce choices: yes: Enable no: Disable diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt index e439cb5..febc37c 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt @@ -533,7 +533,7 @@ No patron matched [% message %] [% END %] - [% IF Koha.Preference('On-site checkouts') %] + [% IF Koha.Preference('OnSiteCheckouts') %]
[% IF noissues %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt index c8f9238..773995a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt @@ -56,7 +56,7 @@
- [% IF Koha.Preference('On-site checkouts') %] + [% IF Koha.Preference('OnSiteCheckouts') %]