Get the App
SLTechnology News&Howtos  ›  Development  › 

How to adjust WeChat Mini Programs's API receiving address

Shulou Source: shulou.com Published: 2022-06-01 07:09:27 10月03日 Update

This article mainly explains "how to adjust the receiving address of WeChat Mini Programs API". Interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Next let the editor to take you to learn "WeChat Mini Programs API receiving address how to adjust" it!

Wx.chooseAddress (OBJECT)

The basic library version 1.1.0 is supported, and the lower version needs to be compatible.

Set up the native interface for editing the shipping address of the user, and return to the address selected by the user after editing.

OBJECT parameter description:

Parameter type is required return successFunction No return the shipping address information selected by the user failFunction No API call failed callback function completeFunction No API call the finished callback function (both successful and failed calls will be executed)

Success return parameter description:

Parameter type description errMsgString call result userNameString consignee name postalCodeString zip code provinceNameString national standard receiving address first-level address cityNameString national standard receiving address second-level address countyNameString national standard receiving address third-level address detailInfoString detailed receiving address information nationalCodeString receiving address country code telNumberString consignee mobile number

Sample code:

Wx.chooseAddress ({success: function (res) {console.log (res.userName) console.log (res.postalCode) console.log (res.provinceName) console.log (res.cityName) console.log (res.countyName) console.log (res.detailInfo) console.log (res.nationalCode) console.log (res.telNumber)}) Bug & Tip

The tip:wx.chooseAddress API requires user authorization. Please be compatible with the scenario in which the user refuses authorization.

At this point, I believe you have a deeper understanding of "how to adjust the receiving address of WeChat Mini Programs API". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!

Tags: Address user parameter program GB interface information content function consignee version type learning selection practical deeper success code interest number Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MariaDB Shulou Tech Info vpn Xiaomi NVidia