Branch 'roundcubemail-plugins-kolab-0.7' - 2 commits - plugins/calendar
Thomas Brüderli
bruederli at kolabsys.com
Wed Jun 27 22:33:08 CEST 2012
plugins/calendar/calendar.php | 8 ++++----
plugins/calendar/config.inc.php.dist | 9 +++++++++
2 files changed, 13 insertions(+), 4 deletions(-)
New commits:
commit 74214181ec5ae6df0eb4fff10d76f4a84ac78ce1
Author: Thomas Bruederli <thomas at roundcube.net>
Date: Wed Jun 27 22:31:42 2012 +0200
Fix typos + add documentation for two more config options
diff --git a/plugins/calendar/calendar.php b/plugins/calendar/calendar.php
index a830fcf..b497095 100644
--- a/plugins/calendar/calendar.php
+++ b/plugins/calendar/calendar.php
@@ -353,7 +353,7 @@ class calendar extends rcube_plugin
' — ' . $select_hours->show($this->rc->config->get('calendar_work_end', $this->defaults['calendar_work_end']), array('name' => '_work_end', 'id' => $field_id)),
);
- $field_id = 'rcmfd_coloing';
+ $field_id = 'rcmfd_coloring';
$select_colors = new html_select(array('name' => '_event_coloring', 'id' => $field_id));
$select_colors->add($this->gettext('coloringmode0'), 0);
$select_colors->add($this->gettext('coloringmode1'), 1);
@@ -462,7 +462,7 @@ class calendar extends rcube_plugin
// compose default alarm preset value
$alarm_offset = get_input_value('_alarm_offset', RCUBE_INPUT_POST);
- $default_alam = $alarm_offset[0] . intval(get_input_value('_alarm_value', RCUBE_INPUT_POST)) . $alarm_offset[1];
+ $default_alarm = $alarm_offset[0] . intval(get_input_value('_alarm_value', RCUBE_INPUT_POST)) . $alarm_offset[1];
$p['prefs'] = array(
'calendar_default_view' => get_input_value('_default_view', RCUBE_INPUT_POST),
@@ -473,7 +473,7 @@ class calendar extends rcube_plugin
'calendar_work_end' => intval(get_input_value('_work_end', RCUBE_INPUT_POST)),
'calendar_event_coloring' => intval(get_input_value('_event_coloring', RCUBE_INPUT_POST)),
'calendar_default_alarm_type' => get_input_value('_alarm_type', RCUBE_INPUT_POST),
- 'calendar_default_alarm_offset' => $default_alam,
+ 'calendar_default_alarm_offset' => $default_alarm,
'calendar_default_calendar' => get_input_value('_default_calendar', RCUBE_INPUT_POST),
'calendar_date_format' => null, // clear previously saved values
'calendar_time_format' => null,
diff --git a/plugins/calendar/config.inc.php.dist b/plugins/calendar/config.inc.php.dist
index 3c4027a..5126b2a 100644
--- a/plugins/calendar/config.inc.php.dist
+++ b/plugins/calendar/config.inc.php.dist
@@ -72,6 +72,15 @@ $rcmail_config['calendar_work_end'] = 18;
// show line at current time of the day
$rcmail_config['calendar_time_indicator'] = true;
+// default alarm settings for new events.
+// this is only a preset when a new event dialog opens
+// possible values are <empty>, DISPLAY, EMAIL
+$rcmail_config['calendar_default_alarm_type'] = '';
+
+// default alarm offset for new events.
+// use ical-style offset values like "-1H" (one hour before) or "+30M" (30 minutes after)
+$rcmail_config['calendar_default_alarm_offset'] = '-15M';
+
// how to colorize events:
// 0: according to calendar color
// 1: according to category color
commit 6879f2841c49e8559bafe5df533c55fbb8d174f7
Author: Thomas Bruederli <thomas at roundcube.net>
Date: Wed Jun 27 22:22:26 2012 +0200
Cast preset value to string in order to really mark the according option as selected (#863)
diff --git a/plugins/calendar/calendar.php b/plugins/calendar/calendar.php
index 912885a..a830fcf 100644
--- a/plugins/calendar/calendar.php
+++ b/plugins/calendar/calendar.php
@@ -332,7 +332,7 @@ class calendar extends rcube_plugin
$select->add(rcube_label('saturday'), '6');
$p['blocks']['view']['options']['first_day'] = array(
'title' => html::label($field_id, Q($this->gettext('first_day'))),
- 'content' => $select->show($this->rc->config->get('calendar_first_day', $this->defaults['calendar_first_day'])),
+ 'content' => $select->show(strval($this->rc->config->get('calendar_first_day', $this->defaults['calendar_first_day']))),
);
$time_format = $this->rc->config->get('time_format', self::to_php_date_format($this->rc->config->get('calendar_time_format', $this->defaults['calendar_time_format'])));
More information about the commits
mailing list