收藏
回答

分享报错Cannot read property 'adUxInfo'?

onShareAppMessage: function (res) {

        const that = this

        const thingDetail = that.data.thingDetail

        // const userId = that.data.userId==='none' ? that.data.userInfo._id : that.data.userId

        let userId

        if(that.data.userId==='none'){

            userId = that.data.userInfo._id

        }else{

            userId = that.data.userId

        }

        return {

            title: thingDetail.thingTitle,

            path: '/pages/detail/detail?isByShere=true&userId='+ userId + '&_id=' + thingDetail._id+"&category=" + thingDetail.categoryName,

            imageUrl: thingDetail.tempImages[0],

            fail: function(res){

                that.showPrompt('暂时无法分享')

            }

        }

    }

这是为什么呀,我不知道我哪里有问题呀,真机调试只要点了分享就有这个

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

2 个回答

  • 是小白啊
    是小白啊
    2020-04-24

    麻烦提供能复现问题的代码片段https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html

    2020-04-24
    有用
    回复
  • Wang
    Wang
    2020-04-24

    页面上有接入广告组件或插件吗

    2020-04-24
    有用
    回复 5
    • Seagull
      Seagull
      2020-04-24
      分享的这个页面没有使用任何插件,都是从云端数据库的数据呀,也没有广告呀
      2020-04-24
      回复
    • Seagull
      Seagull
      2020-04-24
      这个样子的,都是普通的数据呀
      2020-04-24
      回复
    • Seagull
      Seagull
      2020-04-24
      我刚才试了一下就return一个title和path居然还报错 ,能发出去,点了不发也是报这个错误,无解
      2020-04-24
      回复
    • Wang
      Wang
      2020-04-24回复Seagull
      真机调试不行,看看预览吧,在console里输出要调试的信息
      2020-04-24
      回复
    • Seagull
      Seagull
      2020-04-24
      我试了一下调试库2.9.5不会报错真机调试
      2020-04-24
      回复
登录 后发表内容
问题标签