summaryrefslogtreecommitdiff
path: root/plugins/libcalendaring
diff options
context:
space:
mode:
authorThomas Bruederli <bruederli@kolabsys.com>2015-02-02 12:12:56 (GMT)
committerThomas Bruederli <bruederli@kolabsys.com>2015-02-02 12:12:56 (GMT)
commitb4bcf723e5fd1dbddd06f4861aa4ba43ec2cfc5b (patch)
treebe4e89065623d23dc783e58faf837b2fafe0342c /plugins/libcalendaring
parent86d464b6deec19cc9ed7c4fa97884a869a85fee7 (diff)
downloadroundcubemail-plugins-kolab-b4bcf723e5fd1dbddd06f4861aa4ba43ec2cfc5b.tar.gz
Display recurrence information from iTip invitations (#4446)
Diffstat (limited to 'plugins/libcalendaring')
-rw-r--r--plugins/libcalendaring/lib/libcalendaring_itip.php23
-rw-r--r--plugins/libcalendaring/localization/en_US.inc1
2 files changed, 15 insertions, 9 deletions
diff --git a/plugins/libcalendaring/lib/libcalendaring_itip.php b/plugins/libcalendaring/lib/libcalendaring_itip.php
index 0685337..3eead6f 100644
--- a/plugins/libcalendaring/lib/libcalendaring_itip.php
+++ b/plugins/libcalendaring/lib/libcalendaring_itip.php
@@ -125,7 +125,8 @@ class libcalendaring_itip
'name' => $bodytext,
'vars' => array(
'title' => $event['title'],
- 'date' => $this->lib->event_date_text($event, true),
+ 'date' => $this->lib->event_date_text($event, true) .
+ (empty($event['recurrence']) ? '' : sprintf("\n%s: %s", $this->gettext('recurring'), $this->lib->recurrence_text($event['recurrence']))),
'attendees' => join(",\n ", $attendees_list),
'sender' => $this->sender['name'],
'organizer' => $this->sender['name'],
@@ -697,27 +698,31 @@ class libcalendaring_itip
$table->add('ititle', $title);
$table->add('title', Q($event['title']));
if ($event['start'] && $event['end']) {
- $table->add('label', $this->plugin->gettext('date'), $this->domain);
+ $table->add('label', $this->gettext('date'));
$table->add('date', Q($this->lib->event_date_text($event)));
}
else if ($event['due'] && $event['_type'] == 'task') {
- $table->add('label', $this->plugin->gettext('date'), $this->domain);
+ $table->add('label', $this->gettext('date'));
$table->add('date', Q($this->lib->event_date_text($event)));
}
+ if (!empty($event['recurrence'])) {
+ $table->add('label', $this->gettext('recurring'));
+ $table->add('recurrence', $this->lib->recurrence_text($event['recurrence']));
+ }
if ($event['location']) {
- $table->add('label', $this->plugin->gettext('location'), $this->domain);
+ $table->add('label', $this->gettext('location'));
$table->add('location', Q($event['location']));
}
if ($event['sensitivity'] && $event['sensitivity'] != 'public') {
- $table->add('label', $this->plugin->gettext('sensitivity'), $this->domain);
- $table->add('sensitivity', ucfirst($this->plugin->gettext($event['sensitivity'], $this->domain)) . '!');
+ $table->add('label', $this->gettext('sensitivity'));
+ $table->add('sensitivity', ucfirst($this->gettext($event['sensitivity'])) . '!');
}
if ($event['status'] == 'COMPLETED' || $event['status'] == 'CANCELLED') {
- $table->add('label', $this->plugin->gettext('status'), $this->domain);
- $table->add('status', $this->plugin->gettext('status-' . strtolower($event['status']), $this->domain));
+ $table->add('label', $this->gettext('status'));
+ $table->add('status', $this->gettext('status-' . strtolower($event['status'])));
}
if ($event['comment']) {
- $table->add('label', $this->plugin->gettext('comment'), $this->domain);
+ $table->add('label', $this->gettext('comment'));
$table->add('location', Q($event['comment']));
}
diff --git a/plugins/libcalendaring/localization/en_US.inc b/plugins/libcalendaring/localization/en_US.inc
index 2542c47..3e49838 100644
--- a/plugins/libcalendaring/localization/en_US.inc
+++ b/plugins/libcalendaring/localization/en_US.inc
@@ -46,6 +46,7 @@ $labels['repeatinweek'] = 'Repeat in a week';
$labels['showmore'] = 'Show more...';
// recurrence related labels
+$labels['recurring'] = 'Repeats';
$labels['frequency'] = 'Repeat';
$labels['never'] = 'never';
$labels['daily'] = 'daily';