chenjun3_wd

直播列表item跳图文详情页,其他bug修复

@@ -86,9 +86,8 @@ struct ReserveMorePage { @@ -86,9 +86,8 @@ struct ReserveMorePage {
86 // .title('直播列表') 86 // .title('直播列表')
87 87
88 Column() { 88 Column() {
  89 + this.TabbarNormal()
89 Column() { 90 Column() {
90 - this.TabbarNormal()  
91 -  
92 this.ListLayout() 91 this.ListLayout()
93 } 92 }
94 .padding({ 93 .padding({
@@ -6,6 +6,8 @@ import { WDRouterPage, WDRouterRule } from 'wdRouter/Index' @@ -6,6 +6,8 @@ import { WDRouterPage, WDRouterRule } from 'wdRouter/Index'
6 import { CardMediaInfo } from '../cardCommon/CardMediaInfo' 6 import { CardMediaInfo } from '../cardCommon/CardMediaInfo'
7 import { ExtraDTO } from 'wdBean/src/main/ets/bean/component/extra/ExtraDTO' 7 import { ExtraDTO } from 'wdBean/src/main/ets/bean/component/extra/ExtraDTO'
8 import { LiveModel } from '../../viewmodel/LiveModel' 8 import { LiveModel } from '../../viewmodel/LiveModel'
  9 +import { ContentConstants } from '../../constants/ContentConstants'
  10 +import { ProcessUtils } from '../../utils/ProcessUtils'
9 11
10 @Component 12 @Component
11 export struct LiveHorizontalCardComponent { 13 export struct LiveHorizontalCardComponent {
@@ -25,7 +27,7 @@ export struct LiveHorizontalCardComponent { @@ -25,7 +27,7 @@ export struct LiveHorizontalCardComponent {
25 .fontWeight(600) 27 .fontWeight(600)
26 } 28 }
27 29
28 - if (this.compDTO.operDataList.length > 2) { 30 + if (this.compDTO.dataSourceType === 'LIVE_HORIZONTAL_CARD' || this.compDTO.dataSourceType === 'LIVE_MONTHLY_RANKING') {
29 Row() { 31 Row() {
30 Text("更多") 32 Text("更多")
31 .fontSize($r("app.float.font_size_14")) 33 .fontSize($r("app.float.font_size_14"))
@@ -118,26 +120,34 @@ export struct LiveHorizontalCardComponent { @@ -118,26 +120,34 @@ export struct LiveHorizontalCardComponent {
118 120
119 async gotoLive(content: ContentDTO) { 121 async gotoLive(content: ContentDTO) {
120 const liveDetail = await LiveModel.getLiveDetails(content?.objectId || '', content?.relId || '', content?.relType || '') 122 const liveDetail = await LiveModel.getLiveDetails(content?.objectId || '', content?.relId || '', content?.relType || '')
121 - const liveStyle = liveDetail[0].liveInfo.liveStyle  
122 - const liveState = liveDetail[0].liveInfo.liveState 123 + if (content && content.objectType) {
  124 + if (content.objectType === ContentConstants.TYPE_LIVE) {
  125 + if (liveDetail && liveDetail[0] && liveDetail[0].liveInfo) {
  126 + const liveStyle = liveDetail[0].liveInfo.liveStyle
  127 + const liveState = liveDetail[0].liveInfo.liveState
123 128
  129 + console.error('liveDetail===', liveDetail)
124 130
125 - console.error('liveDetail===', liveDetail) 131 + let taskAction: Action = {
  132 + type: 'JUMP_DETAIL_PAGE',
  133 + params: {
  134 + detailPageType: 2,
  135 + contentID: content?.objectId,
  136 + liveStyle: liveState === 'wait' ? 0 : liveStyle,
  137 + extra: {
  138 + relType: content?.relType,
  139 + relId: content?.relId,
  140 + } as ExtraDTO
  141 + } as Params,
  142 + };
  143 + WDRouterRule.jumpWithAction(taskAction)
  144 + // Logger.debug(TAG, `gotoLive, ${content.objectId}`);
  145 + }
  146 + } else if (content.objectType === ContentConstants.TYPE_TELETEXT) {
  147 + ProcessUtils.processPage(content)
  148 + }
  149 + }
126 150
127 151
128 - let taskAction: Action = {  
129 - type: 'JUMP_DETAIL_PAGE',  
130 - params: {  
131 - detailPageType: 2,  
132 - contentID: content?.objectId,  
133 - liveStyle: liveState === 'wait' ? 0 : liveStyle,  
134 - extra: {  
135 - relType: content?.relType,  
136 - relId: content?.relId,  
137 - } as ExtraDTO  
138 - } as Params,  
139 - };  
140 - WDRouterRule.jumpWithAction(taskAction)  
141 - // Logger.debug(TAG, `gotoLive, ${content.objectId}`);  
142 } 152 }
143 } 153 }
@@ -26,7 +26,7 @@ export struct LiveHorizontalReservationComponent { @@ -26,7 +26,7 @@ export struct LiveHorizontalReservationComponent {
26 .fontWeight(600) 26 .fontWeight(600)
27 } 27 }
28 28
29 - if (this.compDTO.operDataList.length > 2) { 29 + if (this.compDTO.dataSourceType === 'LIVE_RESERVATION') {
30 Row() { 30 Row() {
31 Text("更多") 31 Text("更多")
32 .fontSize($r("app.float.font_size_14")) 32 .fontSize($r("app.float.font_size_14"))