wangliang_wd

feat:优化早晚报语音播放问题

@@ -147,6 +147,21 @@ export struct MorningEveningPaperComponent { @@ -147,6 +147,21 @@ export struct MorningEveningPaperComponent {
147 console.log(TAG, 'this.currentStatus', val) 147 console.log(TAG, 'this.currentStatus', val)
148 this.currentStatus = val 148 this.currentStatus = val
149 149
  150 + const newsInfo = this.AudioSuspension.newsInfo();
  151 + if (newsInfo) {
  152 + const parsedInfo: newsInfo = JSON.parse(newsInfo);
  153 + const url = parsedInfo.url;
  154 + let hasURl = false
  155 + this.compInfoBean?.compList[0].audioDataList.forEach((item,index)=>{
  156 + if (item.audioUrl === url) {
  157 + hasURl = true
  158 + }
  159 + })
  160 +
  161 + ///如果当前播放的不是早晚报列表的,则不需要继续播放
  162 + if (!hasURl) return
  163 + }
  164 +
150 if (this.currentStatus === 5) { 165 if (this.currentStatus === 5) {
151 let audioIndex = 0 166 let audioIndex = 0
152 this.compInfoBean?.compList[0].audioDataList.forEach((item,index)=>{ 167 this.compInfoBean?.compList[0].audioDataList.forEach((item,index)=>{