-
Hi Everybody,
I imported my contacts from my old Android phone to UT, no problem. But, there is no way to sort contacts by name. In the present application's contacts, this sorting is done only by first name..... Is there a way to change the sorting of all contacts? Or is there a better dedicated contacts application to do it?
Thank you very much for your next answer. -
@lool_lauris I moved your topic to support as that's a better place for it.
-
@lakotaubp
I would also like it if the contacts can be sorted by last name. Is there a solution in the meantime?
In the contacts.db database, first name, last name, and organization are stored as a single string.
Will there be a revision of the address book where last name, first name and organization are written as individual fields? Would be very nice.... -
@lool_lauris currently it is not possible to sort by lastname. Only the displayName is used for sorting
see https://gitlab.com/ubports/development/core/address-book-app/-/issues/12 -
@lduboeuf i will try to do something.
-
Just gave a quick view of the issue. There is quite lot of change needed. ( section, fastscroll, sort filters, etc... )
One question though, currently, contact list used Display Label. That field is hard coded as "FirstName MiddleName LastName" and stored as this in the database, it seems not possible to change that. So the list will still have FirstName LastName whereas the sorting will be based on the LastName. Can't it be confusing ?
-
@lduboeuf I agree, it would be confusing. It would be very strange.
-
@lduboeuf said in Contacts sorting:
Just gave a quick view of the issue. There is quite lot of change needed. ( section, fastscroll, sort filters, etc... )
One question though, currently, contact list used Display Label. That field is hard coded as "FirstName MiddleName LastName" and stored as this in the database, it seems not possible to change that. So the list will still have FirstName LastName whereas the sorting will be based on the LastName. Can't it be confusing ?
We can modify the UI in address-book by using the "Name + MiddleName + Firstname" instead of the DisplayLabel, at the cost of loosing a bit of performance. The DisplayLabel is the one use thought in Messaging app, Dialer-app and when receiving a call, notification. I can't find a way to set other scheme than FirstName + LastName for now.
-
@lduboeuf would this not be better left to do after the migration to QtPIM?
-
@arubislander said in Contacts sorting:
@lduboeuf would this not be better left to do after the migration to QtPIM?
yes, that is what i think too. But i'm already working locally now with the new backend
-
@arubislander
Where can I read more about this migration? Will it make Nextcloud integration easier (giving address book sync)? Thanks. -
@arubislander
Strange, I can't find any info on what QtPIM is, let alone this migration. Even the source code repository lacks a document file. -
Should be doable more clean ( not in UI) with new backend.
But still need to be implemented.
https://github.com/sailfishos/nemo-qml-plugin-contacts provides one, we might take a look.For the source code of QtPIM, with clickable qtcreator properly configured and F1 gives some info.
Or online ( doc are in cpp files ) : https://codebrowser.dev/qt5/qtpim/
-
@lool_lauris
With Thunderbird I have now found a solution.
When creating a new contact, TB always generates the display name in the form "First Name Last Name".
This can be corrected in Settings->Advanced->Configuration.mail.addr_book.displayName.lastnamefirst -> true
The last name is set first in the display name.
This only applies to newly created contacts.mail.addr_book.lastnamefirst -> 1
The address book is sorted by last name, first name (even if you already have contacts).Since I use the "Cardbook" addon in Thunderbird, I have
Right click on the Cardbook Address Book -> Edit Address Book -> Miscellaneous -> Generate Friendly NamesThe default setting there are:
({{1}} |)({{2}} |)({{3}} |)({{4}} |)({{5}} |)({{6}} |)({ {7}}|)Here is the appropriate setting:
({{4}}, |)({{1}} |)({{2}} |)({{3}} |)({{5}} |)({{6}} |)( {{7}}|)Click on the "Apply to" button and select the desired address book.
After synchronization, all my addresses in UT are now sorted by last name and the display name is "Last Name, First Name"
For me this question is solved -
@chris_bavaria
:), how do you sync contacts with your TB ?.
But when you will edit a contact. the displayName will be changed according to FirstName + LastName -
@lduboeuf
I'm using syncevolution and I created the configuration in the terminal with "--template webdav". My address book is a vCard 3.0.
Only the "Display name" field is used in the UT address book. As far as I found out the fields "First Name" "Last Name" are not used/displayed.
After the change in Thunderbird, I synchronized my contacts with the Radicale server (starts local in background with TB) and the subsequent syncevolution sync on UT refreshed all contacts.
If desired, I can make my configuration for the address book available as a new Topic. -
@chris_bavaria
so you export your contacts to a vcard file from TB ( which is on your PC) to UT and then sync with Evolution ?I ask, because i'm working on the new contact backend, and don't know a lot about that use case.
Evolution will be disabled apparently, so i wonder how that kind of task will be done later -
@lduboeuf
I have a small, slim service running on my PC Linux, which I start as soon as I call Thunderbird:
https://radicale.org/v3.html
Please DO NOT disable Syncevolution!
Syncevolution also synchronizes all calendars.
Here's how I set up my sync:syncevolution --create-database backend=evolution-contacts database=addressbook syncevolution --configure --template webdav username=chris password=123456789 syncURL=http://192.168.188.21:5232 keyring=no target-config@radicale syncevolution --configure backend=evolution-contacts database=contacts @default addressbook #syncevolution --configure backend=contacts database=contacts @default addressbook # hier die Datenbank ID aus radicale dem Adressbuch zuordnen syncevolution --configure database=http://192.168.188.21:5232/chris/cb7491ce-2181-a6cb-b3e4-ab25d8241d35/ backend=carddav target-config@radicale addressbook syncevolution --configure --template SyncEvolution_Client Sync=None syncURL=local://@radicale username= password= radicale addressbook syncevolution --configure sync=two-way backend=evolution-contacts database=addressbook radicale addressbook syncevolution --sync slow radicale addressbook # [ERROR] remote device ID 'syncevolution-01550ce8-4e8b-4ecb-b381-6538a552feb3' in config does not match the one from the peer 'syncevolution-33965ac5-3011-40cc-931e-7327cdfae0ea' - incorrect configuration?! # Die ID in der ~/.config/syncevolution/radicale/config.ini laut Fehlermeldung austauschen ;-) # anschlieรend sollte mit <$syncevolution --sync slow radicale addressbook> die Synchronisatino in beide Richtungen erfolgen
-
@lduboeuf No, it will not be confusing; it will be a lot better than the current condition in any case.
Whoever thought sorting by first name was a good idea anyway? That is just not done, unless you are 5 years old and your only contacts are "Dad", "Gjammy" and "Mom".
-