|
@@ -17,8 +17,14 @@ Component({
|
|
|
methods: {
|
|
|
jumpGoodsDetail(e) {
|
|
|
const { item } = e.currentTarget.dataset
|
|
|
+ const page = getCurrentPages()
|
|
|
+ let id = item.id
|
|
|
+ if (page[page.length - 1].route === 'pages/collection/collection') {
|
|
|
+ id = item.product_id
|
|
|
+ }
|
|
|
+
|
|
|
wx.navigateTo({
|
|
|
- url: '/pages/goodsDetail/goodsDetail?product_id=' + item.id
|
|
|
+ url: '/pages/goodsDetail/goodsDetail?product_id=' + id
|
|
|
})
|
|
|
}
|
|
|
}
|