Skip to content

Commit

Permalink
增加商品详情页面转发功能
Browse files Browse the repository at this point in the history
  • Loading branch information
gooking committed May 20, 2017
1 parent dc8db51 commit cf7e099
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions pages/goods-details/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ Page({
selectSizePrice:res.data.data.basicInfo.minPrice,
});
}
that.data.goodsDetail = res.data.data;
that.setData({
goodsDetail:res.data.data,
selectSizePrice:res.data.data.basicInfo.minPrice,
Expand Down Expand Up @@ -256,5 +257,17 @@ Page({
}
this.addShopCar();
this.goShopCar();
},
onShareAppMessage: function () {
return {
title: this.data.goodsDetail.basicInfo.name,
path: '/pages/goods-details/index?id=' + this.data.goodsDetail.basicInfo.id,
success: function (res) {
// 转发成功
},
fail: function (res) {
// 转发失败
}
}
}
})

0 comments on commit cf7e099

Please sign in to comment.