Improved a comment.
[timetracker.git] / dbinstall.php
index cb5f1c6..2b0d896 100755 (executable)
@@ -78,7 +78,9 @@ if ($request->isGet()) {
   }
 
   // Check if PHP version is good enough.
-  $required_version = '5.2.1'; // Something in TCPDF library does not work below this one.
+  // $required_version = '5.2.1'; // Something in TCPDF library does not work below this one.
+  $required_version = '5.4.0';    // Week view (week.php) requires 5.4 because of []-way of referencing arrays.
+                                  // This needs further investigation as we use [] elsewhere without obvious problems.
   if (version_compare(phpversion(), $required_version, '>=')) {
     echo('PHP version: '.phpversion().', good enough.<br>');
   } else {
@@ -598,7 +600,7 @@ if ($_POST) {
     setChange("ALTER TABLE tt_invoices DROP end_date");
   }
 
-  if ($_POST["convert1600to1900"]) {
+  if ($_POST["convert1600to11300"]) {
     setChange("DROP TABLE IF EXISTS tt_invoice_headers");
     setChange("ALTER TABLE tt_fav_reports ADD COLUMN `client_id` int(11) default NULL");
     setChange("ALTER TABLE tt_fav_reports ADD COLUMN `cf_1_option_id` int(11) default NULL");
@@ -748,7 +750,7 @@ if ($_POST) {
 <h2>DB Install</h2>
 <table width="80%" border="1" cellpadding="10" cellspacing="0">
   <tr>
-    <td width="80%"><b>Create database structure (v1.9.30)</b>
+    <td width="80%"><b>Create database structure (v1.13.0)</b>
     <br>(applies only to new installations, do not execute when updating)</br></td><td><input type="submit" name="crstructure" value="Create"></td>
   </tr>
 </table>
@@ -780,8 +782,8 @@ if ($_POST) {
     <td><input type="submit" name="convert1579to1600" value="Update"><br><input type="submit" name="update_clients" value="Update clients"><br><input type="submit" name="update_custom_fields" value="Update custom fields"><br><input type="submit" name="update_tracking_mode" value="Update tracking mode"></td>
   </tr>
   <tr valign="top">
-    <td>Update database structure (v1.6 to v1.9)</td>
-    <td><input type="submit" name="convert1600to1900" value="Update"><br></td>
+    <td>Update database structure (v1.6 to v1.13)</td>
+    <td><input type="submit" name="convert1600to11300" value="Update"><br></td>
   </tr>
 </table>