Toggle navigation
Toggle navigation
This project
Loading...
Sign in
developOne
/
harmonyPool
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
yangchenggong1_wd
2024-05-27 18:08:28 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
adb3f8ee788db7d559e328fc2903cab383c5c812
adb3f8ee
1 parent
bf6aca2f
fix:bug[17461] 无网络时进入我的预约下,鸿蒙版显示的缺省图与安卓不一致
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
6 deletions
sight_harmony/features/wdComponent/src/main/ets/components/mine/appointment/AppointmentListUI.ets
sight_harmony/features/wdComponent/src/main/ets/components/mine/appointment/AppointmentListUI.ets
View file @
adb3f8e
...
...
@@ -2,7 +2,7 @@ import { AppointmentListChildComponent } from './AppointmentListChildComponent';
import { CustomTitleUI } from '../../reusable/CustomTitleUI'
import { ListHasNoMoreDataUI } from '../../reusable/ListHasNoMoreDataUI';
import { MineAppointmentItem } from '../../../viewmodel/MineAppointmentItem';
import { LazyDataSource, StringUtils } from 'wdKit';
import { LazyDataSource,
NetworkUtil,
StringUtils } from 'wdKit';
import MinePageDatasModel from '../../../model/MinePageDatasModel';
import { EmptyComponent } from '../../view/EmptyComponent';
import { Action, ContentDTO } from 'wdBean/Index';
...
...
@@ -23,6 +23,7 @@ export struct AppointmentListUI {
curPageNum: number = 1;
@State isGetRequest: boolean = false
private scroller: Scroller = new Scroller();
@State isConnectNetwork : boolean = NetworkUtil.isNetConnected()
aboutToAppear() {
this.getNewPageData()
...
...
@@ -34,13 +35,29 @@ export struct AppointmentListUI {
CustomTitleUI({ titleName: "我的预约" })
if (this.count == 0) {
if (this.isGetRequest == true) {
EmptyComponent({ emptyType: 10 })
.height('100%')
.width('100%')
if(this.isConnectNetwork){
EmptyComponent({ emptyType: 10 })
.height('100%')
.width('100%')
}else{
EmptyComponent({ emptyType: 1,emptyHeight:"100%" ,retry: () => {
this.isConnectNetwork = NetworkUtil.isNetConnected()
if(this.isConnectNetwork){
this.curPageNum = 1;
this.hasMore = true
this.isGetRequest = false
this.data.clear()
if (!this.isLoading) {
this.getNewPageData()
}
}
},})
.layoutWeight(1)
.width('100%')
}
}
} else {
CustomPullToRefresh({
alldata:this.data,
scroller:this.scroller,
...
...
Please
register
or
login
to post a comment