绿满眶商城微信小程序-uniapp
zxl
昨天 d1cada30a4b98000ef9c8970f0e2b53ed76e352c
pages/tabbar/index/home.vue
@@ -441,7 +441,18 @@
    userAction(param)
  },
   onLoad(option) {
      if(option.shareId){
         console.log('触发onLoad')
         this.actionParam.shareId = option.shareId;
         this.actionParam.joinType = 'SHARE'
         uni.setStorage({
            key: 'shareId',
            data: option.shareId,
            success: function () {
               console.log('缓存shareId成功');
            }
         });
      }
      console.log('-----------分享出的数据---------->', option)
      //处理扫码出来的视频
      this.marginBottom = uni.getSystemInfoSync().safeAreaInsets.bottom
@@ -513,13 +524,15 @@
      // })
      // 保存分享记录
      // 返回一个Promise
      return new Promise((resolve) => {
               this.shareId = '';
               this.shareParam.shareOption = JSON.stringify({
                  id:this.activityId
               })
               let shareObj ={
                  videoId:videoInfo.id,
                  userId:userInfo.id
               }
               this.shareParam.shareOption = JSON.stringify(shareObj)
               userShare(this.shareParam).then(res => {
                 this.shareId = res.data.data;
                 let param = {