|
@@ -1,7 +1,10 @@
|
|
|
<template>
|
|
|
- <view class="container global-audio-box" v-if="showAudioPop">
|
|
|
+ <!-- v-if="showAudioPop" -->
|
|
|
+ <view class="container global-audio-box">
|
|
|
<view class="bg-overlay" @click="isShowMaskHandler"></view>
|
|
|
+
|
|
|
<view class="audio-box">
|
|
|
+ <view @click="showTabulation = true"> 最后不要忘了删除 </view>
|
|
|
<view class="activity-title">
|
|
|
{{ activityTitle }}
|
|
|
<view class="icon-cross" @click.stop="isShowMaskHandler">
|
|
@@ -9,7 +12,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="audio-card">
|
|
|
- <view class="card-title text_oneLine">
|
|
|
+ <view class="card-title text_oneLine" @click="showTabulation = true">
|
|
|
{{ title }}
|
|
|
</view>
|
|
|
<view class="slider-paly">
|
|
@@ -47,6 +50,14 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
+ <van-popup :show="showTabulation" closeable position="bottom" round custom-style="height: 50%;" @close="onCloseHandler">
|
|
|
+ <view>
|
|
|
+ <view class="global_title">播放列表</view>
|
|
|
+ <view v-for="item in playlistData" :key="item.indexId" @click="palyHandler(item)">
|
|
|
+ {{ item.Name }}
|
|
|
+ </view>
|
|
|
+ </view>
|
|
|
+ </van-popup>
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
@@ -86,6 +97,7 @@ export default {
|
|
|
{ name: "2倍", value: 2 },
|
|
|
],
|
|
|
isRecord: true, //是否记录播放
|
|
|
+ showTabulation: true,
|
|
|
};
|
|
|
},
|
|
|
computed: {
|
|
@@ -108,6 +120,9 @@ export default {
|
|
|
isEnded() {
|
|
|
return this.$store.state.audioBg.isAudioEnded;
|
|
|
},
|
|
|
+ playlistData() {
|
|
|
+ return this.$store.state.audioJoinPlaylist.playlist;
|
|
|
+ },
|
|
|
},
|
|
|
watch: {
|
|
|
audioInit: {
|
|
@@ -287,6 +302,29 @@ export default {
|
|
|
touchstartHandler() {
|
|
|
this.$store.commit("audioBg/setSlide", true);
|
|
|
},
|
|
|
+ // 关闭播放列表
|
|
|
+ onCloseHandler() {
|
|
|
+ this.showTabulation = false;
|
|
|
+ },
|
|
|
+ palyHandler(item) {
|
|
|
+ console.log(item,this.$store.state.audioBg.indexId);
|
|
|
+ if (this.$store.state.audioBg.indexId == item.indexId) {
|
|
|
+ if (this.globalBgAudioManager.paused) {
|
|
|
+ this.globalBgAudioManager.play();
|
|
|
+ } else {
|
|
|
+ this.globalBgAudioManager.pause();
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ console.log(112233);
|
|
|
+ let VoiceList = {
|
|
|
+ Url: item.Url,
|
|
|
+ Name: item.Name,
|
|
|
+ PlaySeconds: item.PlaySeconds,
|
|
|
+ };
|
|
|
+ this.$store.commit("audioBg/addAudio", { list: VoiceList, indexId: item.indexId, activityTitle: item.activityTitle });
|
|
|
+ this.init()
|
|
|
+ }
|
|
|
+ },
|
|
|
},
|
|
|
};
|
|
|
</script>
|