Commit 42d67fb1 by crushh

update: 音乐播放完成后关闭

parent 689dfdec
......@@ -113,6 +113,7 @@ import Linktools from '@/components/linktools-fulls/index.vue';
import audioUpload from '../common/audio-upload.vue';
const maxTimeRange = 180 * 24 * 60 * 60 * 1000; // 6个月
const music = new Audio();
export default {
data() {
const adsImageUrlVal = (rule, value, callback) => {
......@@ -184,6 +185,12 @@ export default {
default: () => {}
}
},
mounted() {
music.addEventListener('ended', () => {
music.currentTime = 0;
this.isPlay = false;
});
},
components: {
dmUploadAvatar,
dmUploadImg,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment