cordova-plugin-contacts
cordova-plugin-contacts copied to clipboard
How to update existing contacts
Someone can help me. How to update an existing contacts ?
find
first, then make your changes and then save
on the Contact
: https://github.com/apache/cordova-plugin-contacts#methods-1
find
first, then make your changes and thensave
on theContact
: https://github.com/apache/cordova-plugin-contacts#methods-1
This is not correct. Save will only update things like name/notes etc. If you for example want to add phoneNumber, Email, Addresses etc, this apparently will not work with save() unless you clone first but than information which is not cloned can be lost.
this apparently will not work with save() unless you clone first but than information which is not cloned can be lost.
Huh what?
On iOS (havent tested Android) there is a bug that does not allow to save any information which is of the type array. The only currently working way is to clone the contacts, remove the contact and save it as a new one. But when doing this, items that are not parsed (so items that will not be cloned) will be lost during the creation of the cloned contact.
Please open an issue for that or update https://github.com/apache/cordova-plugin-contacts/issues/174 to also mention this if it is related.
We are archiving this repository following Apache Cordova's Deprecation Policy. We will not continue to work on this repository. Therefore all issues and pull requests are being closed. Thanks for your contribution.