nextcloud / nextcloud/contacts
set preferred e-mail address
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 642
- Forks
- 220
- Avg merge
- 14h 39m
- Merged PRs (30d)
- 51
Description
The database table oc_cards_properties has a field preferred, but it is unclear to me, what it is used for?
There is no setting in the frontend that can select a preferred address.
MariaDB [nextcloud]> describe oc_cards_properties;
+---------------+---------------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+---------------+---------------------+------+-----+---------+----------------+
| id | bigint(20) unsigned | NO | PRI | NULL | auto_increment |
| addressbookid | bigint(20) | NO | MUL | 0 | |
| cardid | bigint(20) unsigned | NO | MUL | 0 | |
| name | varchar(64) | YES | MUL | NULL | |
| value | varchar(255) | YES | MUL | NULL | |
| preferred | int(11) | NO | | 1 | |
+---------------+---------------------+------+-----+---------+----------------+
Most contact entries have a 0, but very few rather old entries have a 1 there. Was there a setting in earlier versions?
If there are multiple mail addresses per contact card, it would be awesome to be able to set a preferred address over the others.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the oc_cards_properties table and trace how its preferred field is read or written by the contacts app. The issue names no source files or tests, so first establish the existing behavior and agree on whether the frontend should select a preferred email; done would require that behavior to be specified and covered by validation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, mariadb
- Domain
- database, frontend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100