guochunsong

金刚卡微调

... ... @@ -18,42 +18,33 @@ export struct ZhGridLayoutComponent {
@State compDTO: CompDTO = {} as CompDTO
aboutToAppear() {
Logger.info(TAG + ' comp:'+ JSON.stringify(this.compDTO))
// Logger.info(TAG + ' comp:'+ JSON.stringify(this.compDTO))
}
build() {
Column() {
Flex({ wrap: FlexWrap.Wrap,
justifyContent: FlexAlign.SpaceEvenly,
alignItems :ItemAlign.End}) {
alignItems: ItemAlign.End }) {
ForEach(this.compDTO.operDataList, (item: ContentDTO) => {
Column() {
Image(item.coverUrl)
.width(50)
.width(44)
.borderRadius(5)
.aspectRatio(1 / 1)
.autoResize(true)
Text(item.newsTitle)
.fontSize(16)
.padding({ top: 10 })
}.margin({
top:5,
bottom:5,
left:5,
right :5
})
.fontSize(13)
.padding({ top: 8 })
}.height(68).width(75)
}, (item: ContentDTO) => JSON.stringify(item))
}
.backgroundColor(Color.White)
.borderRadius(12)
.padding({
top: 10,
bottom: 10
top: 14,
bottom: 14
})
.width(FULL_PARENT)
.margin(10)
}
}
}
... ...