daijian_wd

fix: 语音播报按钮条件bug修复-16780

... ... @@ -47,7 +47,8 @@ export struct ImageAndTextPageComponent {
@State isPageEnd: boolean = false
@State publishTime: string = ''
@State publishCommentModel: publishCommentModel = new publishCommentModel()
@State operationButtonList: string[] = ['comment', 'collect', 'share']
// @State operationButtonList: string[] = ['comment', 'collect', 'share']
@State operationButtonList: string[] = []
@State isNetConnected: boolean = true
@State info: Area | null = null
@State likeNum: number = 0
... ... @@ -170,11 +171,13 @@ export struct ImageAndTextPageComponent {
}
}
//底部交互区
OperRowListView({
contentDetailData: this.contentDetailData[0],
publishCommentModel: this.publishCommentModel,
operationButtonList: this.operationButtonList,
})
if (this.operationButtonList.length) {
OperRowListView({
contentDetailData: this.contentDetailData[0],
publishCommentModel: this.publishCommentModel,
operationButtonList: this.operationButtonList,
})
}
}
}
... ... @@ -224,8 +227,11 @@ export struct ImageAndTextPageComponent {
this.publishCommentModel.keyArticle = String(this.contentDetailData[0]?.keyArticle)
this.publishCommentModel.targetType = String(this.contentDetailData[0]?.newsType)
}
if (this.contentDetailData[0]?.audioList?.length && this.contentDetailData[0]?.audioList[0].audioUrl) {
if (this.contentDetailData[0]?.openAudio && this.contentDetailData[0]?.audioList?.length &&
this.contentDetailData[0]?.audioList[0].audioUrl) {
this.operationButtonList = ['comment', 'collect', 'listen', 'share']
} else {
this.operationButtonList = ['comment', 'collect', 'share']
}
}
}
... ...