onLoad: function (e) {
var that=this;
var sy=that.data.sy;
wx.request({
url: 'http://47.93.189.32/parkingstateapi.php',
success:function(res){
var nsy=Number(res.data[0].hourUsagerate);
that.setData({
sy:nsy
}),
console.log(nsy);
console.log(sy);
console.log(typeof nsy);
console.log(typeof sy);
}
})
},
若有帮助请帮忙点个"有用"谢谢👇👇
console.log(that.data.nsy)
console.log(that.data.sy)