const _my = require("../../__antmove/api/index.js")(my); const wx = _my; const util = require("../func/request"); //检测是否获取手机号 const isGetPhone = e => { if (e.detail.errMsg == "getPhoneNumber:ok") { return true; } else { return false; } }; //获取手机号 const getPhone = e => { return new Promise((reslove, reject) => { wx.showLoading({ title: "获取中...", mask: true }); util.request_wxrlxf({ url: "/api/next/alipay/decrypt", data: e, method: "post", type: "application/json" }).then(suc => { wx.hideLoading(); console.info('getPhone-->', suc) reslove(suc.mobile); }); }); }; module.exports = getPhone;