视频列表的上拉刷新优化
This commit is contained in:
parent
4460de9be4
commit
205176ee94
@ -391,6 +391,7 @@
|
|||||||
limit: 10
|
limit: 10
|
||||||
},
|
},
|
||||||
communityId:'',
|
communityId:'',
|
||||||
|
Listcount:''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
@ -451,15 +452,24 @@
|
|||||||
onReady: function() {},
|
onReady: function() {},
|
||||||
methods: {
|
methods: {
|
||||||
async GetList(){
|
async GetList(){
|
||||||
console.log('123');
|
// if(this.cateGoods.length > )
|
||||||
const {data} = await graphicLstApi({
|
console.log(this.Listcount);
|
||||||
page: this.page++,
|
if(this.cateGoods.length < this.Listcount){
|
||||||
limit: this.limit,
|
console.log('123');
|
||||||
is_star: this.isSatrt,
|
const {data} = await graphicLstApi({
|
||||||
community_id: this.videoID
|
category_id:-1,
|
||||||
})
|
page: this.page++,
|
||||||
console.log(data);
|
limit: this.limit,
|
||||||
this.cateGoods.push(...data.list)
|
})
|
||||||
|
this.cateGoods.push(...data.list)
|
||||||
|
if(data.list.length < this.limit){
|
||||||
|
this.$util.Tips({
|
||||||
|
title: '没有更多了',
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// console.log(this.cateGoods.length);
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
giveStart(item) {
|
giveStart(item) {
|
||||||
@ -505,6 +515,7 @@
|
|||||||
this.loadVideo = true;
|
this.loadVideo = true;
|
||||||
this.dataList = [];
|
this.dataList = [];
|
||||||
n == 1 ? this.get() : '';
|
n == 1 ? this.get() : '';
|
||||||
|
n == 2 ? this.getFocusList() : '';
|
||||||
n == 3 ? this.getGoods() : '';
|
n == 3 ? this.getGoods() : '';
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
@ -520,6 +531,8 @@
|
|||||||
const {
|
const {
|
||||||
data
|
data
|
||||||
} = await graphicLstApi(this.where)
|
} = await graphicLstApi(this.where)
|
||||||
|
console.log(data);
|
||||||
|
this.Listcount=data.count
|
||||||
this.cateGoods = data.list
|
this.cateGoods = data.list
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user