|
|
@@ -22,14 +22,14 @@
|
|
|
style="margin-top: 20px;"
|
|
|
:columns="recordColumns"
|
|
|
:data-source="state.recordDataSource"
|
|
|
- :loading="state.loading"
|
|
|
+ :loading="state.recordLoading"
|
|
|
:pagination="false"
|
|
|
>
|
|
|
<template #bodyCell="{column, record}" >
|
|
|
<template v-if="column.key === 'action'" >
|
|
|
<a-space>
|
|
|
<!-- <a @click="openModal(record)" >详情</a> -->
|
|
|
- <a @click="recordPlay(record)" >录制播放</a>
|
|
|
+ <a @click="recordPlay(record)" >flv播放</a>
|
|
|
</a-space>
|
|
|
</template>
|
|
|
</template>
|
|
|
@@ -100,7 +100,7 @@
|
|
|
</template>
|
|
|
<script lang="ts" setup >
|
|
|
import { RtsController } from '@/controller/rts'
|
|
|
-import { onMounted, reactive } from 'vue'
|
|
|
+import { onMounted, reactive, watch } from 'vue'
|
|
|
import { Form, message } from 'ant-design-vue'
|
|
|
import { VideoPlayerTsx } from '@/components/VideoPlayer/index'
|
|
|
import { getRecording } from '@/api/rts/stream'
|
|
|
@@ -160,6 +160,7 @@ const recordState = reactive({
|
|
|
|
|
|
const state = reactive({
|
|
|
loading: false,
|
|
|
+ recordLoading: false,
|
|
|
visible: false,
|
|
|
recordVisible: false,
|
|
|
recordingDataSource: [],
|
|
|
@@ -171,8 +172,13 @@ const state = reactive({
|
|
|
videoUrl: ''
|
|
|
})
|
|
|
|
|
|
+watch(
|
|
|
+ () => recordState.type,
|
|
|
+ () => getRecordList()
|
|
|
+)
|
|
|
+
|
|
|
const stopRcord = async (record) => {
|
|
|
- await RtsController.stopRecord(record.id)
|
|
|
+ await RtsController.stopRecord(record.ID)
|
|
|
getRecording()
|
|
|
}
|
|
|
|
|
|
@@ -206,7 +212,9 @@ const getStreamList = async () => {
|
|
|
}
|
|
|
|
|
|
const getRecordList = async () => {
|
|
|
+ state.recordLoading = true
|
|
|
const { data } = await RtsController.listRecord(state.type)
|
|
|
+ state.recordLoading = false
|
|
|
state.recordDataSource = data
|
|
|
}
|
|
|
|