mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-22 07:53:39 +01:00
* Preferences - Add 'Firstname Lastname (Primary Group)' and 'Lastname, Firstname (Primary Group)' as account display options
This commit is contained in:
parent
00885da412
commit
f8c742cdbb
@ -325,10 +325,12 @@ class Accounts
|
|||||||
{
|
{
|
||||||
case 'firstname':
|
case 'firstname':
|
||||||
case 'firstall':
|
case 'firstall':
|
||||||
|
case 'firstgroup':
|
||||||
$order = 'account_firstname,account_lastname';
|
$order = 'account_firstname,account_lastname';
|
||||||
break;
|
break;
|
||||||
case 'lastname':
|
case 'lastname':
|
||||||
case 'lastall':
|
case 'lastall':
|
||||||
|
case 'firstgroup':
|
||||||
$order = 'account_lastname,account_firstname';
|
$order = 'account_lastname,account_firstname';
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@ -492,6 +494,14 @@ class Accounts
|
|||||||
case 'allfirst':
|
case 'allfirst':
|
||||||
$name = '['.$lid.'] ' . $firstname . ' ' . $lastname;
|
$name = '['.$lid.'] ' . $firstname . ' ' . $lastname;
|
||||||
break;
|
break;
|
||||||
|
case 'firstgroup':
|
||||||
|
$group = Accounts::id2name($lid, 'account_primary_group');
|
||||||
|
$name = $firstname . ' ' . $lastname . ($is_group ? '' : ' ('.Accounts::id2name($group).')');
|
||||||
|
break;
|
||||||
|
case 'lastgroup':
|
||||||
|
$group = Accounts::id2name($lid, 'account_primary_group');
|
||||||
|
$name = $lastname . $delimiter . $firstname . ($is_group ? '' : ' ('.Accounts::id2name($group).')');
|
||||||
|
break;
|
||||||
case 'all':
|
case 'all':
|
||||||
/* fall through */
|
/* fall through */
|
||||||
default:
|
default:
|
||||||
|
@ -86,6 +86,8 @@ class preferences_hooks
|
|||||||
'lastall' => lang('Lastname').', '.lang('Firstname').' ['.lang('username').']',
|
'lastall' => lang('Lastname').', '.lang('Firstname').' ['.lang('username').']',
|
||||||
'allfirst' => '['.lang('username').'] '.lang('Firstname').' '.lang('Lastname'),
|
'allfirst' => '['.lang('username').'] '.lang('Firstname').' '.lang('Lastname'),
|
||||||
'all' => '['.lang('username').'] '.lang('Lastname').','.lang('Firstname'),
|
'all' => '['.lang('username').'] '.lang('Lastname').','.lang('Firstname'),
|
||||||
|
'firstgroup'=> lang('Firstname').' '.lang('Lastname').' ('.lang('primary group').')',
|
||||||
|
'lastgroup' => lang('Lastname').', '.lang('Firstname').' ('.lang('primary group').')',
|
||||||
);
|
);
|
||||||
|
|
||||||
if ($hook_data['setup']) // called via setup
|
if ($hook_data['setup']) // called via setup
|
||||||
@ -132,7 +134,7 @@ class preferences_hooks
|
|||||||
'app' => 'api'
|
'app' => 'api'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$GLOBALS['egw_info']['user']['preferences']['common']['rte_toolbar'])
|
if (!$GLOBALS['egw_info']['user']['preferences']['common']['rte_toolbar'])
|
||||||
{
|
{
|
||||||
$GLOBALS['egw']->preferences->add('common', 'rte_toolbar', 'fontselect,fontsizeselect,bold,italic,forecolor,backcolor,'.
|
$GLOBALS['egw']->preferences->add('common', 'rte_toolbar', 'fontselect,fontsizeselect,bold,italic,forecolor,backcolor,'.
|
||||||
|
Loading…
Reference in New Issue
Block a user