This repository has been archived by the owner on May 16, 2023. It is now read-only.
Contact diary: Make it possible to change contact people sort order #325
Labels
contact-journal
Issues regarding the contact diary
enhancement
New feature or request
mirrored-to-jira
This item is also tracked internally in JIRA
Current implementation
The view "Edit People" sorts people alphabetically. Under the assumption that the naming convention is
{firstName}
{lastName}
, they are sorted by first name. It is not possible to change this.Suggested Enhancement
It should be possible to sort contacts by last name. Ideally, the sort order would be read from the phone's contact app settings.
Expected Benefits
This would list contacts in the same family among themselves, making it easier to see which family members you've been in contact with. Also, this would reflect the order of the phone's contact app, resulting in a more "familiar looking" list.
Notes
I know that the entire person name is stored as one string in the database. So we would need some kind of logic that explodes the string and sorts it by the last key, which should be the last name.
Of course, this wouldn't make sense if users entered contacts differently (e.g.
{lastName}
,{firstName}
). Perhaps thename
column of the database should be split intofirstName TEXT NOT NULL CHECK (LENGTH(name) <= 250)
andlastName TEXT NOT NULL CHECK (LENGTH(name) <= 250)
inv3
of theContactDiaryStoreSchema
.Edit: Having separate columns for first and last name would definitely make sense, especially when you want to support SORMAS-compatible exports, see #297 and https://github.com/hzi-braunschweig/SORMAS-Project/blob/4df8bb180c3d864c8b04ffd91f4e583739950160/sormas-api/src/main/java/de/symeda/sormas/api/contact/ContactIndexDto.java#L39-L40.
Internal Tracking ID: EXPOSUREAPP-3034
The text was updated successfully, but these errors were encountered: