wx.switchTab({ url: ‘../../message/message/message‘,})
//wx.switchTab url不能带参数 解决方法?? (紫色表示非固定需要自己更改的)
app.js ??
globalData: {
activityid: ‘‘, //需要传递的参数
title: ‘‘ //需要传递的参数
}
传参页面.js ??
var app = getApp()
issue: function(e){
app.globalData.
activityid =
e.currentTarget.dataset.id
app.globalData.
title =
e.currentTarget.dataset.title
wx.switchTab({
url: ‘../../message/message/message‘,
})
}
取参页面.js ??
var
activityid = app.globalData.
activityid
var
title = app.globalData.
title