Merge pull request #7193 from nextcloud/bugfix/noid/invitation-email-refinements

refine invitation email
This commit is contained in:
Morris Jobke 2017-11-16 21:11:44 +01:00 committed by GitHub
commit 20868e17e8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 4 deletions

View File

@ -378,11 +378,12 @@ class IMipPlugin extends SabreIMipPlugin {
}
}
$localeStart = $l10n->l('datetime', $dtstartDt, ['width' => 'medium']);
$localeStart = $l10n->l('weekdayName', $dtstartDt, ['width' => 'abbreviated']) . ', ' .
$l10n->l('datetime', $dtstartDt, ['width' => 'medium|short']);
// always show full date with timezone if timezones are different
if ($startTimezone !== $endTimezone) {
$localeEnd = $l10n->l('datetime', $dtendDt, ['width' => 'medium']);
$localeEnd = $l10n->l('datetime', $dtendDt, ['width' => 'medium|short']);
return $localeStart . ' (' . $startTimezone . ') - ' .
$localeEnd . ' (' . $endTimezone . ')';
@ -390,9 +391,10 @@ class IMipPlugin extends SabreIMipPlugin {
// show only end time if date is the same
if ($this->isDayEqual($dtstartDt, $dtendDt)) {
$localeEnd = $l10n->l('time', $dtendDt, ['width' => 'medium']);
$localeEnd = $l10n->l('time', $dtendDt, ['width' => 'short']);
} else {
$localeEnd = $l10n->l('datetime', $dtendDt, ['width' => 'medium']);
$localeEnd = $l10n->l('weekdayName', $dtendDt, ['width' => 'abbreviated']) . ', ' .
$l10n->l('datetime', $dtendDt, ['width' => 'medium|short']);
}
return $localeStart . ' - ' . $localeEnd . ' (' . $startTimezone . ')';