liukangdong
2024-08-02 52787adceb282c1914589c7ceb252bdb03e2df36
wechat_jiaxuan/pages/consult/detail.js
@@ -9,6 +9,7 @@
    info: {},
    detail: {},
    origin: '',
    showShare: false
  },
@@ -20,10 +21,25 @@
    this.setData({
      bottomLift: app.bottomLift
    })
    this.getDetail(options.id)
    if(options.origin && options.origin == 'b'){
      this.setData({ origin: 'b' })
    }
    this.getDetail(options.id, options.userId || '')
  },
  getDetail(id) {
    getProductNewsInfo({ id }).then(res => {
  handleDesign() {
    wx.navigateTo({
      url: '/pages/design/design',
    })
  },
  onShareAppMessage() {
    let { info } = this.data
    console.log('点击了分享')
    return {
      path: '/pages/consult/detail?id=' + info.id + '&userId=' + info.users.id
    }
  },
  getDetail(id, userId) {
    getProductNewsInfo({ id, salesId: userId || null }).then(res => {
      this.setData({ info: res.data })
      wx.setNavigationBarTitle({
        title: res.data.title
@@ -69,13 +85,6 @@
   * 页面上拉触底事件的处理函数
   */
  onReachBottom() {
  },
  /**
   * 用户点击右上角分享
   */
  onShareAppMessage() {
  }
})