Managesieve: Fix AM/PM suffix in vacation time selectors

pull/5859/head
Aleksander Machniak 7 years ago
parent f75553dee8
commit a60c81d1b1

@ -34,6 +34,7 @@ CHANGELOG Roundcube Webmail
- Add Preferences > Mailbox View > Main Options > Layout (#5829)
- Password: Fix compatibility with PHP 7+ in cpanel_webmail driver (#5820)
- Managesieve: Fix parsing dot-staffed lines in multiline text (#5838)
- Managesieve: Fix AM/PM suffix in vacation time selectors
- Fix decoding non-ascii attachment names from TNEF attachments (#5646, #5799)
- Fix uninitialized string offset in rcube_utils::bin2ascii() and make sure rcube_utils::random_bytes() result has always requested length (#5788)
- Fix bug where HTML messages with @media styles could moddify style of page body (#5811)

@ -405,8 +405,8 @@ class rcube_sieve_vacation extends rcube_sieve_engine
}
if ($date_extension) {
$time_from = new html_inputfield(array('name' => 'vacation_timefrom', 'id' => 'vacation_timefrom', 'size' => 6));
$time_to = new html_inputfield(array('name' => 'vacation_timeto', 'id' => 'vacation_timeto', 'size' => 6));
$time_from = new html_inputfield(array('name' => 'vacation_timefrom', 'id' => 'vacation_timefrom', 'size' => 7));
$time_to = new html_inputfield(array('name' => 'vacation_timeto', 'id' => 'vacation_timeto', 'size' => 7));
$time_format = $this->rc->config->get('time_format', 'H:i');
$date_value = array();

@ -929,8 +929,8 @@ function sieve_formattime(hour, minutes)
for (i=0; i<format.length; i++) {
c = format.charAt(i);
switch (c) {
case 'a': time += hour > 12 ? 'am' : 'pm'; break;
case 'A': time += hour > 12 ? 'AM' : 'PM'; break;
case 'a': time += hour >= 12 ? 'pm' : 'am'; break;
case 'A': time += hour >= 12 ? 'PM' : 'AM'; break;
case 'g':
case 'h':
h = hour == 0 ? 12 : hour > 12 ? hour - 12 : hour;

Loading…
Cancel
Save