diff --git a/Sccp_manager.class.php b/Sccp_manager.class.php
index 4c92c9b..0cc0ee6 100644
--- a/Sccp_manager.class.php
+++ b/Sccp_manager.class.php
@@ -140,7 +140,6 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
}
$this->sccpvalues = $this->dbinterface->get_db_SccpSetting(); // Overwrite Exist
-// $this->getSccpSetingINI(false); // get from sccep.ini
$this->initializeSccpPath();
$this->initVarfromDefs();
$this->initTftpLang();
@@ -202,6 +201,10 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
$this->sccpvalues[$key] = array('keyword' => $key, 'data' => $value, 'type' => '0', 'seq' => '0');
}
}
+ // Check timezone has not been changed in FreePBX and update if has
+ if ($this->sccpvalues['ntp_timezone'] != \date_default_timezone_get()) {
+ $this->sccpvalues['ntp_timezone'] = array('keyword' => 'ntp_timezone', 'seq'=>95, 'type' => 2, 'data' => \date_default_timezone_get());
+ }
}
/*
diff --git a/conf/sccpgeneral.xml.v433 b/conf/sccpgeneral.xml.v433
index 698f0d6..2334954 100644
--- a/conf/sccpgeneral.xml.v433
+++ b/conf/sccpgeneral.xml.v433
@@ -492,7 +492,7 @@ and open the template in the editor. Base Version before all crash :-)
off
- Enabling NTP settings in device configuration.
+ Enable NTP settings in device configuration.
@@ -501,7 +501,7 @@ and open the template in the editor. Base Version before all crash :-)
pool.ntp.orgpool.ntp.org
- NTP Server name or IP
+ NTP Server name or IP addressntp_server_mode
@@ -532,7 +532,7 @@ and open the template in the editor. Base Version before all crash :-)
- Date Format: Time zone
+ System Time zone - this is set by FreePBX and can be changed in Settings : Advanced Settings
diff --git a/views/formShow.php b/views/formShow.php
index 336c182..66e9fdf 100644
--- a/views/formShow.php
+++ b/views/formShow.php
@@ -946,13 +946,6 @@ foreach ($items as $child) {
}
}
- $time_regions = array('Africa', 'America', 'Antarctica', 'Arctic', 'Asia', 'Atlantic', 'Australia', 'Europe', 'Russian', 'Indian', 'Pacific');
- $time_zone_global = DateTimeZone::listIdentifiers(DateTimeZone::ALL_WITH_BC);
- $time_zone_ru = array('Russian/Kaliningrad', 'Russian/Moscow', 'Russian/St.Peterburg', 'Russian/Samara', 'Russian/Novosibirsk', 'Russian/Ekaterinburg', 'Russian/Irkutsk', 'Russian/Yakutsk', 'Russian/Khabarovsk', 'Russian/Vladivostok', 'Russian/Sakhalin', 'Russian/Magadan', 'Russian/Kamchatka');
- $time_zone_list = array_merge($time_zone_global, $time_zone_ru);
- $optgroup = '';
- sort($time_zone_list);
-
if (empty($child->class)) {
$child->class = 'form-control';
}
@@ -963,45 +956,23 @@ foreach ($items as $child) {
}
}
- if (empty($child->value)) {
- $child->value = \date_default_timezone_get();
-// if (!empty($child->default)){
-// $child->value = $child->default;
-// }
- }
+ $child->value = \date_default_timezone_get();
echo '';
?>