onLoad: function (options) {
var that = this
that.setData({
orderNums: options.orderNum
});
wx.request({
url: 'https://apich.xiaoxiaowu.info/report/getHezuoshangPayImg',
method: 'POST',
header: {
'content-type': 'application/x-www-form-urlencoded'
},
data: {
openId: wx.getStorageSync('openId'),
orderNum: options.orderNum
},
success(res) {
console.log(res.data)
if(res.data.error == 0) {
that.setData({
src: res.data.pay_qrcode,
price:res.data.price
})
}
console.log(that.data);
}
})
},
微信小程序开发问题解答
微信小程序开发者回答:
请具体描述问题出现的流程,并提供能复现问题的简单代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)。
本文网址:http://www.91bianli.com/weixinxiaochengxu/9755.html