// 彩图奔跑APP中的JS函数调用 var appfunc = { /* 微信分享 参数data格式: { title: "彩图奔跑商家版", url: "https://oss-mbh5.colormaprun.com/shop/", image: "https://oss-mbh5.colormaprun.com/shop/static/logo.png", scene: "session" // session:分享到对话 timeline:分享到朋友圈 favorite:分享到收藏 }; */ shareWx(data) { data = JSON.stringify(data); // console.log("[appfunc] shareWx: data", data); share_wx.postMessage(data); }, /* 打开微信小程序 参数data格式: { username: "gh_bea09156da8d", // 小程序原始ID path: "" // 小程序页面路径(为空则表示进入默认首页) 商家首页:pages/index/index?mall_id=3892 积分中心:pages/integralRedeem/index?mall_id=3892 }; */ launchWxMini(data) { data = JSON.stringify(data); console.log("[appfunc] launchWxMini: data", data); wx_launch_mini.postMessage(data); } } export default appfunc;