|
@@ -101,7 +101,14 @@ export async function getVideoSrc(code: string) {
|
|
|
}
|
|
|
closeVideo();
|
|
|
curIndexCode = code;
|
|
|
- return await getVideoUrl(curIndexCode, token).then(res => res.data.https_fmp4).catch(() => null)
|
|
|
+ return await getVideoUrl(curIndexCode, token)
|
|
|
+ .then(res => {
|
|
|
+ let url = res.data.fmp4;
|
|
|
+ // 修改url(解决跨域问题)
|
|
|
+ url = url.replace('http://10.8.4.147:8800', '/videourl_api');
|
|
|
+ return url;
|
|
|
+ })
|
|
|
+ .catch(() => null)
|
|
|
}
|
|
|
|
|
|
export function closeVideo(videoNm = curIndexCode, authorization = token) {
|