From 65b36743073972358bca7b81c6830320b4fabb2c Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Mon, 6 Oct 2014 23:42:19 +0200 Subject: [PATCH] Bug 11926: DB changes This patch adds the syspref in the database. Signed-off-by: Chris Cormack Signed-off-by: Katrin Fischer Signed-off-by: Tomas Cohen Arazi --- installer/data/mysql/sysprefs.sql | 7 +++++++ installer/data/mysql/updatedatabase.pl | 18 ++++++++++++++++++ 2 files changed, 25 insertions(+) diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql index b08a5149fa..5a5d5ae89f 100644 --- a/installer/data/mysql/sysprefs.sql +++ b/installer/data/mysql/sysprefs.sql @@ -424,6 +424,13 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` ('UpdateTotalIssuesOnCirc','0',NULL,'Whether to update the totalissues field in the biblio on each circ.','YesNo'), ('uppercasesurnames','0',NULL,'If ON, surnames are converted to upper case in patron entry form','YesNo'), ('URLLinkText','',NULL,'Text to display as the link anchor in the OPAC','free'), +('UsageStatsCountry', '', 'The country where your library is to show on hea Koha community website', NULL, 'YesNo'), +('UsageStatsID', '', 'This pref is part of Koha but it should not be deleted or updated manually.', '', 'Free'), +('UsageStatsLastUpdateTime', '', 'This pref is part of Koha but it should not be deleted or updated manually.', '', 'Free'), +('UsageStatsLibraryName', '', 'The library name to show on hea Koha community website', NULL, 'Free'), +('UsageStatsLibraryType', 'public', 'public|university', 'The library type to show on hea Koha community website', NULL, 'Choice'), +('UsageStatsLibraryUrl', '', 'The library url to show on hea Koha community website', NULL, 'Free'), +('UsageStatsShare', 0, 'Share data volumetry with Koha community (HEA).', NULL, 'YesNo'), ('UseAuthoritiesForTracings','1','0','Use authority record numbers for subject tracings instead of heading strings.','YesNo'), ('UseBranchTransferLimits','0','','If ON, Koha will will use the rules defined in branch_transfer_limits to decide if an item transfer should be allowed.','YesNo'), ('UseControlNumber','0','','If ON, record control number (w subfields) and control number (001) are used for linking of bibliographic records.','YesNo'), diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 95832e52fa..d43b2c7cd3 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -8820,6 +8820,24 @@ if ( CheckVersion($DBversion) ) { SetVersion ($DBversion); } +$DBversion = "3.17.00.XXX"; +if ( CheckVersion($DBversion) ) { + $dbh->do( + q{ + INSERT INTO systempreferences (variable, value, options, explanation, type ) + VALUES + ('UsageStatsCountry', '', NULL, 'The country where your library is to show on hea Koha community website', 'YesNo'), + ('UsageStatsID', '', NULL, 'This pref is part of Koha but it should not be deleted or updated manually.', 'Free'), + ('UsageStatsLastUpdateTime', '', NULL, 'This pref is part of Koha but it should not be deleted or updated manually.', 'Free'), + ('UsageStatsLibraryName', '', NULL, 'The library name to show on hea Koha community website', 'Free'), + ('UsageStatsLibraryType', 'public', 'public|university', 'The library type to show on hea Koha community website', 'Choice'), + ('UsageStatsLibraryUrl', '', NULL, 'The library url to show on hea Koha community website', 'Free'), + ('UsageStatsShare', 0, NULL, 'Share data volumetry with Koha community (HEA).', 'YesNo') + }); + print "Upgrade to $DBversion done (Bug 11926: Add UsageStats systempreferences (HEA))\n"; + SetVersion($DBversion); +} + =head1 FUNCTIONS =head2 TableExists($table) -- 2.39.5