https://developers.weixin.qq.com/miniprogram/dev/framework/open-ability/getPhoneNumber.htmlhttps://developers.weixin.qq.com/miniprogram/dev/api-backend/open-api/phonenumber/phonenumber.getPhoneNumber.html
文档未更新?
文档如下
getPhoneNumber (e) { console.log(e.detail.code) }
实际返回如下
encryptedData: "nurZxxxxxxXqPywB1sIOVOIL49/1ePKn00cMwSPZ4nrC5JpAHur9ZgT/03Ew/F30i7c3HfVS77b4t41wVrZC3N6Jw+KNve04/Wigfs/O4q5iFNO4YOGyicUFD9nREPw7vmq/Cby+TU2dxpw=="
errMsg: "getPhoneNumber:ok"
iv: "oUHPbVhCXXXXXWAVg=="
小程序基础库版本不对,之前整理过一个文章,可以看下https://developers.weixin.qq.com/community/develop/article/doc/000aececedcf204f520eb01d056813
基础库2.21.2之前只有encryptedData和iv
基础库2.21.2后返回code,原来的encryptedData和iv继续保留