fix(home): 添加currentDMid空值检查防止异常
This commit is contained in:
parent
b7134046e8
commit
b96a82ad96
|
|
@ -909,6 +909,8 @@ export default {
|
|||
|
||||
// 刷新当前对话的消息详情
|
||||
handleGetConversationDetail() {
|
||||
if (!this.currentDMid) return;
|
||||
|
||||
this.$u.api
|
||||
.GetConversationDetail({
|
||||
"Item1.Id": this.currentDMid,
|
||||
|
|
@ -932,6 +934,8 @@ export default {
|
|||
|
||||
// 刷新当前页数据;若当前页为空且页码>1,则自动回退上一页
|
||||
refreshPageWithFallback() {
|
||||
if (!this.currentDMid) return;
|
||||
|
||||
const currentIndex = this.pageQuery.PageIndex || 1;
|
||||
const pageSize = this.pageQuery.PageSize;
|
||||
|
||||
|
|
@ -983,6 +987,8 @@ export default {
|
|||
onScrollToUpper() {
|
||||
console.log("触发上拉刷新");
|
||||
|
||||
if (!this.currentDMid) return;
|
||||
|
||||
// 如果已经没有更多数据或正在切换对话或当前对话为空(新建对话),不再触发上拉刷新
|
||||
if (this.noMoreData || this.isSwitchingConversation) {
|
||||
return;
|
||||
|
|
|
|||
Loading…
Reference in New Issue