Showing
3 changed files
with
6 additions
and
2 deletions
| @@ -63,6 +63,8 @@ export struct EmptyComponent { | @@ -63,6 +63,8 @@ export struct EmptyComponent { | ||
| 63 | @State emptyButton: boolean = false | 63 | @State emptyButton: boolean = false |
| 64 | @State isBlack: boolean = false // 背景是否为黑色 默认白色 | 64 | @State isBlack: boolean = false // 背景是否为黑色 默认白色 |
| 65 | @State timeNum: number = 10 | 65 | @State timeNum: number = 10 |
| 66 | + ///占位图上是否显示返回按钮 | ||
| 67 | + @State showBackButton: boolean = true | ||
| 66 | /** | 68 | /** |
| 67 | * The empty image width percentage setting. | 69 | * The empty image width percentage setting. |
| 68 | */ | 70 | */ |
| @@ -111,6 +113,7 @@ export struct EmptyComponent { | @@ -111,6 +113,7 @@ export struct EmptyComponent { | ||
| 111 | build() { | 113 | build() { |
| 112 | Stack({alignContent:Alignment.Bottom}) { | 114 | Stack({alignContent:Alignment.Bottom}) { |
| 113 | this.noProgrammeData(); | 115 | this.noProgrammeData(); |
| 116 | + if (this.showBackButton) { | ||
| 114 | Image($r("app.media.icon_arrow_left_white")) | 117 | Image($r("app.media.icon_arrow_left_white")) |
| 115 | .width(24) | 118 | .width(24) |
| 116 | .height(24) | 119 | .height(24) |
| @@ -123,6 +126,7 @@ export struct EmptyComponent { | @@ -123,6 +126,7 @@ export struct EmptyComponent { | ||
| 123 | }) | 126 | }) |
| 124 | } | 127 | } |
| 125 | } | 128 | } |
| 129 | + } | ||
| 126 | 130 | ||
| 127 | /** | 131 | /** |
| 128 | * 无数据,空白view组件 | 132 | * 无数据,空白view组件 |
| @@ -78,7 +78,7 @@ export struct TabChatComponent { | @@ -78,7 +78,7 @@ export struct TabChatComponent { | ||
| 78 | } else if (this.pageModel.viewType == ViewType.ERROR) { | 78 | } else if (this.pageModel.viewType == ViewType.ERROR) { |
| 79 | ErrorComponent() | 79 | ErrorComponent() |
| 80 | } else if (this.pageModel.viewType == ViewType.EMPTY) { | 80 | } else if (this.pageModel.viewType == ViewType.EMPTY) { |
| 81 | - EmptyComponent({ emptyType: WDViewDefaultType.WDViewDefaultType_NoComment1 }) | 81 | + EmptyComponent({ emptyType: WDViewDefaultType.WDViewDefaultType_NoComment1, showBackButton:false}) |
| 82 | } else { | 82 | } else { |
| 83 | 83 | ||
| 84 | CustomPullToRefresh({ | 84 | CustomPullToRefresh({ |
| @@ -75,7 +75,7 @@ export struct TabLiveComponent { | @@ -75,7 +75,7 @@ export struct TabLiveComponent { | ||
| 75 | } else if (this.pageModel.viewType == ViewType.ERROR) { | 75 | } else if (this.pageModel.viewType == ViewType.ERROR) { |
| 76 | ErrorComponent() | 76 | ErrorComponent() |
| 77 | } else if (this.pageModel.viewType == ViewType.EMPTY) { | 77 | } else if (this.pageModel.viewType == ViewType.EMPTY) { |
| 78 | - EmptyComponent({ emptyType: WDViewDefaultType.WDViewDefaultType_NoContent1 }) | 78 | + EmptyComponent({ emptyType: WDViewDefaultType.WDViewDefaultType_NoContent1, showBackButton:false }) |
| 79 | } else { | 79 | } else { |
| 80 | CustomPullToRefresh({ | 80 | CustomPullToRefresh({ |
| 81 | alldata: this.liveList, | 81 | alldata: this.liveList, |
-
Please register or login to post a comment