==================================
function sleep(d){
for(var t = Date.now();Date.now() - t <= d;);
}
异步,后发先至,undefined,阻塞一下,sleep
==================================
1Cannot create property 'yh' on boolean
不能给 “false”创建属性
2左手边不能赋值
排错心得
发现报错信息“Cannot create property 'yh' on boolean”,报错信息的原因是数据为空,为空的原因是请求返回空数据,返回空数据的原因是goods_id设置不正确,接下来追查goods_id是从哪里来的,(找到携带该参数的跳转链接,修改之)
option dataset navigate to
join_group: function(o) {
var t = this.data;
//原来的值为t.id
//应当更改为 t.goods_info.goods_id
//console.log(t.goods_info.goods_id);return false;
wx.navigateTo({
url: "qgform?store_id=" + t.options.store_id + "&goods_id=" + t.goods_info.goods_id + "&type=2&group_id=" + t.id + "&end_time=" + t.options.time + "&xf_time=" + t.options.xf_time
});
},
base64 图片 加解密
urlencode加解密
unicode 加解密