[Owncloud] [Contacts] Hack for sorting by last name

Andreas Borutta borumat at gmx.de
Wed Aug 7 11:16:22 UTC 2013


Thomas Tanghus schrieb:

[/apps/contacts/js/contacts.js]
[Surname, Forename]

> Contact.prototype.getDisplayName = function() {
>     return this.getPreferredValue('N', [this.getPreferredValue('FN',[])]).slice(0, 2).join(', ');
> };

Is there a way not to display the comma, when there's only a surname
or only a forename?

Example:

Source:

Forename: Andreas	
Surname: 

Forename: 
Surname: Tanghus

Wished View:

Andreas
Tanghus

Actual View:

, Andreas
Tanghus,


Andreas
-- 
http://borumat.de
http://fahrradzukunft.de




More information about the Owncloud mailing list