fix(notifications): 调整通知列表加载逻辑与刷新条件
- 修改ApiConfig中的showLog为false - 新增isLoading1状态用于区分不同加载场景 - 将RefreshView的isLoading绑定改为isLoading1 - 调整日期范围从5天改为10天 - 简化数据处理逻辑,移除多余临时变量 - 修复两个数据源请求参数顺序错误问题 - 更新分页加载判断逻辑并调整最小加载数量 - 修改下拉刷新触发距离阈值从200到100 - 缩短加载更多的时间间隔限制从1500ms到500ms
这个提交包含在:
父节点
9e21c58b86
当前提交
30d9e04954
@ -151,12 +151,12 @@ export struct RefreshView {
|
|||||||
break
|
break
|
||||||
case TouchType.Up:
|
case TouchType.Up:
|
||||||
this.endY = e1.y
|
this.endY = e1.y
|
||||||
if (this.endY - this.startY < -200 && this._openMore) {
|
if (this.endY - this.startY < -100 && this._openMore) {
|
||||||
const v = this.data && (this.data.length % this.pageSize) === 0
|
const v = this.data && (this.data.length % this.pageSize) === 0
|
||||||
if ((v && this.canLoadMore == 'default') || this.canLoadMore == 'allow') {
|
if ((v && this.canLoadMore == 'default') || this.canLoadMore == 'allow') {
|
||||||
const cTime = new Date().getTime()
|
const cTime = new Date().getTime()
|
||||||
// 2024.11.21 测试觉得刷新太多了,暂时改为1秒5间隔
|
// 2024.11.21 测试觉得刷新太多了,暂时改为1秒5间隔
|
||||||
if (cTime - this._oTime > 1500) {
|
if (cTime - this._oTime > 500) {
|
||||||
this.onLoadMore && this.onLoadMore(Math.floor(this.data.length / this.pageSize))
|
this.onLoadMore && this.onLoadMore(Math.floor(this.data.length / this.pageSize))
|
||||||
this._oTime = cTime
|
this._oTime = cTime
|
||||||
}
|
}
|
||||||
|
|||||||
正在加载...
在新工单中引用
屏蔽一个用户