<view class="b1" hidden="{{flag}}">
<view class="b2">
<image src='{{qrcodeUrl}}'/>
</view>
var openid=wx.getStorageSync('openid')
if(openid){
wx.request({
url: app.globalData.host+'/getQrcode',
data: {
scene: openid+'&'+that.data.goodsid
},
method:'GET',
header: {
'content-type': 'application/json'
},
success: function(res) {
console.log(res.data)
that.setData({
qrcodeUrl:res.data,
flag:false
})
}
})
可以看下控制台是否有报错信息