This commit is contained in:
zhaofang
2022-11-11 18:52:22 +08:00
parent c0950fbb96
commit 1f38d830a0
3 changed files with 95 additions and 85 deletions

View File

@@ -43,7 +43,7 @@
tab:0,
data:[],//拿到的数据
total:0,//总条数
loadStatus:'more',//more,loading,noMore
loadStatus:'noMore',//more,loading,noMore
query:{
pageIndex:1,//当前页
type:null,//当前只限于文章
@@ -96,6 +96,7 @@
this.message.list = [];
this.queryData.pageIndex = 1;
}
let $this = this;
uni.showLoading({ title: '加载中...' });
apiMessage.list(this.queryData).then(res => {
if (res.status == 200) {
@@ -111,11 +112,6 @@
});
this.loadAuthorInfo(res.result.list,ids)
}
if(this.message.list.length<this.message.total){
this.loadStatus='more'
}else{
this.loadStatus='noMore'
}
} else {
this.$refs.toast.show({ message: '获取数据失败', type: 'error' })
}
@@ -146,11 +142,6 @@
})
this.loadAuthorInfo(res.result.list,ids);
}
if(this.data.length<this.total){
this.loadStatus='more'
}else{
this.loadStatus='noMore'
}
}else{
this.$refs.interactToast.show({message:'加载@我的评论失败',type:'error'});
}