Showing
4 changed files
with
4 additions
and
43 deletions
@@ -19,7 +19,6 @@ enum CameraManagerApi { | @@ -19,7 +19,6 @@ enum CameraManagerApi { | ||
19 | STREAMING_POST_URL = '/video/platform', | 19 | STREAMING_POST_URL = '/video/platform', |
20 | STREAMING_DELETE_URL = '/video/platform', | 20 | STREAMING_DELETE_URL = '/video/platform', |
21 | STREAMING_PLAY_GET_URL = '/video/url', | 21 | STREAMING_PLAY_GET_URL = '/video/url', |
22 | - OUT_VIDEO = '/video/outVideo', | ||
23 | } | 22 | } |
24 | 23 | ||
25 | export const cameraPage = (params: CameraQueryParam) => { | 24 | export const cameraPage = (params: CameraQueryParam) => { |
@@ -128,13 +127,3 @@ export const controlling = (params: any) => { | @@ -128,13 +127,3 @@ export const controlling = (params: any) => { | ||
128 | params, | 127 | params, |
129 | }); | 128 | }); |
130 | }; | 129 | }; |
131 | - | ||
132 | -/** | ||
133 | - * @description 退出视频流播放 | ||
134 | - * @param entityId | ||
135 | - */ | ||
136 | -export const outVideo = (entityId) => { | ||
137 | - return defHttp.get({ | ||
138 | - url: `${CameraManagerApi.OUT_VIDEO}/${entityId}`, | ||
139 | - }); | ||
140 | -}; |
@@ -29,12 +29,7 @@ | @@ -29,12 +29,7 @@ | ||
29 | import type { StreamingManageRecord, CameraModel } from '/@/api/camera/model/cameraModel'; | 29 | import type { StreamingManageRecord, CameraModel } from '/@/api/camera/model/cameraModel'; |
30 | import { BasicVideoPlay, getVideoTypeByUrl } from '/@/components/Video'; | 30 | import { BasicVideoPlay, getVideoTypeByUrl } from '/@/components/Video'; |
31 | import { AccessMode } from './config.data'; | 31 | import { AccessMode } from './config.data'; |
32 | - import { | ||
33 | - closeFlvPlay, | ||
34 | - getFlvPlayUrl, | ||
35 | - getStreamingPlayUrl, | ||
36 | - outVideo, | ||
37 | - } from '/@/api/camera/cameraManager'; | 32 | + import { closeFlvPlay, getFlvPlayUrl, getStreamingPlayUrl } from '/@/api/camera/cameraManager'; |
38 | import { isRtspProtocol } from '/@/components/Video/src/utils'; | 33 | import { isRtspProtocol } from '/@/components/Video/src/utils'; |
39 | import { VideoJsPlayerOptions } from 'video.js'; | 34 | import { VideoJsPlayerOptions } from 'video.js'; |
40 | import { useFingerprint } from '/@/utils/useFingerprint'; | 35 | import { useFingerprint } from '/@/utils/useFingerprint'; |
@@ -102,7 +97,6 @@ | @@ -102,7 +97,6 @@ | ||
102 | const handleCancel = () => { | 97 | const handleCancel = () => { |
103 | showVideo.value = false; | 98 | showVideo.value = false; |
104 | withToken.value = false; | 99 | withToken.value = false; |
105 | - outVideo(videoId.value); | ||
106 | }; | 100 | }; |
107 | </script> | 101 | </script> |
108 | 102 |
1 | <script setup lang="ts"> | 1 | <script setup lang="ts"> |
2 | import { PageWrapper } from '/@/components/Page'; | 2 | import { PageWrapper } from '/@/components/Page'; |
3 | import OrganizationIdTree from '../../common/organizationIdTree/src/OrganizationIdTree.vue'; | 3 | import OrganizationIdTree from '../../common/organizationIdTree/src/OrganizationIdTree.vue'; |
4 | - import { onMounted, onUnmounted, reactive, Ref, ref, unref, watch } from 'vue'; | 4 | + import { onMounted, reactive, Ref, ref, unref, watch } from 'vue'; |
5 | import { Spin, Button, Pagination, Space, List } from 'ant-design-vue'; | 5 | import { Spin, Button, Pagination, Space, List } from 'ant-design-vue'; |
6 | import { cameraPage, closeFlvPlay, getFlvPlayUrl } from '/@/api/camera/cameraManager'; | 6 | import { cameraPage, closeFlvPlay, getFlvPlayUrl } from '/@/api/camera/cameraManager'; |
7 | import { CameraRecord } from '/@/api/camera/model/cameraModel'; | 7 | import { CameraRecord } from '/@/api/camera/model/cameraModel'; |
@@ -10,7 +10,7 @@ | @@ -10,7 +10,7 @@ | ||
10 | import { useDrawer } from '/@/components/Drawer'; | 10 | import { useDrawer } from '/@/components/Drawer'; |
11 | import { AccessMode, CameraPermission, PageMode } from './config.data'; | 11 | import { AccessMode, CameraPermission, PageMode } from './config.data'; |
12 | import SvgIcon from '/@/components/Icon/src/SvgIcon.vue'; | 12 | import SvgIcon from '/@/components/Icon/src/SvgIcon.vue'; |
13 | - import { getStreamingPlayUrl, outVideo } from '/@/api/camera/cameraManager'; | 13 | + import { getStreamingPlayUrl } from '/@/api/camera/cameraManager'; |
14 | import { buildUUID } from '/@/utils/uuid'; | 14 | import { buildUUID } from '/@/utils/uuid'; |
15 | import { BasicVideoPlay, getVideoTypeByUrl } from '/@/components/Video'; | 15 | import { BasicVideoPlay, getVideoTypeByUrl } from '/@/components/Video'; |
16 | import { VideoJsPlayerOptions } from 'video.js'; | 16 | import { VideoJsPlayerOptions } from 'video.js'; |
@@ -192,25 +192,9 @@ | @@ -192,25 +192,9 @@ | ||
192 | } | 192 | } |
193 | }; | 193 | }; |
194 | 194 | ||
195 | - const handleVideoOut = () => { | ||
196 | - if (unref(cameraList).length) { | ||
197 | - unref(cameraList).forEach((item) => { | ||
198 | - if (item.accessMode === 1) { | ||
199 | - outVideo(item.id); | ||
200 | - } | ||
201 | - }); | ||
202 | - } | ||
203 | - }; | ||
204 | - | ||
205 | onMounted(() => { | 195 | onMounted(() => { |
206 | getCameraList(); | 196 | getCameraList(); |
207 | }); | 197 | }); |
208 | - onUnmounted(() => { | ||
209 | - handleVideoOut(); | ||
210 | - }); | ||
211 | - window.addEventListener('beforeunload', function () { | ||
212 | - handleVideoOut(); | ||
213 | - }); | ||
214 | 198 | ||
215 | const listEl = ref(); | 199 | const listEl = ref(); |
216 | onMounted(() => { | 200 | onMounted(() => { |
@@ -26,12 +26,7 @@ | @@ -26,12 +26,7 @@ | ||
26 | import { BasicModal, useModalInner } from '/@/components/Modal'; | 26 | import { BasicModal, useModalInner } from '/@/components/Modal'; |
27 | import type { StreamingManageRecord, CameraModel } from '/@/api/camera/model/cameraModel'; | 27 | import type { StreamingManageRecord, CameraModel } from '/@/api/camera/model/cameraModel'; |
28 | import { getVideoTypeByUrl } from '/@/components/Video'; | 28 | import { getVideoTypeByUrl } from '/@/components/Video'; |
29 | - import { | ||
30 | - closeFlvPlay, | ||
31 | - getFlvPlayUrl, | ||
32 | - getStreamingPlayUrl, | ||
33 | - outVideo, | ||
34 | - } from '/@/api/camera/cameraManager'; | 29 | + import { closeFlvPlay, getFlvPlayUrl, getStreamingPlayUrl } from '/@/api/camera/cameraManager'; |
35 | import { isRtspProtocol } from '/@/components/Video/src/utils'; | 30 | import { isRtspProtocol } from '/@/components/Video/src/utils'; |
36 | import { VideoJsPlayerOptions } from 'video.js'; | 31 | import { VideoJsPlayerOptions } from 'video.js'; |
37 | import { useFingerprint } from '/@/utils/useFingerprint'; | 32 | import { useFingerprint } from '/@/utils/useFingerprint'; |
@@ -102,7 +97,6 @@ | @@ -102,7 +97,6 @@ | ||
102 | const handleCancel = () => { | 97 | const handleCancel = () => { |
103 | showVideo.value = false; | 98 | showVideo.value = false; |
104 | withToken.value = false; | 99 | withToken.value = false; |
105 | - outVideo(videoId.value); | ||
106 | }; | 100 | }; |
107 | </script> | 101 | </script> |
108 | 102 |