mirror of
https://github.com/SimpleMobileTools/Simple-Contacts.git
synced 2025-02-13 18:10:46 +01:00
Added a comme when displaying surname first: "Lastname, Firstname"
This commit is contained in:
parent
4e292ae130
commit
6f83def862
@ -108,7 +108,7 @@ data class Contact(
|
||||
|
||||
fun getNameToDisplay(): String {
|
||||
val firstMiddle = "$firstName $middleName".trim()
|
||||
val firstPart = if (startWithSurname) surname else firstMiddle //TODO
|
||||
val firstPart = if (startWithSurname) if (surname.isNotEmpty()) "$surname," else "" else firstMiddle //TODO
|
||||
val lastPart = if (startWithSurname) firstMiddle else surname
|
||||
val suffixComma = if (suffix.isEmpty()) "" else ", $suffix"
|
||||
val fullName = "$prefix $firstPart $lastPart$suffixComma".trim()
|
||||
|
Loading…
x
Reference in New Issue
Block a user