收藏
回答

扫码进入小程序页面,通过携带的参数判断是否要跳转,结果跳转了两次?

扫码进入小程序页面,通过携带的参数判断是否要跳转,结果连续跳转了两次,并且在第二次跳转的时候携带的参数为空

if (!that.isOrBind) {

uni.navigateTo({

url: '../../pages/choosingPets/choosingPets?type=4&scene=' + that.scene

})

this.scene = ''

} else {

console.log('跳转')

uni.navigateTo({

url: '../../pagesA/dogTagIndex/dogTagInfo?scene=' + that.scene

})

this.scene = ''

console.log(this.scene)

}

走else的时候,连续跳转了两次,但是congsole只打印一次,isOrBind是进入页面后请求来的

回答关注问题邀请回答
收藏

1 个回答

  • 社区技术运营专员-Jahozheng
    社区技术运营专员-Jahozheng
    2021-03-21

    你好,麻烦通过点击下方“反馈信息”按钮,提供出现问题的以及能复现问题的代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)。

    待楼主反馈
    2021-03-21
    有用
    回复
登录 后发表内容
问题标签