From efc0851a49fb41d7d1b9be817983ca035990b2c2 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Wed, 6 Apr 2011 13:39:07 +0200 Subject: [PATCH] 6083: Adding some version numbers and newlines to improve output in web installer Signed-off-by: Chris Cormack --- installer/data/mysql/updatedatabase.pl | 60 +++++++++++++------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 8fb9656766..9cbc8db490 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -2547,7 +2547,7 @@ $DBversion = '3.01.00.045'; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("INSERT INTO systempreferences (variable,value,options,explanation,type)VALUES('HidePatronName', '0', '', 'If this is switched on, patron''s cardnumber will be shown instead of their name on the holds and catalog screens', 'YesNo')"); SetVersion ($DBversion); - print "Upgrade to $DBversion done (added a preference to hide the patrons name in the staff catalog)"; + print "Upgrade to $DBversion done (added a preference to hide the patrons name in the staff catalog)\n"; } $DBversion = "3.01.00.046"; @@ -2717,7 +2717,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; "); - SetVersion ($DBversion); + SetVersion ($DBversion);print "Upgrade to $DBversion done (Created table fieldmapping)\n";print "Upgrade to 3.01.00.064 done (Version number skipped: nothing done)\n"; } $DBversion = '3.01.00.065'; @@ -2765,7 +2765,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $DBversion = "3.01.00.068"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("ALTER TABLE issuingrules ADD COLUMN `finedays` int(11) default NULL AFTER `fine` "); - print "Upgrade done (Adding finedays in issuingrules table)\n"; + print "Upgrade to $DBversion done (Adding finedays in issuingrules table)\n"; SetVersion ($DBversion); } @@ -2788,13 +2788,13 @@ CREATE TABLE IF NOT EXISTS `search_history` ( SEARCHHIST $dbh->do($create); - print "Upgrade done (added OPAC search history preference and table)\n"; + print "Upgrade to $DBversion done (added OPAC search history preference and table)\n"; } $DBversion = "3.01.00.070"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("ALTER TABLE authorised_values ADD COLUMN `lib_opac` VARCHAR(80) default NULL AFTER `lib`"); - print "Upgrade done (Added a lib_opac field in authorised_values table)\n"; + print "Upgrade to $DBversion done (Added a lib_opac field in authorised_values table)\n"; } $DBversion = "3.01.00.071"; @@ -3169,14 +3169,14 @@ ALTER table suggestions ADD itemtype VARCHAR(30) default NULL ; SUGGESTIONS - print "Upgrade to $DBversion done Suggestions"; + print "Upgrade to $DBversion done (Suggestions)\n"; SetVersion ($DBversion); } $DBversion = "3.01.00.087"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("ALTER table aqbudgets drop column budget_amount_sublevel;"); - print "Upgrade to $DBversion done drop column budget_amount_sublevel from aqbudgets\n"; + print "Upgrade to $DBversion done (Drop column budget_amount_sublevel from aqbudgets)\n"; SetVersion ($DBversion); } @@ -3319,7 +3319,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $DBversion = "3.01.00.100"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("INSERT INTO `systempreferences` (`variable`, `value`, `options`, `explanation`, `type`) VALUES ('casAuthentication', '0', '', 'Enable or disable CAS authentication', 'YesNo'), ('casLogout', '1', '', 'Does a logout from Koha should also log out of CAS ?', 'YesNo'), ('casServerUrl', 'https://localhost:8443/cas', '', 'URL of the cas server', 'Free')"); - print "Upgrade done (added CAS authentication system preferences)\n"; + print "Upgrade to $DBversion done (added CAS authentication system preferences)\n"; SetVersion ($DBversion); } @@ -3341,14 +3341,14 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do( "UPDATE permissions set description = 'Edit catalog (Modify bibliographic/holdings data)' where module_bit = 9 and code = 'edit_catalogue'" ); - print "Upgrade done (fixed spelling error in edit_catalogue permission)\n"; + print "Upgrade to $DBversion done (fixed spelling error in edit_catalogue permission)\n"; SetVersion ($DBversion); } $DBversion = "3.01.00.103"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("INSERT INTO permissions (module_bit, code, description) VALUES (13, 'moderate_tags', 'Moderate patron tags')"); - print "Upgrade done (adding patron permissions for tags tool)\n"; + print "Upgrade to $DBversion done (adding patron permissions for tags tool)\n"; SetVersion ($DBversion); } @@ -3402,7 +3402,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $DBversion = "3.01.00.106"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("INSERT INTO `systempreferences` (variable,value,options,explanation,type) VALUES ( 'OpacAddMastheadLibraryPulldown', '0', '', 'Adds a pulldown menu to select the library to search on the opac masthead.', 'YesNo' )"); - print "Upgrade done (added OpacAddMastheadLibraryPulldown system preferences)\n"; + print "Upgrade to $DBversion done (added OpacAddMastheadLibraryPulldown system preferences)\n"; SetVersion ($DBversion); } @@ -3421,7 +3421,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { ADD `field_separator` VARCHAR( 2 ) NOT NULL AFTER `csv_separator` , ADD `subfield_separator` VARCHAR( 2 ) NOT NULL AFTER `field_separator` }); - print "Upgrade done (added separators for csv export)\n"; + print "Upgrade to $DBversion done (added separators for csv export)\n"; SetVersion ($DBversion); } @@ -3430,27 +3430,27 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do(qq{ ALTER TABLE `export_format` ADD `encoding` VARCHAR(255) NOT NULL AFTER `subfield_separator` }); - print "Upgrade done (added encoding for csv export)\n"; + print "Upgrade to $DBversion done (added encoding for csv export)\n"; SetVersion ($DBversion); } $DBversion = '3.01.00.110'; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do('ALTER TABLE `categories` ADD COLUMN `enrolmentperioddate` DATE NULL DEFAULT NULL AFTER `enrolmentperiod`'); - print "Upgrade done (Add enrolment period date support)\n"; + print "Upgrade to $DBversion done (Add enrolment period date support)\n"; SetVersion ($DBversion); } $DBversion = '3.01.00.111'; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { - print "Upgrade done (mark DBrev for 3.2-alpha release)\n"; + print "Upgrade to $DBversion done (mark DBrev for 3.2-alpha release)\n"; SetVersion ($DBversion); } $DBversion = '3.01.00.112'; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("INSERT INTO `systempreferences` (variable,value,options,explanation,type) VALUES ('SpineLabelShowPrintOnBibDetails', '0', '', 'If turned on, a \"Print Label\" link will appear for each item on the bib details page in the staff interface.', 'YesNo');"); - print "Upgrade done ( added Show Spine Label Printer on Bib Items Details preferences )\n"; + print "Upgrade to $DBversion done ( added Show Spine Label Printer on Bib Items Details preferences )\n"; SetVersion ($DBversion); } @@ -3464,7 +3464,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do( "INSERT INTO systempreferences (variable,value,type) VALUES('OPACXSLTDetailsDisplay',?,'YesNo')", {}, $value ? 1 : 0); - print "Upgrade done (added two new syspref: OPACXSLTResultsDisplay and OPACXSLTDetailDisplay). You may have to go in Admin > System preference to tweak XSLT related syspref both in OPAC and Search tabs.\n "; + print "Upgrade to $DBversion done (added two new syspref: OPACXSLTResultsDisplay and OPACXSLTDetailDisplay). You may have to go in Admin > System preference to tweak XSLT related syspref both in OPAC and Search tabs.\n"; SetVersion ($DBversion); } @@ -3490,7 +3490,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { if (C4::Context->preference('OrderPdfFormat') eq 'pdfformat::example'){ $dbh->do("UPDATE `systempreferences` set value='pdfformat::layout2pages' WHERE variable='OrderPdfFormat'"); } - print "Upgrade done ( corrected default OrderPdfFormat value if still set wrong )\n"; + print "Upgrade to $DBversion done (corrected default OrderPdfFormat value if still set wrong )\n"; SetVersion ($DBversion); } @@ -3615,7 +3615,7 @@ $DBversion = "3.01.00.129"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("UPDATE `permissions` SET `code` = 'items_batchdel' WHERE `permissions`.`module_bit` =13 AND `permissions`.`code` = 'batchdel' LIMIT 1 ;"); $dbh->do("UPDATE `permissions` SET `code` = 'items_batchmod' WHERE `permissions`.`module_bit` =13 AND `permissions`.`code` = 'batchmod' LIMIT 1 ;"); - print "Upgrade done (Change permissions names for item batch modification / deletion)\n"; + print "Upgrade to $DBversion done (Change permissions names for item batch modification / deletion)\n"; SetVersion ($DBversion); } @@ -3623,7 +3623,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $DBversion = "3.01.00.130"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("UPDATE reserves SET expirationdate = NULL WHERE expirationdate = '0000-00-00'"); - print "Upgrade done (change reserves.expirationdate values of 0000-00-00 to NULL (bug 1532)"; + print "Upgrade to $DBversion done (change reserves.expirationdate values of 0000-00-00 to NULL (bug 1532)\n"; SetVersion ($DBversion); } @@ -3655,7 +3655,7 @@ if (C4::Context->preference('Version') < TransformToNum($DBversion)){ $DBversion = '3.01.00.134'; if (C4::Context->preference('Version') < TransformToNum($DBversion)){ $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('DisplayMultiPlaceHold','1','Display the ability to place multiple holds or not','','YesNo')"); - print "Upgrade to $DBversion done adding syspref DisplayMultiPlaceHold to control whether multiple holds can be placed from the search results page"; + print "Upgrade to $DBversion done (adding syspref DisplayMultiPlaceHold to control whether multiple holds can be placed from the search results page)\n"; SetVersion ($DBversion); } @@ -3665,7 +3665,7 @@ if (C4::Context->preference('Version') < TransformToNum($DBversion)){ INSERT INTO `letter` (module, code, name, title, content) VALUES ('reserves', 'HOLD_PRINT', 'Hold Available for Pickup (print notice)', 'Hold Available for Pickup (print notice)', '<>\r\n<>\r\n<>\r\n\r\n\r\nChange Service Requested\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n<> <>\r\n<>\r\n<> <>\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n<> <> <>\r\n\r\nYou have a hold available for pickup as of <>:\r\n\r\nTitle: <>\r\nAuthor: <>\r\nCopy: <>\r\n') "); - print "Upgrade to $DBversion done (bug 4377: added HOLD_PRINT message template)"; + print "Upgrade to $DBversion done (bug 4377: added HOLD_PRINT message template)\n"; SetVersion ($DBversion); } @@ -3674,7 +3674,7 @@ if (C4::Context->preference('Version') < TransformToNum($DBversion)){ $dbh->do(qq{ INSERT INTO permissions (module_bit, code, description) VALUES ( 9, 'edit_items', 'Edit Items');}); - print "Upgrade to $DBversion done Adding a new permission to edit items"; + print "Upgrade to $DBversion done (Adding a new permission to edit items)\n"; SetVersion ($DBversion); } @@ -3691,14 +3691,14 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { (15, 'renew_subscription', 'Renew a subscription'), (15, 'routing', 'Routing'); "); - print "Upgrade to $DBversion done (adding granular permissions for serials)"; + print "Upgrade to $DBversion done (adding granular permissions for serials)\n"; SetVersion ($DBversion); } $DBversion = "3.01.00.138"; if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $dbh->do("DELETE FROM systempreferences WHERE variable = 'GranularPermissions'"); - print "Upgrade to $DBversion done (bug 4896: removing GranularPermissions syspref; use of granular permissions is now the default)"; + print "Upgrade to $DBversion done (bug 4896: removing GranularPermissions syspref; use of granular permissions is now the default)\n"; SetVersion ($DBversion); } @@ -3720,14 +3720,14 @@ $DBversion = '3.01.00.141'; if (C4::Context->preference('Version') < TransformToNum($DBversion)){ $dbh->do(qq{DELETE FROM message_attributes WHERE message_attribute_id=3;}); $dbh->do(qq{DELETE FROM letter WHERE code='EVENT' AND title='Upcoming Library Event';}); - print "Upgrade to $DBversion done Remove upcoming events messaging option (bug 2434)"; + print "Upgrade to $DBversion done Remove upcoming events messaging option (bug 2434)\n"; SetVersion ($DBversion); } $DBversion = '3.01.00.142'; if (C4::Context->preference('Version') < TransformToNum($DBversion)){ $dbh->do(qq{DELETE FROM message_transports WHERE message_attribute_id=3;}); - print "Upgrade to $DBversion done Remove upcoming events messaging option part 2 (bug 2434)"; + print "Upgrade to $DBversion done (Remove upcoming events messaging option part 2 (bug 2434))\n"; SetVersion ($DBversion); } @@ -3735,14 +3735,14 @@ $DBversion = '3.01.00.143'; if (C4::Context->preference('Version') < TransformToNum($DBversion)){ $dbh->do(qq{CREATE INDEX auth_value_idx ON authorised_values (authorised_value)}); $dbh->do(qq{CREATE INDEX auth_val_cat_idx ON borrower_attribute_types (authorised_value_category)}); - print "Create index on authorised_values and borrower_attribute_types (bug 4139)"; + print "Upgrade to $DBversion done (Create index on authorised_values and borrower_attribute_types (bug 4139))\n"; SetVersion ($DBversion); } $DBversion = '3.01.00.144'; if (C4::Context->preference('Version') < TransformToNum($DBversion)){ $dbh->do(qq{UPDATE systempreferences SET value='normal' where value='default' and variable='IntranetBiblioDefaultView'}); - print "Update the 'default' to 'normal' for the IntranetBiblioDefaultView syspref (bug 5007)"; + print "Upgrade to $DBversion done (Update the 'default' to 'normal' for the IntranetBiblioDefaultView syspref (bug 5007))\n"; SetVersion ($DBversion); } @@ -3925,7 +3925,7 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { $DBversion = '3.03.00.008'; if (C4::Context->preference('Version') < TransformToNum($DBversion)){ $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OPACNoResultsFound','','Display this HTML when no results are found for a search in the OPAC','70|10','Textarea')"); - print "Upgrade to $DBversion done adding syspref OPACNoResultsFound to control what displays when no results are found for a search in the OPAC."; + print "Upgrade to $DBversion done (adding syspref OPACNoResultsFound to control what displays when no results are found for a search in the OPAC.)\n"; SetVersion ($DBversion); } -- 2.39.5