commit
3d1b8015c5
|
@ -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());
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -762,9 +765,9 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
|
|||
|
||||
case 'sccp_ntp_timezone':
|
||||
$tz_id = $value;
|
||||
$TZdata = $this->extconfigs->getextConfig('sccp_timezone_offset', $tz_id);
|
||||
$TZdata = $this->extconfigs->getextConfig('sccp_timezone', $tz_id);
|
||||
if (!empty($TZdata)) {
|
||||
$value = ($TZdata / 60);
|
||||
$value = $TZdata['offset']/60;
|
||||
if (!($this->sccpvalues['tzoffset']['data'] == $value)) {
|
||||
$save_settings[] = array('keyword' => 'tzoffset', 'data' => $value,
|
||||
'seq' => '98',
|
||||
|
@ -774,7 +777,6 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
|
|||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!empty($save_settings)) {
|
||||
$this->saveSccpSettings($save_settings);
|
||||
$this->sccpvalues = $this->dbinterface->get_db_SccpSetting();
|
||||
|
@ -1069,6 +1071,7 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
|
|||
}
|
||||
|
||||
$driver = $this->FreePBX->Core->getAllDriversInfo();
|
||||
// Below is always set to replace; good for Develop, but needs to be updated for release
|
||||
$sccp_driver_replace = '';
|
||||
if (empty($driver['sccp'])) {
|
||||
$sccp_driver_replace = 'yes';
|
||||
|
@ -1084,7 +1087,7 @@ class Sccp_manager extends \FreePBX_Helpers implements \BMO {
|
|||
|
||||
$this->sccpvalues['sccp_compatible'] = array('keyword' => 'sccp_compatible', 'data' => $ver_id, 'type' => '1', 'seq' => '99');
|
||||
$this->sccppath = $this->extconfigs->validate_init_path($confDir, $this->sccpvalues, $sccp_driver_replace);
|
||||
$driver = $this->FreePBX->Core->getAllDriversInfo(); // ??????
|
||||
$driver = $this->FreePBX->Core->getAllDriversInfo(); // Check that Sccp Driver has been updated by above
|
||||
|
||||
$read_config = $this->cnf_read->getConfig('sccp.conf');
|
||||
$this->sccp_conf_init['general'] = $read_config['general'];
|
||||
|
|
|
@ -492,7 +492,7 @@ and open the template in the editor. Base Version before all crash :-)
|
|||
<default>off</default>
|
||||
<button value="on">Yes</button>
|
||||
<button value="off">No</button>
|
||||
<help>Enabling NTP settings in device configuration.</help>
|
||||
<help>Enable NTP settings in device configuration.</help>
|
||||
</item>
|
||||
<item type="IE" id="2" seq="10">
|
||||
<label>NTP Server name (ip)</label>
|
||||
|
@ -501,7 +501,7 @@ and open the template in the editor. Base Version before all crash :-)
|
|||
<default>pool.ntp.org</default>
|
||||
<value>pool.ntp.org</value>
|
||||
</input>
|
||||
<help>NTP Server name or IP</help>
|
||||
<help>NTP Server name or IP address</help>
|
||||
</item>
|
||||
<item type="IS" id="3" seq="10">
|
||||
<name>ntp_server_mode</name>
|
||||
|
@ -532,7 +532,7 @@ and open the template in the editor. Base Version before all crash :-)
|
|||
<select>
|
||||
<default>UTC</default>
|
||||
</select>
|
||||
<help>Date Format: Time zone</help>
|
||||
<help>System Time zone - this is set by FreePBX and can be changed in Settings : Advanced Settings</help>
|
||||
</item>
|
||||
</page_group>
|
||||
|
||||
|
|
|
@ -14,15 +14,13 @@ class extconfigs
|
|||
$this->paren_class = $parent_class;
|
||||
}
|
||||
|
||||
public function info()
|
||||
{
|
||||
$Ver = '13.0.3';
|
||||
public function info() {
|
||||
$Ver = '13.1.1';
|
||||
return array('Version' => $Ver,
|
||||
'about' => 'Default Setings and Enums ver: ' . $Ver);
|
||||
}
|
||||
|
||||
public function getextConfig($id = '', $index = '')
|
||||
{
|
||||
public function getextConfig($id = '', $index = '') {
|
||||
switch ($id) {
|
||||
case 'keyset':
|
||||
$result = $this->keysetdefault;
|
||||
|
@ -33,64 +31,47 @@ class extconfigs
|
|||
case 'sccpDefaults':
|
||||
$result = $this->sccpDefaults;
|
||||
break;
|
||||
case 'sccp_timezone_offset': // Sccp manafer: 1400 (+ Id) :2007 (+ Id)
|
||||
if (empty($index)) {
|
||||
return 0;
|
||||
}
|
||||
if (array_key_exists($index, $this->cisco_timezone)) {
|
||||
$tmp_time = $this->get_cisco_time_zone($index);
|
||||
return $tmp_time['offset'];
|
||||
}
|
||||
|
||||
$tmp_dt = new \DateTime(null, new \DateTimeZone($index));
|
||||
$tmp_ofset = $tmp_dt->getOffset();
|
||||
return $tmp_ofset / 60;
|
||||
|
||||
break;
|
||||
case 'sccp_timezone': // Sccp manafer: 1400 (+ Id) :2007 (+ Id)
|
||||
case 'sccp_timezone': // Sccp manager: 1303; server_info: 122
|
||||
$result = array();
|
||||
|
||||
if (empty($index)) {
|
||||
return array('offset' => '00', 'daylight' => '', 'cisco_code' => 'Greenwich');
|
||||
}
|
||||
if (array_key_exists($index, $this->cisco_timezone)) {
|
||||
return $this->get_cisco_time_zone($index);
|
||||
} else {
|
||||
$timezone_abbreviations = \DateTimeZone::listAbbreviations();
|
||||
|
||||
$tz_tmp = array();
|
||||
foreach ($timezone_abbreviations as $subArray) {
|
||||
$tf_idt = array_search($index, array_column($subArray, 'timezone_id'));
|
||||
if (!empty($tf_idt)) {
|
||||
$tz_tmp[] = $subArray[$tf_idt];
|
||||
}
|
||||
}
|
||||
if (empty($tz_tmp)) {
|
||||
return array('offset' => '00', 'daylight' => '', 'cisco_code' => 'Greenwich');
|
||||
return array('offset' => '00', 'daylight' => '', 'cisco_code' => 'Greenwich Standard Time');
|
||||
}
|
||||
|
||||
if (count($tz_tmp)==1) {
|
||||
$time_set = $tz_tmp[0];
|
||||
} else {
|
||||
$tmp_dt = new \DateTime(null, new \DateTimeZone($index));
|
||||
$tmp_ofset = $tmp_dt->getOffset();
|
||||
foreach ($tz_tmp as $subArray) {
|
||||
if ($subArray['offset'] == $tmp_ofset) {
|
||||
$time_set = $subArray;
|
||||
//See if DST is used in this TZ. Test if DST setting is different at
|
||||
//various future intervals. If dst changes, this TZ uses dst
|
||||
$usesDaylight = false;
|
||||
$haveDstNow = date('I');
|
||||
$futureDateArray = array(2,4,6,8);
|
||||
foreach ($futureDateArray as $numMonths) {
|
||||
$futureDate = (new \DateTime(null,new \DateTimeZone($index)))->modify("+{$numMonths} months");
|
||||
if ($futureDate->format('I') != $haveDstNow) {
|
||||
$usesDaylight = true;
|
||||
break;
|
||||
};
|
||||
}
|
||||
$thisTzOffset = (new \DateTime(null, new \DateTimeZone($index)))->getOffset();
|
||||
|
||||
// Now look for a match in cisco_tz_array based on offset and DST
|
||||
// First correct offset if we have DST now as cisco offsets are
|
||||
// based on non dst offsets
|
||||
$tmpOffset = $thisTzOffset / 60;
|
||||
if ($haveDstNow) {
|
||||
$tmpOffset = $tmpOffset - 60;
|
||||
}
|
||||
}
|
||||
$tmp_ofset = $time_set['offset'] / 60;
|
||||
$tmp_dli = (empty($time_set['dst']) ? '' : 'Daylight' );
|
||||
foreach ($this->cisco_timezone as $key => $value) {
|
||||
if (($value['offset'] == $tmp_ofset) and ( $value['daylight'] == $tmp_dli )) {
|
||||
return $this->get_cisco_time_zone($key);
|
||||
if (($value['offset'] == $tmpOffset) and ( $value['daylight'] == $usesDaylight )) {
|
||||
// This code may not be the one typically used, but it has the correct values.
|
||||
$cisco_code = $key . ' Standard' . (($usesDaylight) ? '/Daylight' : '') . ' Time';
|
||||
|
||||
$this->sccpvalues['tzoffset']['data'] = $tmpOffset;
|
||||
|
||||
return array('offset' => $tmpOffset, 'daylight' => ($usesDaylight) ? 'Daylight' : '', 'cisco_code' => $cisco_code);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return array('offset' => '00', 'daylight' => '', 'cisco_code' => 'Greenwich');
|
||||
}
|
||||
return array('offset' => '00', 'daylight' => '', 'cisco_code' => 'Greenwich Standard Time');
|
||||
|
||||
break;
|
||||
default:
|
||||
return array('noId');
|
||||
|
@ -109,16 +90,8 @@ class extconfigs
|
|||
|
||||
private function get_cisco_time_zone($tzc)
|
||||
{
|
||||
|
||||
if ((empty($tzc)) or (!array_key_exists($tzc, $this->cisco_timezone))) {
|
||||
// return array('offset' => '00', 'daylight' => '', 'cisco_code' => 'Greenwich');
|
||||
return array();
|
||||
}
|
||||
$tzdata = $this->cisco_timezone[$tzc];
|
||||
$cisco_code = $tzc . ' Standard' . ((empty($tzdata['daylight'])) ? '' : '/' . $tzdata['daylight']) . ' Time';
|
||||
if (isset($tzdata['cisco_code'])) {
|
||||
$cisco_code = (empty($tzdata['cisco_code'])) ? $cisco_code : $tzdata['cisco_code'];
|
||||
}
|
||||
$cisco_code = $tzc . ' Standard' . (($tzdata['daylight']) ? '/Daylight' : '') . ' Time';
|
||||
return array('offset' => $tzdata['offset'], 'daylight' => $tzdata['daylight'], 'cisco_code' => $cisco_code);
|
||||
}
|
||||
|
||||
|
@ -194,74 +167,53 @@ class extconfigs
|
|||
'zh_TW' => array('code' => 'zh', 'language' => 'Chinese', 'locale' => 'Chinese_Taiwan', 'codepage' => 'ISO8859-1')
|
||||
);
|
||||
private $cisco_timezone = array(
|
||||
'Dateline' => array('offset' => '-720', 'daylight' => ''),
|
||||
'Samoa' => array('offset' => '-660', 'daylight' => ''),
|
||||
'Hawaiian' => array('offset' => '-600', 'daylight' => ''),
|
||||
'Alaskan' => array('offset' => '-540', 'daylight' => 'Daylight'),
|
||||
'Pacific' => array('offset' => '-480', 'daylight' => 'Daylight'),
|
||||
'Mountain' => array('offset' => '-420', 'daylight' => 'Daylight'),
|
||||
'US Mountain' => array('offset' => '-420', 'daylight' => ''),
|
||||
'Central' => array('offset' => '-360', 'daylight' => 'Daylight'),
|
||||
'Mexico' => array('offset' => '-360', 'daylight' => 'Daylight'),
|
||||
'Canada Central' => array('offset' => '-360', 'daylight' => ''),
|
||||
'SA Pacific' => array('offset' => '-300', 'daylight' => ''),
|
||||
'Eastern' => array('offset' => '-300', 'daylight' => 'Daylight'),
|
||||
'US Eastern' => array('offset' => '-300', 'daylight' => ''),
|
||||
'Atlantic' => array('offset' => '-240', 'daylight' => 'Daylight'),
|
||||
'SA Western' => array('offset' => '-240', 'daylight' => ''),
|
||||
'Pacific SA' => array('offset' => '-240', 'daylight' => ''),
|
||||
'Newfoundland' => array('offset' => '-210', 'daylight' => 'Daylight'),
|
||||
'E. South America' => array('offset' => '-180', 'daylight' => 'Daylight'),
|
||||
'SA Eastern' => array('offset' => '-180', 'daylight' => ''),
|
||||
'Pacific SA' => array('offset' => '-180', 'daylight' => 'Daylight'),
|
||||
'Mid-Atlantic' => array('offset' => '-120', 'daylight' => 'Daylight'),
|
||||
'Azores' => array('offset' => '-060', 'daylight' => 'Daylight'),
|
||||
'GMT' => array('offset' => '00', 'daylight' => 'Daylight'),
|
||||
'Greenwich' => array('offset' => '00', 'daylight' => ''),
|
||||
'W. Europe' => array('offset' => '60', 'daylight' => 'Daylight'),
|
||||
'GTB' => array('offset' => '60', 'daylight' => 'Daylight'),
|
||||
'Egypt' => array('offset' => '60', 'daylight' => 'Daylight'),
|
||||
'E. Europe' => array('offset' => '60', 'daylight' => 'Daylight'),
|
||||
'Romance' => array('offset' => '120', 'daylight' => 'Daylight'),
|
||||
'Central Europe' => array('offset' => '120', 'daylight' => 'Daylight'),
|
||||
'South Africa' => array('offset' => '120', 'daylight' => ''),
|
||||
'Jerusalem' => array('offset' => '120', 'daylight' => 'Daylight'),
|
||||
'Saudi Arabia' => array('offset' => '180', 'daylight' => ''),
|
||||
/* Russian Regions */
|
||||
'Russian/Kaliningrad' => array('offset' => '120', 'daylight' => '', 'cisco_code' => 'South Africa Standard Time'),
|
||||
'Russian/Moscow' => array('offset' => '180', 'daylight' => '', 'cisco_code' => 'Russian Standard Time'),
|
||||
'Russian/St.Peterburg' => array('offset' => '180', 'daylight' => '', 'cisco_code' => 'Russian Standard Time'),
|
||||
'Russian/Samara' => array('offset' => '240', 'daylight' => '', 'cisco_code' => 'Arabian Standard Time'),
|
||||
'Russian/Novosibirsk' => array('offset' => '300', 'daylight' => '', 'cisco_code' => 'Ekaterinburg Standard Time'),
|
||||
'Russian/Ekaterinburg' => array('offset' => '300', 'daylight' => '', 'cisco_code' => 'Ekaterinburg Standard Time'),
|
||||
'Russian/Irkutsk' => array('offset' => '480', 'daylight' => '', 'cisco_code' => 'China Standard Time'),
|
||||
'Russian/Yakutsk' => array('offset' => '540', 'daylight' => '', 'cisco_code' => 'Tokyo Standard Time'),
|
||||
'Russian/Khabarovsk' => array('offset' => '600', 'daylight' => '', 'cisco_code' => 'West Pacific Standard Time'),
|
||||
'Russian/Vladivostok' => array('offset' => '600', 'daylight' => '', 'cisco_code' => 'West Pacific Standard Time'),
|
||||
'Russian/Sakhalin' => array('offset' => '660', 'daylight' => '', 'cisco_code' => 'Central Pacific Standard Time'),
|
||||
'Russian/Magadan' => array('offset' => '660', 'daylight' => '', 'cisco_code' => 'Central Pacific Standard Time'),
|
||||
'Russian/Kamchatka' => array('offset' => '720', 'daylight' => '', 'cisco_code' => 'Fiji Standard Time'),
|
||||
/* EnD - Russian Regions */
|
||||
'Iran' => array('offset' => '210', 'daylight' => 'Daylight'),
|
||||
'Caucasus' => array('offset' => '240', 'daylight' => 'Daylight'),
|
||||
'Arabian' => array('offset' => '240', 'daylight' => ''),
|
||||
'Afghanistan' => array('offset' => '270', 'daylight' => ''),
|
||||
'West Asia' => array('offset' => '300', 'daylight' => ''),
|
||||
'India' => array('offset' => '330', 'daylight' => ''),
|
||||
'Central Asia' => array('offset' => '360', 'daylight' => ''),
|
||||
'SE Asia' => array('offset' => '420', 'daylight' => ''),
|
||||
'China' => array('offset' => '480', 'daylight' => ''),
|
||||
'Taipei' => array('offset' => '480', 'daylight' => ''),
|
||||
'Tokyo' => array('offset' => '540', 'daylight' => ''),
|
||||
'Cen. Australia' => array('offset' => '570', 'daylight' => 'Daylight'),
|
||||
'AUS Central' => array('offset' => '570', 'daylight' => ''),
|
||||
'E. Australia' => array('offset' => '600', 'daylight' => ''),
|
||||
'AUS Eastern' => array('offset' => '600', 'daylight' => 'Daylight'),
|
||||
'West Pacific' => array('offset' => '600', 'daylight' => ''),
|
||||
'Tasmania' => array('offset' => '600', 'daylight' => 'Daylight'),
|
||||
'Central Pacific' => array('offset' => '660', 'daylight' => ''),
|
||||
'Fiji' => array('offset' => '720', 'daylight' => ''),
|
||||
'New Zealand' => array('offset' => '720', 'daylight' => 'Daylight')
|
||||
'Dateline' => array('offset' => '-720', 'daylight' => false),
|
||||
'Samoa' => array('offset' => '-660', 'daylight' => false),
|
||||
'Hawaiian' => array('offset' => '-600', 'daylight' => false),
|
||||
'Alaskan' => array('offset' => '-540', 'daylight' => true),
|
||||
'Pacific' => array('offset' => '-480', 'daylight' => true),
|
||||
'Mountain' => array('offset' => '-420', 'daylight' => true),
|
||||
'US Mountain' => array('offset' => '-420', 'daylight' => false),
|
||||
'Central' => array('offset' => '-360', 'daylight' => true),
|
||||
'Mexico' => array('offset' => '-360', 'daylight' => true),
|
||||
'Canada Central' => array('offset' => '-360', 'daylight' => false),
|
||||
'SA Pacific' => array('offset' => '-300', 'daylight' => false),
|
||||
'Eastern' => array('offset' => '-300', 'daylight' => true),
|
||||
'US Eastern' => array('offset' => '-300', 'daylight' => false),
|
||||
'Atlantic' => array('offset' => '-240', 'daylight' => true),
|
||||
'SA Western' => array('offset' => '-240', 'daylight' => false),
|
||||
'Pacific SA' => array('offset' => '-240', 'daylight' => false),
|
||||
'Newfoundland' => array('offset' => '-210', 'daylight' => true),
|
||||
'E. South America' => array('offset' => '-180', 'daylight' => true),
|
||||
'SA Eastern' => array('offset' => '-180', 'daylight' => false),
|
||||
'Pacific SA' => array('offset' => '-180', 'daylight' => true),
|
||||
'Mid-Atlantic' => array('offset' => '-120', 'daylight' => true),
|
||||
'Azores' => array('offset' => '-060', 'daylight' => true),
|
||||
'GMT' => array('offset' => '00', 'daylight' => true),
|
||||
'Greenwich' => array('offset' => '00', 'daylight' => false),
|
||||
'W. Europe' => array('offset' => '60', 'daylight' => true),
|
||||
'Central Europe' => array('offset' => '120', 'daylight' => true),
|
||||
'South Africa' => array('offset' => '120', 'daylight' => false),
|
||||
'Saudi Arabia' => array('offset' => '180', 'daylight' => false),
|
||||
'Iran' => array('offset' => '210', 'daylight' => true),
|
||||
'Caucasus' => array('offset' => '240', 'daylight' => true),
|
||||
'Arabian' => array('offset' => '240', 'daylight' => false),
|
||||
'Afghanistan' => array('offset' => '270', 'daylight' => false),
|
||||
'West Asia' => array('offset' => '300', 'daylight' => false),
|
||||
'India' => array('offset' => '330', 'daylight' => false),
|
||||
'Central Asia' => array('offset' => '360', 'daylight' => false),
|
||||
'SE Asia' => array('offset' => '420', 'daylight' => false),
|
||||
'China' => array('offset' => '480', 'daylight' => false),
|
||||
'Tokyo' => array('offset' => '540', 'daylight' => false),
|
||||
'Cen. Australia' => array('offset' => '570', 'daylight' => true),
|
||||
'AUS Central' => array('offset' => '570', 'daylight' => false),
|
||||
'E. Australia' => array('offset' => '600', 'daylight' => false),
|
||||
'AUS Eastern' => array('offset' => '600', 'daylight' => true),
|
||||
'West Pacific' => array('offset' => '600', 'daylight' => false),
|
||||
'Tasmania' => array('offset' => '600', 'daylight' => true),
|
||||
'Central Pacific' => array('offset' => '660', 'daylight' => false),
|
||||
'Fiji' => array('offset' => '720', 'daylight' => false),
|
||||
'New Zealand' => array('offset' => '720', 'daylight' => true)
|
||||
);
|
||||
|
||||
public function validate_init_path($confDir = '', $db_vars, $sccp_driver_replace = '')
|
||||
|
@ -394,7 +346,6 @@ class extconfigs
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
$dst = $_SERVER['DOCUMENT_ROOT'] . '/admin/modules/core/functions.inc/drivers/Sccp.class.php';
|
||||
if (!file_exists($dst) || $sccp_driver_replace == 'yes') {
|
||||
$src_path = $_SERVER['DOCUMENT_ROOT'] . '/admin/modules/sccp_manager/conf/' . basename($dst) . '.v' . $db_vars['sccp_compatible']['data'];
|
||||
|
|
|
@ -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;
|
||||
// }
|
||||
}
|
||||
|
||||
echo '<!-- Begin '.$child->label.' -->';
|
||||
?>
|
||||
<div class="element-container">
|
||||
<div class="row"> <div class="form-group">
|
||||
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<div class="col-md-3">
|
||||
<label class="control-label" for="<?php echo $res_id; ?>"><?php echo _($child->label);?></label>
|
||||
<i class="fa fa-question-circle fpbx-help-icon" data-for="<?php echo $res_id; ?>"></i>
|
||||
</div>
|
||||
<div class="col-md-9"> <!-- <div class = "lnet form-group form-inline" data-nextid=1> --> <?php
|
||||
echo '<select name="'.$res_id.'" class="'. $child->class . '" id="' . $res_id . '">';
|
||||
foreach ($time_zone_list as $opt_key) {
|
||||
$z = explode('/', $opt_key, 2);
|
||||
if (count($z) != 2 || !in_array($z[0], $time_regions)) {
|
||||
continue;
|
||||
}
|
||||
if ($optgroup != $z[0]) {
|
||||
if ($optgroup !== '') {
|
||||
echo '</optgroup>';
|
||||
}
|
||||
$optgroup = $z[0];
|
||||
echo '<optgroup label="' . htmlentities($z[0]) . '">';
|
||||
}
|
||||
echo '<option value="' . htmlentities($opt_key) . '" label="' . htmlentities(str_replace('_', ' ', $z[1])) . '"' . ($opt_key == $child->value ? ' selected="selected" >' : '>'). htmlentities(str_replace('_', ' ', $opt_key)) . '</option>';
|
||||
}
|
||||
if ($optgroup !== '') {
|
||||
echo '</optgroup>';
|
||||
}
|
||||
|
||||
?> </select>
|
||||
<!-- </div> --> </div>
|
||||
</div></div>
|
||||
<div class="col-md-9"> <?php
|
||||
echo $child->value;
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row"><div class="col-md-12">
|
||||
<span id="<?php echo $res_id;?>-help" class="help-block fpbx-help-block"><?php echo _($child->help);?></span>
|
||||
</div></div>
|
||||
|
|
|
@ -117,7 +117,7 @@ if ($mysql_info['Value'] <= '2000') {
|
|||
}
|
||||
|
||||
|
||||
// Check Time Zone comatable
|
||||
// Check Time Zone compatibility
|
||||
$conf_tz = $this->sccpvalues['ntp_timezone']['data'];
|
||||
$cisco_tz = $this->extconfigs->getextConfig('sccp_timezone', $conf_tz);
|
||||
if ($cisco_tz['offset'] == 0) {
|
||||
|
|
Loading…
Reference in a new issue