Browse Source

Bug 10860 [QA Followup] - Rename system preferences

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
3.18.x
Kyle Hall 8 years ago
committed by Tomas Cohen Arazi
parent
commit
64eca4693c
  1. 4
      C4/Items.pm
  2. 2
      circ/circulation.pl
  3. 4
      installer/data/mysql/sysprefs.sql
  4. 6
      installer/data/mysql/updatedatabase.pl
  5. 4
      koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref
  6. 2
      koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt
  7. 2
      koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt

4
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);

2
circ/circulation.pl

@ -336,7 +336,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(

4
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'),

6
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);
}

4
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

2
koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt

@ -549,7 +549,7 @@ No patron matched <span class="ex">[% message %]</span>
<button class="btn btn-small action" id="cleardate" name="cleardate" onclick="this.checked = false; this.form.duedatespec.value = ''; this.form.stickyduedate.checked = false; this.form.barcode.focus(); return false;" >Clear</button>
</div>[% END %]
[% IF Koha.Preference('On-site checkouts') %]
[% IF Koha.Preference('OnSiteCheckouts') %]
<div class="onsite_checkout-select">
[% IF noissues %]
<input type="checkbox" id="onsite_checkout" name="onsite_checkout_forced" checked="checked" disabled="disabled" /> <label for="onsite_checkout">On-site checkout</label>

2
koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt

@ -56,7 +56,7 @@
<div id="tabs" class="toptabs">
[% IF Koha.Preference('On-site checkouts') %]
[% IF Koha.Preference('OnSiteCheckouts') %]
<ul>
<li><a href="#readingrec" id="tab_all">All</a></li>
<li><a href="#readingrec" id="tab_checkout">Checkouts</a></li>

Loading…
Cancel
Save