...
|
...
|
@@ -174,18 +174,11 @@ export default { |
|
|
return get(this.productDetail, 'goods_list[0].size_list', null);
|
|
|
},
|
|
|
},
|
|
|
beforeRouteUpdate(to, from, next) {
|
|
|
// const loading = this.createLoading();
|
|
|
|
|
|
this.loadData(to.params.productId);
|
|
|
next();
|
|
|
},
|
|
|
mounted() {
|
|
|
this.loadData(this.productId);
|
|
|
this.imageHideThreadhold = -window.innerWidth * 0.693;
|
|
|
},
|
|
|
activated() {
|
|
|
this.refresh();
|
|
|
this.loadData(this.productId);
|
|
|
},
|
|
|
methods: {
|
|
|
...mapActions(['fetchProductInfo', 'fetchTop3', 'toggleFav', 'updateTradeInfo', 'getSelectedTradeProduct']),
|
...
|
...
|
@@ -239,11 +232,21 @@ export default { |
|
|
});
|
|
|
},
|
|
|
gotoBrand() {
|
|
|
// type: 4,品牌;5,系列
|
|
|
const query = {
|
|
|
type: 5,
|
|
|
};
|
|
|
|
|
|
if (this.productDetail.seriesId) {
|
|
|
query.series = this.productDetail.seriesId;
|
|
|
} else {
|
|
|
query.type = 4;
|
|
|
query.brand = this.productDetail.brandId;
|
|
|
}
|
|
|
|
|
|
this.$router.push({
|
|
|
name: '',
|
|
|
params: {
|
|
|
productId: this.productDetail.product_id,
|
|
|
},
|
|
|
name: 'List',
|
|
|
query,
|
|
|
});
|
|
|
},
|
|
|
showActivity() {
|
...
|
...
|
@@ -430,12 +433,13 @@ export default { |
|
|
}
|
|
|
|
|
|
.recommend {
|
|
|
margin-top: 20px;
|
|
|
padding-top: 20px;
|
|
|
background: #f5f5f5;
|
|
|
|
|
|
h2 {
|
|
|
font-size: 36px;
|
|
|
line-height: 50px;
|
|
|
padding: 20px 0;
|
|
|
padding: 20px 0 0;
|
|
|
margin: 0 40px;
|
|
|
}
|
|
|
}
|
...
|
...
|
|