mirror of
https://github.com/cuiocean/ZY-Player.git
synced 2026-05-05 19:03:23 +08:00
fix:直播时上下切换频道时的bug
This commit is contained in:
@@ -673,7 +673,7 @@ export default {
|
||||
},
|
||||
prevEvent () {
|
||||
if (this.video.iptv) {
|
||||
var index = this.channelList.findIndex(obj => obj.prefer === this.video.iptv.id)
|
||||
var index = this.channelList.findIndex(obj => obj.id === this.video.iptv.channelID)
|
||||
if (index >= 1) {
|
||||
var channel = this.channelList[index - 1]
|
||||
this.playChannel(channel)
|
||||
@@ -691,7 +691,7 @@ export default {
|
||||
},
|
||||
nextEvent () {
|
||||
if (this.video.iptv) {
|
||||
var index = this.channelList.findIndex(obj => obj.prefer === this.video.iptv.id)
|
||||
var index = this.channelList.findIndex(obj => obj.id === this.video.iptv.channelID)
|
||||
if (index < (this.channelList.length - 1)) {
|
||||
var channel = this.channelList[index + 1]
|
||||
this.playChannel(channel)
|
||||
|
||||
Reference in New Issue
Block a user