jiangping
2024-09-27 04b4bddaac0a222760113899568d20b45af701f4
wechat_staff/pages/detailDis/product.js
@@ -14,6 +14,7 @@
    current: 0,
    id: '',
    info: {},
    spaceList: [],
    member: {},
    showShare: false,
    isFold: false,
@@ -80,10 +81,11 @@
        actionType: flag ? 'collect' : 'collect_cancel'
      }).then(res => {
        info.isCollection = flag
        wx.showToast({title: flag ? '收藏成功' : '取消收藏'})
        wx.showToast({title: flag ? '收藏成功' : '取消收藏', icon: 'none'})
        this.setData({
          info
        })
        wx.setStorageSync('conentCountTemp', this.data.info)
      })
    }
  },
@@ -101,6 +103,7 @@
    this.setData({ current: e.detail.current })
  },
  priviewSpace(e) {
    return
    const url = e.currentTarget.dataset.url
    const {
      info
@@ -118,13 +121,16 @@
    getProductInfo({
      id
    }).then(res => {
      const index = enjoyList.findIndex( i => i.id === res.data.id )
      const index = enjoyList.findIndex( i =>(res.data && i.id === res.data.id) )
      this.setData({
        spaceList: res.data.spaceList || [],
        info: {
          ...res.data,
          isEnjoy: index > -1
        }
      })
      const { info} = this.data
      wx.setStorageSync('conentCountTemp', info)
      wx.setNavigationBarTitle({
        title: res.data.title
      })
@@ -177,12 +183,7 @@
  //     title: productDetail.title,
  //     path: '/pages/index/index?id=' + productDetail.id + '&shareuserid=' + userInfo.id + '&type=0'
  //   }
  // },
  onClose() {
    this.setData({
      showShare: false
    })
  },
  // },
  handleDown() {
    let {
      info