This is the two system preferences controlling this feature, and the
updatedatabase addition using db verion 3.01.00.040
---
 admin/systempreferences.pl                         |    2 ++
 installer/data/mysql/en/mandatory/sysprefs.sql     |    2 ++
 .../1-Obligatoire/unimarc_standard_systemprefs.sql |    2 ++
 installer/data/mysql/updatedatabase.pl             |    8 ++++++++
 kohaversion.pl                                     |    2 +-
 5 files changed, 15 insertions(+), 1 deletions(-)

diff --git a/admin/systempreferences.pl b/admin/systempreferences.pl
index 902f8ce..5498b91 100755
--- a/admin/systempreferences.pl
+++ b/admin/systempreferences.pl
@@ -165,6 +165,7 @@ $tabsysprefs{BranchTransferLimitsType}       = 
"Circulation";
 $tabsysprefs{AllowNotForLoanOverride}        = "Circulation";
 $tabsysprefs{RenewalPeriodBase}              = "Circulation";
 $tabsysprefs{FilterBeforeOverdueReport}      = "Circulation";
+$tabsysprefs{AllowHoldDateInFuture}          = "Circulation";
 
 # Staff Client
 $tabsysprefs{TemplateEncoding}        = "StaffClient";
@@ -308,6 +309,7 @@ $tabsysprefs{OPACViewOthersSuggestions}  = "OPAC";
 $tabsysprefs{URLLinkText}                = "OPAC";
 $tabsysprefs{OPACShelfBrowser}           = "OPAC";
 $tabsysprefs{OPACDisplayRequestPriority} = "OPAC";
+$tabsysprefs{OPACAllowHoldDateInFuture}  = "OPAC";
 
 # OPAC
 $tabsysprefs{SearchMyLibraryFirst} = "OPAC";
diff --git a/installer/data/mysql/en/mandatory/sysprefs.sql 
b/installer/data/mysql/en/mandatory/sysprefs.sql
index 069c647..6764d53 100644
--- a/installer/data/mysql/en/mandatory/sysprefs.sql
+++ b/installer/data/mysql/en/mandatory/sysprefs.sql
@@ -1,5 +1,7 @@
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('acquisitions','normal','Choose Normal, budget-based acquisitions, or 
Simple bibliographic-data acquisitions','simple|normal','Choice');
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('advancedMARCeditor',0,'If ON, the MARC editor won\'t display 
field/subfield descriptions','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES ('AllowHoldDateInFuture','0','If set a date field is displayed on the 
Hold screen of the Staff Interface, allowing the hold date to be set in the 
future.','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES ('OPACAllowHoldDateInFuture','0','If set, along with the 
AllowHoldDateInFuture system preference, OPAC users can set the date of a hold 
to be in the future.','','YesNo');
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('AmazonEnabled',0,'Turn ON Amazon Content - You MUST set AWSAccessKeyID 
and AmazonAssocTag if enabled','','YesNo');
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('AmazonReviews',0,'Display Amazon review on staff interface - You MUST 
set AWSAccessKeyID and AmazonAssocTag if enabled','','YesNo');
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('AmazonSimilarItems',0,'Turn ON Amazon Similar Items feature  - You MUST 
set AWSAccessKeyID and AmazonAssocTag if enabled','','YesNo');
diff --git 
a/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql 
b/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql
index 9e8547a..9d706e1 100644
--- a/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql
+++ b/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql
@@ -1,5 +1,7 @@
 set NAMES 'utf8';
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('advancedMARCeditor', '0', 'Si ce paramètre est mis à 1, l''éditeur MARC 
n''affichera pas les libellés des champs/sous-champs, seulement leur code. 
Devrait être à 0 dans la plupart des cas.', '', '');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES ('AllowHoldDateInFuture','0','Si Activé, un champ date est affiché à 
l''écran des réservations pour l''intranet, permettant de positionner la date 
de réservation dans le futur.','','YesNo');
+INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES ('OPACAllowHoldDateInFuture','0','Si Activé avec AllowHoldDateInFuture, 
Les utilisateurs à l''OPAC peuvent positionner la date de réservation dans le 
futur.','','YesNo');
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('AmazonEnabled', '0', 'Ce paramètre active la récupération des images de 
couverture sur Amazon. Vous DEVEZ positionner AmazonDevKey AmazonAssocTag si 
vous activez cette option', '', 'YesNo');
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('AmazonReviews',0,'Affiche dans l''interface pro la description Amazon 
des livres - Vous DEVEZ définir AmazonDevKey et AmazonAssocTag si vous activez 
cette fonction','','YesNo');
 INSERT INTO `systempreferences` (variable,value,explanation,options,type) 
VALUES('AmazonSimilarItems','0','Active ou non les fonctions Amazon ''les 
lecteurs ayant acheté...'' - Vous DEVEZ définir AmazonDevKey et AmazonAssocTag 
si vous activez cette fonction','','YesNo');
diff --git a/installer/data/mysql/updatedatabase.pl 
b/installer/data/mysql/updatedatabase.pl
index 4954962..a10585c 100755
--- a/installer/data/mysql/updatedatabase.pl
+++ b/installer/data/mysql/updatedatabase.pl
@@ -2488,6 +2488,14 @@ if (C4::Context->preference("Version") < 
TransformToNum($DBversion)) {
     print "Upgrade to $DBversion done (added SpineLabelFormat and 
SpineLabelAutoPrint sysprefs)\n";
 }
 
+$DBversion = '3.01.00.040';
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+    $dbh->do("INSERT INTO systempreferences 
(variable,value,options,explanation,type)VALUES('AllowHoldDateInFuture','0','If 
set a date field is displayed on the Hold screen of the Staff Interface, 
allowing the hold date to be set in the future.','','YesNo')");
+    $dbh->do("INSERT INTO systempreferences 
(variable,value,options,explanation,type)VALUES('OPACAllowHoldDateInFuture','0','If
 set, along with the AllowHoldDateInFuture system preference, OPAC users can 
set the date of a hold to be in the future.','','YesNo')");
+    SetVersion ($DBversion);
+    print "Upgrade to $DBversion done (AllowHoldDateInFuture and 
OPACAllowHoldDateInFuture sysprefs)\n";
+}
+
 =item DropAllForeignKeys($table)
 
   Drop all foreign keys of the table $table
diff --git a/kohaversion.pl b/kohaversion.pl
index 5509870..98eeb31 100644
--- a/kohaversion.pl
+++ b/kohaversion.pl
@@ -10,7 +10,7 @@
 use strict;
 
 sub kohaversion {
-    our $VERSION = '3.01.00.039';
+    our $VERSION = '3.01.00.040';
     # version needs to be set this way
     # so that it can be picked up by Makefile.PL
     # during install
-- 
1.6.0.4

_______________________________________________
Koha-patches mailing list
[email protected]
http://lists.koha.org/mailman/listinfo/koha-patches

Reply via email to