X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=dbinstall.php;h=5baff57e63da8bb8eb4cfed8a1dc4d70a346fbf8;hb=ee95ed0e72258b76ed0280f04d6846d802aefa12;hp=9e71651ef209fc257ff6edbac2ce62259b4c0249;hpb=8a0ec8135a1bb4f42c0ae89b7d97e3dfd500aba5;p=timetracker.git diff --git a/dbinstall.php b/dbinstall.php index 9e71651e..5baff57e 100644 --- a/dbinstall.php +++ b/dbinstall.php @@ -963,8 +963,11 @@ if ($_POST) { setChange("UPDATE `tt_site_config` SET param_value = '1.18.00', modified = now() where param_name = 'version_db' and param_value = '1.17.97'"); setChange("create index log_idx on tt_custom_field_log(log_id)"); setChange("UPDATE `tt_site_config` SET param_value = '1.18.05', modified = now() where param_name = 'version_db' and param_value = '1.18.00'"); - setChange("update `tt_groups` inner join `tt_site_config` sc on (sc.param_name = 'version_db' and sc.param_value = '1.18.05') set org_id = id where org_id is null"); + setChange("UPDATE `tt_groups` inner join `tt_site_config` sc on (sc.param_name = 'version_db' and sc.param_value = '1.18.05') set org_id = id where org_id is null"); setChange("UPDATE `tt_site_config` SET param_value = '1.18.06', modified = now() where param_name = 'version_db' and param_value = '1.18.05'"); + setChange("ALTER TABLE `tt_users` ADD `org_id` int(11) default NULL AFTER `group_id`"); + setChange("UPDATE `tt_users` inner join `tt_site_config` sc on (sc.param_name = 'version_db' and sc.param_value = '1.18.06') set org_id = group_id where org_id is null"); + setChange("UPDATE `tt_site_config` SET param_value = '1.18.07', modified = now() where param_name = 'version_db' and param_value = '1.18.06'"); } if ($_POST["cleanup"]) {