* change for upgrade.

This commit is contained in:
wangyidong
2016-03-23 10:59:40 +08:00
parent 63010c7886
commit 807d6af656
6 changed files with 35 additions and 2 deletions
+1 -1
View File
@@ -1 +1 @@
8.1.stable
8.1.3
+1 -1
View File
@@ -17,7 +17,7 @@ if(!function_exists('getWebRoot')){function getWebRoot(){}}
/* Basic settings. */
$config = new config();
$config->version = '8.1'; // The version of zentaopms. Don't change it.
$config->version = '8.1.3'; // The version of zentaopms. Don't change it.
$config->charset = 'UTF-8'; // The charset of zentaopms.
$config->cookieLife = time() + 2592000; // The cookie life time.
$config->timezone = 'Asia/Shanghai'; // The time zone setting, for more see http://www.php.net/manual/en/timezones.php
+28
View File
@@ -0,0 +1,28 @@
ALTER TABLE `zt_extension` DROP INDEX `name`;
ALTER TABLE `zt_extension` DROP INDEX `addedTime`;
ALTER TABLE `zt_extension` ADD INDEX `extension` (`name`, `installedTime`);
ALTER TABLE `zt_file` DROP INDEX `objectType`;
ALTER TABLE `zt_file` DROP INDEX `objectID`;
ALTER TABLE `zt_file` ADD INDEX `file` (`objectType`, `objectID`);
ALTER TABLE `zt_module` DROP INDEX `root`;
ALTER TABLE `zt_module` DROP INDEX `type`;
ALTER TABLE `zt_module` ADD INDEX `module` (`root`, `type`, `path`);
ALTER TABLE `zt_project` DROP INDEX `project`;
ALTER TABLE `zt_project` ADD INDEX `project` (`parent`, `begin`, `end`, `status`, `order`);
ALTER TABLE `zt_story` DROP INDEX `status`;
ALTER TABLE `zt_story` DROP INDEX `product`;
ALTER TABLE `zt_story` ADD INDEX `story` (`product`, `module`, `status`, `assignedTo`);
ALTER TABLE `zt_task` DROP INDEX `project`;;
ALTER TABLE `zt_task` DROP INDEX `type`;
ALTER TABLE `zt_task` DROP INDEX `status`;
ALTER TABLE `zt_task` ADD INDEX `task` (`project`, `module`, `story`, `assignedTo`);
ALTER TABLE `zt_testresult` DROP INDEX `run`;
ALTER TABLE `zt_testresult` DROP INDEX `case`;
ALTER TABLE `zt_testresult` ADD INDEX `testresult` (`case`, `version`, `run`);
ALTER TABLE `zt_todo` DROP INDEX `user`;
ALTER TABLE `zt_todo` ADD INDEX `todo` (`account`, `date`);
ALTER TABLE `zt_user` DROP INDEX `dept`;
ALTER TABLE `zt_user` ADD INDEX `user` (`dept`, `email`, `commiter`);
ALTER TABLE `zt_userquery` DROP INDEX `account`;
ALTER TABLE `zt_userquery` DROP INDEX `module`;
ALTER TABLE `zt_userquery` ADD INDEX `query` (`account`, `module`);
+1
View File
@@ -98,3 +98,4 @@ $lang->upgrade->fromVersions['7_3'] = '7.3';
$lang->upgrade->fromVersions['7_4_beta'] = '7.4.beta';
$lang->upgrade->fromVersions['8_0'] = '8.0';
$lang->upgrade->fromVersions['8_0_1'] = '8.0.1';
$lang->upgrade->fromVersions['8_1'] = '8.1';
+1
View File
@@ -98,3 +98,4 @@ $lang->upgrade->fromVersions['7_3'] = '7.3';
$lang->upgrade->fromVersions['7_4_beta'] = '7.4.beta';
$lang->upgrade->fromVersions['8_0'] = '8.0';
$lang->upgrade->fromVersions['8_0_1'] = '8.0.1';
$lang->upgrade->fromVersions['8_1'] = '8.1';
+3
View File
@@ -134,6 +134,8 @@ class upgradeModel extends model
case '8_0_1':
$this->execSQL($this->getUpgradeFile('8.0.1'));
$this->addPriv8_1();
case '8_1':
$this->execSQL($this->getUpgradeFile('8.1'));
default: if(!$this->isError()) $this->setting->updateVersion($this->config->version);
}
@@ -208,6 +210,7 @@ class upgradeModel extends model
case '7_4_beta': $confirmContent .= file_get_contents($this->getUpgradeFile('7.4.beta'));
case '8_0':
case '8_0_1': $confirmContent .= file_get_contents($this->getUpgradeFile('8.0.1'));
case '8_1': $confirmContent .= file_get_contents($this->getUpgradeFile('8.1'));
}
return str_replace('zt_', $this->config->db->prefix, $confirmContent);
}