|
@@ -26,6 +26,7 @@ import { getVideoControlStart } from '/@/api/device/videoChannel'; |
|
@@ -26,6 +26,7 @@ import { getVideoControlStart } from '/@/api/device/videoChannel'; |
26
|
import { StreamType as PlayerStreamType } from '/@/components/Video/src/types';
|
26
|
import { StreamType as PlayerStreamType } from '/@/components/Video/src/types';
|
27
|
import { useGlobSetting } from '/@/hooks/setting';
|
27
|
import { useGlobSetting } from '/@/hooks/setting';
|
28
|
import { BooleanStringEnum } from '/@/enums/toolEnum';
|
28
|
import { BooleanStringEnum } from '/@/enums/toolEnum';
|
|
|
29
|
+import { isBoolean } from '/@/utils/is';
|
29
|
|
30
|
|
30
|
interface FileItem {
|
31
|
interface FileItem {
|
31
|
uid: string;
|
32
|
uid: string;
|
|
@@ -646,7 +647,9 @@ export async function getPlayUrl( |
|
@@ -646,7 +647,9 @@ export async function getPlayUrl( |
646
|
const result = await getVideoControlStart({ channelId: channelNo!, deviceId: deviceId! });
|
647
|
const result = await getVideoControlStart({ channelId: channelNo!, deviceId: deviceId! });
|
647
|
const { securityPolicy } = useGlobSetting();
|
648
|
const { securityPolicy } = useGlobSetting();
|
648
|
return {
|
649
|
return {
|
649
|
- url: securityPolicy === BooleanStringEnum.TRUE ? result.data.https_flv : result.data.flv,
|
650
|
+ url: (isBoolean(securityPolicy) ? securityPolicy : securityPolicy === BooleanStringEnum.TRUE)
|
|
|
651
|
+ ? result.data.https_flv
|
|
|
652
|
+ : result.data.flv,
|
650
|
type: 'flv',
|
653
|
type: 'flv',
|
651
|
};
|
654
|
};
|
652
|
} else {
|
655
|
} else {
|