Fix(首页):[#1113]每次从其他页面返回首页时刷新首页,以达到每次进入首页尖货推荐都随机刷新商品列表的效果
This commit is contained in:
+16
-1
@@ -410,8 +410,12 @@ export default {
|
||||
this.getUnreadMsgList();
|
||||
}
|
||||
|
||||
//获取团购商品
|
||||
// 获取团购商品
|
||||
this.getGroupGoods();
|
||||
// fix bug#1113
|
||||
if (this.bastList.length > 0) {
|
||||
this.getBastList()
|
||||
}
|
||||
},
|
||||
onShareAppMessage() {
|
||||
return {
|
||||
@@ -528,6 +532,17 @@ export default {
|
||||
});
|
||||
});
|
||||
},
|
||||
getBastList() {
|
||||
getHomeData().then(res => {
|
||||
const { success, data } = res
|
||||
if (success) {
|
||||
for (let i = 0; i < data.bastList.length; i++) {
|
||||
data.bastList[i].hide = true
|
||||
}
|
||||
this.$set(that, 'bastList', data.bastList)
|
||||
}
|
||||
})
|
||||
},
|
||||
getGroupGoods() {
|
||||
var params = {
|
||||
page: 1,
|
||||
|
||||
@@ -186,6 +186,8 @@ export default {
|
||||
|
||||
changeTabs(index) {
|
||||
if (this.isManage) return
|
||||
// fix bug#1111
|
||||
this.isAll = false
|
||||
this.tabsIndex = index
|
||||
this.page = 1
|
||||
this.fetchData()
|
||||
|
||||
Reference in New Issue
Block a user