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
陈剑华
2024-05-22 14:07:33 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
4900c436ff34f2af50beabd2c00d2af2c95e31af
4900c436
1 parent
355c87f8
feat: 17989 轮播图卡-音频专题数据展示交互问题
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
2 deletions
sight_harmony/features/wdComponent/src/main/ets/components/CompParser.ets
sight_harmony/features/wdComponent/src/main/ets/components/CompParser.ets
View file @
4900c43
import { CompDTO } from 'wdBean';
import { CompDTO
, ContentDTO
} from 'wdBean';
import { CommonConstants, CompStyle } from 'wdConstant/Index';
import { WDRouterPage, WDRouterRule } from 'wdRouter/Index';
import PageModel from '../viewmodel/PageModel';
...
...
@@ -35,10 +35,20 @@ export struct CompParser {
@ObjectLink compDTO: CompDTO
@State compIndex: number = 0;
@State private pageModel: PageModel = new PageModel();
@State audioItems: ContentDTO[] = [];
@State noneAudioItems: ContentDTO[] = [];
aboutToAppear(): void {
// 轮播图屏蔽音频类型稿件
if (this.compDTO.compStyle === CompStyle.Zh_Carousel_Layout_01) {
this.audioItems = this.compDTO.operDataList.filter(item => item.appStyle === '13')
this.noneAudioItems = this.compDTO.operDataList.filter(item => item.appStyle !== '13')
this.compDTO.operDataList = this.noneAudioItems;
}
}
build() {
Column() {
this.componentBuilder();
}
}
...
...
@@ -54,8 +64,10 @@ export struct CompParser {
LabelComponent({ compDTO: this.compDTO })
Divider().strokeWidth(1).color('#f5f5f5').padding({ left: 16, right: 16 })
} else if (this.compDTO.compStyle === CompStyle.Zh_Carousel_Layout_01) {
if (this.compDTO.operDataList.length > this.audioItems.length) {
ZhCarouselLayout01({ compDTO: this.compDTO })
Divider().strokeWidth(1).color('#f5f5f5').padding({ left: 16, right: 16 })
}
} else if (this.compDTO.compStyle === CompStyle.Zh_Single_Row_01 &&
this.compDTO.imageScale === 2) { // && compDTO.name ==="横划卡"
...
...
Please
register
or
login
to post a comment