Mall WeChat Mini Programs authorized user information and mobile phone number of the correct process is what?

such as the title.
should I write two pages to click to get or write a page to authorize user information and then directly authorize to obtain the mobile phone number?

Sep.22,2021

generally, as soon as you enter Mini Program, you will jump out of the authorization request dialog box. If the user refuses authorization, you will jump to the corresponding page. But I think if you only need to get user information in some business, you can first determine whether there is user information when users operate these businesses that must authorize user information. If not, pop up the authorization request to obtain user information.


generally place a button to get it, and if the user is not authorized, jump to the page written by the user and let the user fill in the mobile phone number manually.

//wxml
<button open-type="getPhoneNumber" bindgetphonenumber='handler'></button>

//js
handler(e){
    let {encryptedData, iv} = e.detail;
    if(encryptedData && iv) {
        //
    } else {
        //
    }
}

official document: get the mobile number

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1ea9455-5cd5d.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1ea9455-5cd5d.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?