| | |
| | | <div |
| | | v-for="item in videoData" |
| | | :key="item.id" |
| | | style="position: relative" |
| | | style="position: relative;height:350px" |
| | | > |
| | | <div class="video-title">{{ item.name }}{{ item.community }}</div> |
| | | |
| | |
| | | .catch((err) => this.$message.error(err)); |
| | | }, |
| | | loadVideo(item) { |
| | | if (item.platResourceId) { |
| | | if (item.code) { |
| | | if (Hls.isSupported()) { |
| | | var video = document.getElementById(item.id); |
| | | var hls = new Hls(); |
| | | videoPoint.getVideoPointUrl(item.platResourceId).then((res) => { |
| | | videoPoint.getVideoPointUrl(item.code).then((res) => { |
| | | if (res.code === 0) { |
| | | hls.loadSource(res.data); |
| | | hls.attachMedia(video); |