Showing
3 changed files
with
29 additions
and
22 deletions
| @@ -4,7 +4,7 @@ import PageModel from '../../viewmodel/PageModel'; | @@ -4,7 +4,7 @@ import PageModel from '../../viewmodel/PageModel'; | ||
| 4 | import { CommonConstants, ViewType } from 'wdConstant' | 4 | import { CommonConstants, ViewType } from 'wdConstant' |
| 5 | import { EmptyComponent,WDViewDefaultType } from '../view/EmptyComponent' | 5 | import { EmptyComponent,WDViewDefaultType } from '../view/EmptyComponent' |
| 6 | import { ErrorComponent } from '../view/ErrorComponent' | 6 | import { ErrorComponent } from '../view/ErrorComponent' |
| 7 | -import { CompDTO, ContentDTO } from 'wdBean' | 7 | +import { CompDTO, ContentDTO, contentListParams,contentListItem } from 'wdBean' |
| 8 | import NoMoreLayout from './NoMoreLayout' | 8 | import NoMoreLayout from './NoMoreLayout' |
| 9 | import { CustomSelectUI } from '../view/CustomSelectUI'; | 9 | import { CustomSelectUI } from '../view/CustomSelectUI'; |
| 10 | import { CustomBottomFuctionUI } from '../view/CustomBottomFuctionUI'; | 10 | import { CustomBottomFuctionUI } from '../view/CustomBottomFuctionUI'; |
| @@ -149,16 +149,13 @@ struct MyCollectionListPage { | @@ -149,16 +149,13 @@ struct MyCollectionListPage { | ||
| 149 | .margin({left:16}) | 149 | .margin({left:16}) |
| 150 | } | 150 | } |
| 151 | Column() { | 151 | Column() { |
| 152 | - BigPicCardComponent({compDTO:new CompDTO,contentDTO:compDTO}) | 152 | + BigPicCardComponent({compDTO:new CompDTO,contentDTO:compDTO,pageId:TrackConstants.PageName.My_Collect,pageName:TrackConstants.PageName.My_Collect}) |
| 153 | } | 153 | } |
| 154 | }.onVisibleAreaChange([0.0, 1.0], (isVisible: boolean, currentRatio: number) => { | 154 | }.onVisibleAreaChange([0.0, 1.0], (isVisible: boolean, currentRatio: number) => { |
| 155 | if (isVisible) { | 155 | if (isVisible) { |
| 156 | TrackingContent.common(TrackConstants.EventType.Show, TrackConstants.PageName.My_Collect,TrackConstants.PageName.My_Collect, TrackParamConvert.program(compDTO)) | 156 | TrackingContent.common(TrackConstants.EventType.Show, TrackConstants.PageName.My_Collect,TrackConstants.PageName.My_Collect, TrackParamConvert.program(compDTO)) |
| 157 | } | 157 | } |
| 158 | }) | 158 | }) |
| 159 | - // .onClick(()=>{ | ||
| 160 | - // TrackingContent.common(TrackConstants.EventType.Click, TrackConstants.PageName.My_Collect,TrackConstants.PageName.My_Collect, TrackParamConvert.program(compDTO)) | ||
| 161 | - // }) | ||
| 162 | } | 159 | } |
| 163 | 160 | ||
| 164 | 161 | ||
| @@ -262,4 +259,12 @@ struct MyCollectionListPage { | @@ -262,4 +259,12 @@ struct MyCollectionListPage { | ||
| 262 | } | 259 | } |
| 263 | } | 260 | } |
| 264 | 261 | ||
| 262 | + getContentData(){ | ||
| 263 | + for (let index = 0; index < this.allDatas.length; index++) { | ||
| 264 | + const compDTO = this.allDatas[index]; | ||
| 265 | + compDTO.isCollection = true ///用于时间展示 | ||
| 266 | + this.allDatas.push(compDTO) | ||
| 267 | + } | ||
| 268 | + } | ||
| 269 | + | ||
| 265 | } | 270 | } |
| @@ -15,6 +15,8 @@ const TAG: string = 'BigPicCardComponent'; | @@ -15,6 +15,8 @@ const TAG: string = 'BigPicCardComponent'; | ||
| 15 | @Component | 15 | @Component |
| 16 | export struct BigPicCardComponent { | 16 | export struct BigPicCardComponent { |
| 17 | @ObjectLink compDTO: CompDTO | 17 | @ObjectLink compDTO: CompDTO |
| 18 | + @State pageId: string = ''; | ||
| 19 | + @State pageName: string = ''; | ||
| 18 | contentDTO: ContentDTO = new ContentDTO(); | 20 | contentDTO: ContentDTO = new ContentDTO(); |
| 19 | 21 | ||
| 20 | aboutToAppear() { | 22 | aboutToAppear() { |
| @@ -110,7 +112,7 @@ export struct BigPicCardComponent { | @@ -110,7 +112,7 @@ export struct BigPicCardComponent { | ||
| 110 | 112 | ||
| 111 | @Builder | 113 | @Builder |
| 112 | cardBuild() { | 114 | cardBuild() { |
| 113 | - CardParser({ compDTO: this.compDTO, contentDTO: this.contentDTO }); | 115 | + CardParser({ compDTO: this.compDTO, contentDTO: this.contentDTO,pageId:this.pageId,pageName:this.pageName}); |
| 114 | } | 116 | } |
| 115 | } | 117 | } |
| 116 | 118 |
| @@ -74,6 +74,22 @@ struct LaunchAdvertisingPage { | @@ -74,6 +74,22 @@ struct LaunchAdvertisingPage { | ||
| 74 | bottom: 0 | 74 | bottom: 0 |
| 75 | }) | 75 | }) |
| 76 | 76 | ||
| 77 | + if (this.defaultModel.isAd === '1'){ | ||
| 78 | + Stack({alignContent:Alignment.TopStart}){ | ||
| 79 | + Text('广告') | ||
| 80 | + .fontColor(Color.White) | ||
| 81 | + .textAlign(TextAlign.Center) | ||
| 82 | + .fontSize('24lpx') | ||
| 83 | + .width('72lpx') | ||
| 84 | + .height('36lpx') | ||
| 85 | + .borderRadius(2) | ||
| 86 | + .margin({top:'15lpx',left:'19lpx'}) | ||
| 87 | + .backgroundColor('#80000000') | ||
| 88 | + } | ||
| 89 | + .width('100%') | ||
| 90 | + .height('100%') | ||
| 91 | + } | ||
| 92 | + | ||
| 77 | Stack({alignContent:Alignment.TopEnd}){ | 93 | Stack({alignContent:Alignment.TopEnd}){ |
| 78 | Button(){ | 94 | Button(){ |
| 79 | Text(this.time + 's 跳过') | 95 | Text(this.time + 's 跳过') |
| @@ -95,22 +111,6 @@ struct LaunchAdvertisingPage { | @@ -95,22 +111,6 @@ struct LaunchAdvertisingPage { | ||
| 95 | .width('100%') | 111 | .width('100%') |
| 96 | .height('100%') | 112 | .height('100%') |
| 97 | 113 | ||
| 98 | - if (this.defaultModel.isAd === '1'){ | ||
| 99 | - Stack({alignContent:Alignment.TopStart}){ | ||
| 100 | - Text('广告') | ||
| 101 | - .fontColor(Color.White) | ||
| 102 | - .textAlign(TextAlign.Center) | ||
| 103 | - .fontSize('24lpx') | ||
| 104 | - .width('72lpx') | ||
| 105 | - .height('36lpx') | ||
| 106 | - .borderRadius(2) | ||
| 107 | - .margin({top:'15lpx',left:'19lpx'}) | ||
| 108 | - .backgroundColor('#80000000') | ||
| 109 | - } | ||
| 110 | - .width('100%') | ||
| 111 | - .height('100%') | ||
| 112 | - } | ||
| 113 | - | ||
| 114 | if(this.defaultModel.screenType != '2'){ | 114 | if(this.defaultModel.screenType != '2'){ |
| 115 | //底部logo样式 按钮加载在背景展示图上 | 115 | //底部logo样式 按钮加载在背景展示图上 |
| 116 | Button(){ | 116 | Button(){ |
-
Please register or login to post a comment