From 09895c5fe68ba8b2b20fb0ebe09aef535280fbfa Mon Sep 17 00:00:00 2001 From: Henri-Damien LAURENT Date: Wed, 17 Feb 2010 14:20:19 +0100 Subject: [PATCH] Bug 4194 : Adding ILS-DI System preferences Signed-off-by: Galen Charlton --- installer/data/mysql/en/mandatory/sysprefs.sql | 2 ++ .../1-Obligatoire/unimarc_standard_systemprefs.sql | 1 + installer/data/mysql/updatedatabase.pl | 9 +++++++++ .../en/modules/admin/preferences/web-services.pref | 11 +++++++++++ 4 files changed, 23 insertions(+) diff --git a/installer/data/mysql/en/mandatory/sysprefs.sql b/installer/data/mysql/en/mandatory/sysprefs.sql index 39a6b004a5..29e904cdd1 100644 --- a/installer/data/mysql/en/mandatory/sysprefs.sql +++ b/installer/data/mysql/en/mandatory/sysprefs.sql @@ -284,3 +284,5 @@ INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AutoSelfCheckPass','','Password to be used for automatic web-based self-check. Only applies if AutoSelfCheckAllowed syspref is turned on.','','free'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('soundon','0','Enable circulation sounds during checkin and checkout in the staff interface. Not supported by all web browsers yet.','','YesNo'); INSERT INTO `systempreferences` ( `variable` , `value` , `options` , `explanation` , `type` ) VALUES ( 'PrintNoticesMaxLines', '0', '', 'If greater than 0, sets the maximum number of lines an overdue notice will print. If the number of items is greater than this number, the notice will end with a warning asking the borrower to check their online account for a full list of overdue items.', 'Integer' ); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ILS-DI','0','Enables ILS-DI services at OPAC.','','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ILS-DI:Authorized_IPs','','.','Restricts usage of ILS-DI to some IPs','Free'); 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 57b808ba5b..e3ce7f3217 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 @@ -287,3 +287,4 @@ INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('AutoSelfCheckPass','','Mot de passe utilisé pour le prêt autocontrôlé. Ne s''applique que dans le cas de l''activation de la préférence AutoSelfCheckout.','','free'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('soundon','0','Activer les événements sonores de circulation pendant le prêt et le retour dans l''intranet. N''est pas encore supporté par tous les navigateurs web.','','YesNo'); INSERT INTO `systempreferences` ( `variable` , `value` , `options` , `explanation` , `type` ) VALUES ( 'PrintNoticesMaxLines', '0', '', 'If greater than 0, sets the maximum number of lines an overdue notice will print. If the number of items is greater than this number, the notice will end with a warning asking the borrower to check their online account for a full list of overdue items.', 'Integer' ); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('ILS-DI','0','Active les services ILS-DI à l''OPAC.','','YesNo'); diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 49483de39a..02239f9329 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -3532,6 +3532,15 @@ if (C4::Context->preference('Version') < TransformToNum($DBversion)){ SetVersion ($DBversion); } +$DBversion = "3.01.00.126"; +if (C4::Context->preference("Version") < TransformToNum($DBversion)) { + $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ILS-DI','0','Enable ILS-DI services. See http://your.opac.name/cgi-bin/koha/ilsdi.pl for online documentation.','','YesNo')"); + $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ILS-DI:AuthorizedIPs','127.0.0.1','A comma separated list of IP addresses authorized to access the web services.','','free')"); + + print "Upgrade to $DBversion done (Adding ILS-DI updates and ILS-DI:Authorized_IPs)\n"; + SetVersion ($DBversion); +} + =item DropAllForeignKeys($table) Drop all foreign keys of the table $table diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web-services.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web-services.pref index 39e4bb228c..9b0b10111b 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web-services.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web-services.pref @@ -22,3 +22,14 @@ Web Services: - pref: "OAI-PMH:ConfFile" class: file - . If empty, Koha OAI Server operates in normal mode, otherwise it operates in extended mode. In extended mode, it's possible to parameter other formats than marcxml or Dublin Core. OAI-PMH:ConfFile specify a YAML configuration file which list available metadata formats and XSL file used to create them from marcxml records. + ILS-DI + - + - pref: ILS-DI + choices: + yes: Enable + no: Disable + - Enable ILS-DI services for OPAC users + - + - pref: ILS-DI:Authorized_IPs + class: Text + - allowed Ips to use the ILS-DI services -- 2.39.5