...
|
...
|
@@ -112,18 +112,24 @@ export default { |
|
|
computed: {
|
|
|
...mapState(['channelList']),
|
|
|
navList() {
|
|
|
this.$nextTick(() => {
|
|
|
this.refreshProductList(this.active);
|
|
|
});
|
|
|
return get(find(this.channelList.list, ['template_name', 'guessLike']), 'data') || [];
|
|
|
}
|
|
|
},
|
|
|
watch: {
|
|
|
'channelList.list': function() {
|
|
|
this.init();
|
|
|
},
|
|
|
navList() {
|
|
|
this.$nextTick(() => {
|
|
|
this.refreshProductList(this.active);
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
activated() {
|
|
|
if (!this.channelList.list || !this.channelList.list.length) {
|
|
|
this.fetchChannelList();
|
|
|
}
|
|
|
this.init();
|
|
|
this.PAGE_URL = window.location.href;
|
|
|
// 首页进入上报
|
|
|
this.$store.dispatch('reportYas', {
|
...
|
...
|
@@ -132,14 +138,13 @@ export default { |
|
|
appop: 'XY_UFO_MAIN_START'
|
|
|
}
|
|
|
});
|
|
|
if (!this.channelList.list || !this.channelList.list.length) {
|
|
|
this.fetchChannelList();
|
|
|
}
|
|
|
this.init();
|
|
|
},
|
|
|
async serverPrefetch() {
|
|
|
return this.fetchChannelList();
|
|
|
},
|
|
|
mounted() {
|
|
|
this.refreshProductList(this.active);
|
|
|
},
|
|
|
methods: {
|
|
|
...mapActions(['fetchChannelList']),
|
|
|
...mapActionsList(['fetchProductList']),
|
...
|
...
|
@@ -195,7 +200,7 @@ export default { |
|
|
},
|
|
|
reportYas(scrollY) {
|
|
|
this.getReportEle(scrollY)
|
|
|
console.log(this.homeYasParams)
|
|
|
// console.log(this.homeYasParams)
|
|
|
this.$store.dispatch('reportYas', {
|
|
|
params: {
|
|
|
param: this.homeYasParams,
|
...
|
...
|
@@ -205,7 +210,7 @@ export default { |
|
|
},
|
|
|
setYasParam: function(params) {
|
|
|
let {total, list} = this.productList;
|
|
|
|
|
|
|
|
|
if (params && typeof params === 'object' && Object.keys(params).length) {
|
|
|
let P_NAME = 'XY_UFOSearchList', TYPE_ID = 1, P_PARAM = '', PRD_LIST = [];
|
|
|
for (let item of list) {
|
...
|
...
|
@@ -276,7 +281,7 @@ export default { |
|
|
// this.$refs.scroll.forceUpdate();
|
|
|
// return;
|
|
|
// }
|
|
|
|
|
|
|
|
|
await this.fetchList(this.selectedCategory);
|
|
|
this.$refs.scroll.forceUpdate();
|
|
|
},
|
...
|
...
|
@@ -455,7 +460,7 @@ export default { |
|
|
position: relative;
|
|
|
z-index: 1;
|
|
|
}
|
|
|
|
|
|
|
|
|
.channel-no-item {
|
|
|
padding-top: 200px;
|
|
|
}
|
...
|
...
|
|