当前位置:首页 > 千层云服务器 > 正文

小程序如何点击tabar刷新此页面

小程序如何点击tabar刷新此页面

小程序点击tabar刷新此页面的方法:

调用onShow函数实现。

onShow:function(){

varthat=this;

wx.request({

url:app.globalData.web_url+'yourApi?open_id='+wx.getStorageSync('open_id'),

success:function(res){

that.setData({

cartList:res.data.cartList,

cartSize:res.data.cartSize,

totalAmount:res.data.totalAmount

})

}

})

},


如果您对该产品感兴趣,请填写办理(客服微信:xiaoxiongyidong)

为您推荐:

发表评论

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

在线客服