扫码地址问题处理
This commit is contained in:
parent
51e6d98827
commit
a7ef77145c
18
src/app.wpy
18
src/app.wpy
@ -35,7 +35,7 @@ wepy.app({
|
||||
}
|
||||
},
|
||||
globalData: {
|
||||
versions: 'v5.5.99', // 版本号
|
||||
versions: 'v5.5.100', // 版本号
|
||||
navBarHeight: 0, // 导航栏高度
|
||||
navRight: 0, // 胶囊距右方间距(方保持左、右间距一致)
|
||||
navTop: 0, // 胶囊距顶部间距
|
||||
@ -89,9 +89,9 @@ wepy.app({
|
||||
|
||||
onShow(options) {
|
||||
console.log('路径携带参数:', options)
|
||||
if (options.path === 'pages/home/informationV2') {
|
||||
wx.redirectTo({ url: `/pages/home/information?${decodeURIComponent(options.query.scene)}` })
|
||||
}
|
||||
// if (options.path === 'pages/home/informationV2') {
|
||||
// wx.redirectTo({ url: `/pages/home/information?${decodeURIComponent(options.query.scene)}` })
|
||||
// }
|
||||
if (options.path === 'pages/tabBar/home1') {
|
||||
wx.switchTab({ url: `/pages/tabBar/home?${decodeURIComponent(options.query.scene)}` })
|
||||
}
|
||||
@ -114,9 +114,13 @@ wepy.app({
|
||||
},
|
||||
onPageNotFound(res) {
|
||||
console.log(res, '错误res')
|
||||
wx.switchTab({
|
||||
url: '/pages/tabBar/home'
|
||||
}) // 如果是 tabbar 页面,请使用 wx.switchTab
|
||||
if (res.path === 'pages/home/informationV2') {
|
||||
wx.redirectTo({ url: `/pages/home/information?${decodeURIComponent(res.query.scene)}` })
|
||||
} else {
|
||||
wx.switchTab({
|
||||
url: `/pages/tabBar/home?${decodeURIComponent(res.query.scene)}`
|
||||
}) // 如果是 tabbar 页面,请使用 wx.switchTab
|
||||
}
|
||||
},
|
||||
onHide() {},
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user