daijian_wd

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

@@ -47,7 +47,8 @@ export struct ImageAndTextPageComponent { @@ -47,7 +47,8 @@ export struct ImageAndTextPageComponent {
47 @State isPageEnd: boolean = false 47 @State isPageEnd: boolean = false
48 @State publishTime: string = '' 48 @State publishTime: string = ''
49 @State publishCommentModel: publishCommentModel = new publishCommentModel() 49 @State publishCommentModel: publishCommentModel = new publishCommentModel()
50 - @State operationButtonList: string[] = ['comment', 'collect', 'share'] 50 + // @State operationButtonList: string[] = ['comment', 'collect', 'share']
  51 + @State operationButtonList: string[] = []
51 @State isNetConnected: boolean = true 52 @State isNetConnected: boolean = true
52 @State info: Area | null = null 53 @State info: Area | null = null
53 @State likeNum: number = 0 54 @State likeNum: number = 0
@@ -170,11 +171,13 @@ export struct ImageAndTextPageComponent { @@ -170,11 +171,13 @@ export struct ImageAndTextPageComponent {
170 } 171 }
171 } 172 }
172 //底部交互区 173 //底部交互区
173 - OperRowListView({  
174 - contentDetailData: this.contentDetailData[0],  
175 - publishCommentModel: this.publishCommentModel,  
176 - operationButtonList: this.operationButtonList,  
177 - }) 174 + if (this.operationButtonList.length) {
  175 + OperRowListView({
  176 + contentDetailData: this.contentDetailData[0],
  177 + publishCommentModel: this.publishCommentModel,
  178 + operationButtonList: this.operationButtonList,
  179 + })
  180 + }
178 } 181 }
179 182
180 } 183 }
@@ -224,8 +227,11 @@ export struct ImageAndTextPageComponent { @@ -224,8 +227,11 @@ export struct ImageAndTextPageComponent {
224 this.publishCommentModel.keyArticle = String(this.contentDetailData[0]?.keyArticle) 227 this.publishCommentModel.keyArticle = String(this.contentDetailData[0]?.keyArticle)
225 this.publishCommentModel.targetType = String(this.contentDetailData[0]?.newsType) 228 this.publishCommentModel.targetType = String(this.contentDetailData[0]?.newsType)
226 } 229 }
227 - if (this.contentDetailData[0]?.audioList?.length && this.contentDetailData[0]?.audioList[0].audioUrl) { 230 + if (this.contentDetailData[0]?.openAudio && this.contentDetailData[0]?.audioList?.length &&
  231 + this.contentDetailData[0]?.audioList[0].audioUrl) {
228 this.operationButtonList = ['comment', 'collect', 'listen', 'share'] 232 this.operationButtonList = ['comment', 'collect', 'listen', 'share']
  233 + } else {
  234 + this.operationButtonList = ['comment', 'collect', 'share']
229 } 235 }
230 } 236 }
231 } 237 }