From db5c2968c61cc716d78762cbe612a880d8a78b6d Mon Sep 17 00:00:00 2001 From: Alex Tselegidis Date: Sun, 29 Mar 2020 14:02:00 +0200 Subject: [PATCH] Use UTC as the default timezone value for all users. --- .../migrations/018_add_timezone_columns.php | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/application/migrations/018_add_timezone_columns.php b/application/migrations/018_add_timezone_columns.php index d02d1a39..184aeb12 100644 --- a/application/migrations/018_add_timezone_columns.php +++ b/application/migrations/018_add_timezone_columns.php @@ -11,27 +11,17 @@ * @since v1.4.0 * ---------------------------------------------------------------------------- */ -class Migration_Add_add_timezone_columns extends CI_Migration { +class Migration_Add_timezone_columns extends CI_Migration { public function up() { - $this->db->query(' - ALTER TABLE `ea_appointments` - ADD `timezone` VARCHAR(256) NULL AFTER `end_datetime`; - '); - $this->db->query(' ALTER TABLE `ea_users` - ADD `timezone` VARCHAR(256) NULL AFTER `notes`; + ADD `timezone` VARCHAR(256) DEFAULT "UTC" AFTER `notes`; '); } public function down() { - $this->db->query(' - ALTER TABLE `ea_appointments` - DROP COLUMN `timezone`; - '); - $this->db->query(' ALTER TABLE `ea_users` DROP COLUMN `timezone`;