- Fix: German translation error in Admin -> Users -> Groups -> Members -> Add Member UserPicker.

- Fix: German translation "Notify Users" placeholder too long.
This commit is contained in:
buddh4 2017-03-01 14:29:05 +01:00
parent 2101c2c1c0
commit 3b4be55f86
3 changed files with 11 additions and 5 deletions

View File

@ -1,6 +1,6 @@
<?php
return array (
'Add a member to notify' => 'Mitglied zur Benachrichtigung hinzufügen',
'Add a member to notify' => 'Benachrichtige Benutzer',
'Make private' => 'Ändern in geschlossene Gruppe',
'Make public' => 'Ändern in öffentliche Gruppe',
'Notify members' => 'Informiere Mitglieder',

View File

@ -1,8 +1,8 @@
<?php
return array (
'Add more...' => 'Benutzer hinzufügen',
'No users found for the given query.' => 'Keine Benutzer gefunden.',
'Select {n,plural,=1{user} other{users}}' => 'Wähle {n,plural,=1{user} andere {users}}
',
'Select {n,plural,=1{user} other{users}}' => 'Wähle Benutzer',
'This field only allows a maximum of {n,plural,=1{# user} other{# users}}.' => 'Dieses Feld erlaubt nur ein Maximum von {n,plural,=1{# user} anderen {# users}}.
',
);

View File

@ -57,8 +57,14 @@ class UserPickerField extends BasePickerField
{
$result = parent::getData();
$allowMultiple = $this->maxSelection !== 1;
$result['placeholder'] = Yii::t('UserModule.widgets_UserPickerField', 'Select {n,plural,=1{user} other{users}}', ['n' => ($allowMultiple) ? 2 : 1]);
$result['placeholder-more'] = Yii::t('UserModule.widgets_SpacePickerField', 'Add user');
$result['placeholder'] = ($this->placeholder != null) ? $this->placeholder : Yii::t('UserModule.widgets_UserPickerField', 'Select {n,plural,=1{user} other{users}}', ['n' => ($allowMultiple) ? 2 : 1]);
if($this->placeholder && !$this->placeholderMore) {
$result['placeholder-more'] = $this->placeholder;
} else {
$result['placeholder-more'] = ($this->placeholderMore) ? $this->placeholderMore : Yii::t('UserModule.widgets_UserPickerField', 'Add more...');
}
$result['no-result'] = Yii::t('UserModule.widgets_UserPickerField', 'No users found for the given query.');
if ($this->maxSelection) {