页面1:传递参数(merchant:{})
enter(merchant) {
console.log("进店")
uni.navigateTo({
url: '/pages/home/Merchant?merchant=' + encodeURIComponent(JSON.stringify(merchant))
})
}
页面2:获取参数
onLoad(options) {
// 获取传递过来的商家信息
this.merchant = JSON.parse(decodeURIComponent(options.merchant))
}