|
@ -105,7 +105,6 @@ const VideoPlay = ({ dispatch, actions, |
|
|
const [showTime_, setShowTime] = useState('') |
|
|
const [showTime_, setShowTime] = useState('') |
|
|
const [showTimeSelect, setShowTimeSelect] = useState(false) |
|
|
const [showTimeSelect, setShowTimeSelect] = useState(false) |
|
|
|
|
|
|
|
|
const [playNumber, setPlayNumber] = useState(0) |
|
|
|
|
|
|
|
|
|
|
|
const [hideFullScreenBut, setHideFullScreenBut] = useState(false) |
|
|
const [hideFullScreenBut, setHideFullScreenBut] = useState(false) |
|
|
|
|
|
|
|
@ -123,6 +122,7 @@ const VideoPlay = ({ dispatch, actions, |
|
|
const yingshiPlayer = useRef(null) |
|
|
const yingshiPlayer = useRef(null) |
|
|
const jessibucas = useRef(null) |
|
|
const jessibucas = useRef(null) |
|
|
const flvPlayer = useRef() |
|
|
const flvPlayer = useRef() |
|
|
|
|
|
const playNumber = useRef(0) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -476,12 +476,12 @@ const VideoPlay = ({ dispatch, actions, |
|
|
}, |
|
|
}, |
|
|
handleError: (e) => { //播放失败 |
|
|
handleError: (e) => { //播放失败 |
|
|
console.log(e, '播放失败'); |
|
|
console.log(e, '播放失败'); |
|
|
if (playNumber > 4) { |
|
|
if (playNumber.current > 4) { |
|
|
setNumbers(e.retcode) |
|
|
setNumbers(e.retcode) |
|
|
videoAfter = new moment(); //验证后时间 |
|
|
videoAfter = new moment(); //验证后时间 |
|
|
setDisappear(true) |
|
|
setDisappear(true) |
|
|
} else { |
|
|
} else { |
|
|
setPlayNumber(playNumber + 1) |
|
|
playNumber.current = playNumber.current + 1 |
|
|
yingshiPlayer.current.stop().then(() => { |
|
|
yingshiPlayer.current.stop().then(() => { |
|
|
yingshiPlayer.current.play({ url: videoObj.playUrlSd }) |
|
|
yingshiPlayer.current.play({ url: videoObj.playUrlSd }) |
|
|
}) |
|
|
}) |
|
|