X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/timetracker.git/blobdiff_plain/da93a87e5052017f10005e12c39f7d1023e013fe..bf5ddc4f34213ffe75d6d601c16148a3fe506455:/dbinstall.php diff --git a/dbinstall.php b/dbinstall.php index 58467bc1..dd360115 100755 --- a/dbinstall.php +++ b/dbinstall.php @@ -709,7 +709,7 @@ if ($_POST) { setChange("ALTER TABLE `tt_log` ADD `paid` tinyint(4) NULL default '0' AFTER `billable`"); } - if ($_POST["convert11400to11714"]) { + if ($_POST["convert11400to11715"]) { setChange("ALTER TABLE `tt_teams` DROP `address`"); setChange("ALTER TABLE `tt_fav_reports` ADD `report_spec` text default NULL AFTER `user_id`"); setChange("ALTER TABLE `tt_fav_reports` ADD `paid_status` tinyint(4) default NULL AFTER `invoice`"); @@ -720,6 +720,10 @@ if ($_POST) { setChange("ALTER TABLE `tt_teams` ADD `config` text default NULL AFTER `custom_logo`"); setChange("ALTER TABLE `tt_monthly_quotas` ADD `minutes` int(11) DEFAULT NULL"); setChange("ALTER TABLE `tt_teams` ADD `workday_minutes` smallint(4) DEFAULT '480' AFTER `workday_hours`"); + setChange("UPDATE `tt_teams` SET `workday_minutes` = 60 * `workday_hours`"); + setChange("ALTER TABLE `tt_teams` DROP `workday_hours`"); + setChange("UPDATE `tt_monthly_quotas` SET `minutes` = 60 * `quota`"); + setChange("ALTER TABLE `tt_monthly_quotas` DROP `quota`"); } if ($_POST["cleanup"]) { @@ -764,7 +768,7 @@ if ($_POST) {
| Create database structure (v1.17.14) + | Create database structure (v1.17.15)
(applies only to new installations, do not execute when updating) |