分享出去的页面是有参数的,为啥接收不到参数?

发布于 7 年前作者 xiulanshen15004 次浏览最后编辑 7 年前来自 issues

分享出去的页面是有参数的,为啥接收不到参数?

5 回复
lixue
lixue1 楼5 年前

分享的代码是怎么写的?当前页面有参数,分享的代码也需要把参数加上才行

changxiulan
changxiulan2 楼5 年前
onShareAppMessage: function (res{
    let that = this
    if (res.from === 'button') {
      // 来自页面内转发按钮
      // console.log(res.target)
    }
    let path = '/pages/cart/new?shareKey=' + shareKey
    console.log(path)
    return {
      title'购物车分享',
      path: path,
    }
  }  
onLoadfunction (options{
    console.log('options', options)
}

手机打印会有这个initNativeTransServiceId. ntrans:object componentId :-961943802
na13
na133 楼5 年前

shareKey 在哪里定义的 建议你logshareKey看一下

 

jun92
jun924 楼5 年前

参数走丢了

wwan
wwan5 楼5 年前

代码怎么写的