视频对接
This commit is contained in:
parent
0ba396e9d3
commit
05be0ae3fb
|
@ -373,7 +373,7 @@
|
|||
import detailsPageconetentTree from '@/views/home/detailsPageconetentTree.vue'
|
||||
import searchResultList from '@/views/home/components/searchResultList.vue'
|
||||
import KnowledgeBase from '@/views/home/components/KnowledgeBase.vue'
|
||||
import VideoSurveillance from '@/views/home/videoSurveillance'
|
||||
// import VideoSurveillance from '@/views/home/videoSurveillance'
|
||||
export default defineComponent({
|
||||
setup() {
|
||||
// const store = useStore()
|
||||
|
@ -1008,60 +1008,11 @@
|
|||
pageNo: paramsGetResources.pageNum,
|
||||
pageSize: paramsGetResources.pageSize
|
||||
}
|
||||
resourceTotal.value = 10
|
||||
resourceList.data = [
|
||||
{
|
||||
"id": "689299957948436480",//摄像头id
|
||||
"cameraIndexCode": "37021100001316660963",//监控点编号
|
||||
"cameraSerial": null,//海康平台摄像头编码
|
||||
"gbIndexCode": "37021100001316660963",//监控点国标编号
|
||||
"name": "216省道与星海滩路(桥底南)",//监控点名称
|
||||
"deviceIndexCode": "",//所属设备编号
|
||||
"longitude": "120.05622780039626",//经度(WGS84坐标系)
|
||||
"latitude": "35.9411893638582",//纬度(WGS84坐标系)
|
||||
"altitude": "",//海拔高度(WGS84坐标系,单位:米)
|
||||
"pixel": "1",//摄像机像素(1-普通像素,2-130万高清,3-200万高清,4-300万高清)
|
||||
"cameraType": "2",//监控点类型(0-枪机,1-半球,2-快球,3-带云台枪机)
|
||||
"cameraTypeName": "Fast Ball Camera",//监控点类型说明
|
||||
"installPlace": "",//安装位置
|
||||
"matrixCode": "",//矩阵编号
|
||||
"chanNum": null,//通道号
|
||||
"viewshed": "",//可视域相关(JSON格式),该字段具体使用方式参考【监控点可视域字段说明】。
|
||||
"capabilitySet": "@vss@",//能力集
|
||||
"capabilitySetName": "@Video capability@",//能力集说明
|
||||
"intelligentSet": "",//智能分析能力集
|
||||
"intelligentSetName": "",//智能分析能力集说明
|
||||
"recordLocation": "0",//录像存储位置(0-中心存储,1-设备存储)
|
||||
"recordLocationName": "Central storage",//录像存储位置说明
|
||||
"ptzController": null,//云台控制(1-DVR,2-模拟矩阵,3-MU4000,4-NC600)
|
||||
"ptzControllerName": "",//云台控制说明
|
||||
"deviceResourceType": "",//所属设备类型
|
||||
"deviceResourceTypeName": "",//所属设备类型说明
|
||||
"channelType": "analog",//通道子类型
|
||||
"channelTypeName": "Analog channel",//通道子类型说明
|
||||
"transType": "1",//传输协议(0-UDP,1-TCP)
|
||||
"transTypeName": "TCP",//传输协议类型说明
|
||||
"updateTime": "2022-05-18T02:04:24.166+08:00",//监控点更新时间(ISO8601格式yyyy-MM-dd'T'HH:mm:ss.SSSzzz)
|
||||
"unitIndexCode": "37021100001310001004",//所属组织编号
|
||||
"treatyType": "",//接入协议
|
||||
"treatyTypeName": "",//接入协议类型说明
|
||||
"createTime": null,//监控点创建时间(ISO8601格式yyyy-MM-dd'T'HH:mm:ss.SSSzzz)
|
||||
"status": "1",// 在线状态(0-不在线,1-在线)
|
||||
"statusName": "Online",//状态说明
|
||||
"locationLong": 120.05622780039626,//地理坐标经度(计算使用)
|
||||
"locationLat": 35.9411893638582,//地理坐标纬度(计算使用)
|
||||
"delFlag": 0,//删除标记(0:有效;1:删除)
|
||||
"createdBy": null,//创建人code
|
||||
"createdTime": "2022-05-25 12:38:47",//创建时间
|
||||
"updatedBy": null,//修改人code
|
||||
"updatedTime": "2022-06-08 17:05:26"//修改时间
|
||||
}
|
||||
]
|
||||
// getVideoList(params).then((res) => {
|
||||
// // 赋值
|
||||
// resourceTotal.value = res.data.data.total
|
||||
// resourceList.data = res.data.data.list
|
||||
// })
|
||||
getVideoList(params).then((res) => {
|
||||
// 赋值
|
||||
resourceTotal.value = res.data.data.total
|
||||
resourceList.data = res.data.data.list
|
||||
})
|
||||
} else if (Cardsname.value === '数据资源') {
|
||||
resourceTotal.value = resourceData.value.data.total || ''
|
||||
getShoppingCartList(resourceData.value.data.records)
|
||||
|
@ -1311,7 +1262,7 @@
|
|||
DownOutlined,
|
||||
KnowledgeBase,
|
||||
// VideoCameraOutlined,
|
||||
VideoSurveillance,
|
||||
// VideoSurveillance,
|
||||
},
|
||||
beforeUnmount() {
|
||||
mybus.off('selectCardsitem')
|
||||
|
|
|
@ -153,7 +153,11 @@
|
|||
免费试用
|
||||
</a-button>
|
||||
</div>
|
||||
<a-button type="primary" v-if="item.cameraIndexCode" @click="openVideo( item)">
|
||||
<a-button
|
||||
type="primary"
|
||||
v-if="item.cameraIndexCode"
|
||||
@click="openVideo(item)"
|
||||
>
|
||||
视频预览
|
||||
</a-button>
|
||||
<a-button type="primary" v-else @click="toView('details', item)">
|
||||
|
@ -169,11 +173,24 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<a-modal
|
||||
v-model:visible="visible"
|
||||
title="视频预览"
|
||||
:width="750"
|
||||
destroyOnClose
|
||||
>
|
||||
<template #footer></template>
|
||||
<div style="width: 100%; display: flex; justify-content: center">
|
||||
<div style="width: 100%; height: 100%">
|
||||
<vue3VideoPlay v-bind="options" />
|
||||
</div>
|
||||
</div>
|
||||
</a-modal>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { ref } from 'vue'
|
||||
import { ref, reactive } from 'vue'
|
||||
import { message } from 'ant-design-vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { getUser, sgcInsert } from '@/api/home'
|
||||
|
@ -285,6 +302,33 @@
|
|||
setup(props) {
|
||||
let shoppingKey = ref(1)
|
||||
let videoUrl = ref('')
|
||||
let visible = ref(false)
|
||||
const options = reactive({
|
||||
width: '700px', //播放器宽度
|
||||
height: '400px', //播放器高度
|
||||
color: '#409eff', //主题色
|
||||
title: '', //视频名称
|
||||
src: '', //视频源
|
||||
muted: false, //静音
|
||||
webFullScreen: false,
|
||||
speedRate: ['0.75', '1.0', '1.25', '1.5', '2.0'], //播放倍速
|
||||
autoPlay: true, //自动播放
|
||||
loop: false, //循环播放
|
||||
mirror: false, //镜像画面
|
||||
ligthOff: false, //关灯模式
|
||||
volume: 0.3, //默认音量大小
|
||||
control: true, //是否显示控制
|
||||
controlBtns: [
|
||||
'audioTrack',
|
||||
'quality',
|
||||
'speedRate',
|
||||
'volume',
|
||||
'setting',
|
||||
'pip',
|
||||
'pageFullScreen',
|
||||
'fullScreen',
|
||||
], //显示所有按钮,
|
||||
})
|
||||
// 购物车id列表
|
||||
const selList = ref([
|
||||
{ name: '发布时间', value: 'tdr.create_date' },
|
||||
|
@ -414,13 +458,18 @@
|
|||
}
|
||||
getHls(param).then((res) => {
|
||||
console.log('获取视频地址===============>', res)
|
||||
videoUrl.value = res.data.data
|
||||
// videoUrl.value = res.data.data
|
||||
options.value.src = res.data.data
|
||||
visible.value = true
|
||||
})
|
||||
}
|
||||
mybus.on('chongzhi', () => {
|
||||
selData.value = 'total'
|
||||
})
|
||||
return {
|
||||
visible,
|
||||
videoUrl,
|
||||
options,
|
||||
onSearch,
|
||||
resultList,
|
||||
toView,
|
||||
|
|
|
@ -17,16 +17,26 @@
|
|||
</div>
|
||||
<div class="item">
|
||||
<div class="zj">组件服务</div>
|
||||
<div class="name" v-for="(item, index) in zjList" :key="item.id" :class="index == 4 ? 'name-last' : ''"
|
||||
@click="selectOne(item.id)">
|
||||
<div
|
||||
class="name"
|
||||
v-for="(item, index) in zjList"
|
||||
:key="item.id"
|
||||
:class="index == 4 ? 'name-last' : ''"
|
||||
@click="selectOne(item.id)"
|
||||
>
|
||||
{{ index + 1 }}-{{ item.name }}
|
||||
</div>
|
||||
<div class="btn" @click="jumpPage('组件服务')">查看更多</div>
|
||||
</div>
|
||||
<div class="item">
|
||||
<div class="yy">应用资源</div>
|
||||
<div class="name" v-for="(item, index) in yyList" :key="item.id" :class="index == 4 ? 'name-last' : ''"
|
||||
@click="selectOne(item.id)">
|
||||
<div
|
||||
class="name"
|
||||
v-for="(item, index) in yyList"
|
||||
:key="item.id"
|
||||
:class="index == 4 ? 'name-last' : ''"
|
||||
@click="selectOne(item.id)"
|
||||
>
|
||||
{{ index + 1 }}-{{ item.name }}
|
||||
</div>
|
||||
<div class="btn" @click="jumpPage('应用资源')">查看更多</div>
|
||||
|
@ -68,16 +78,16 @@
|
|||
</div>
|
||||
</template>
|
||||
<script setup>
|
||||
import { pageWithAttrs } from '@/api/home.js'
|
||||
import { ref } from 'vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { useStore } from 'vuex'
|
||||
const store = useStore()
|
||||
const router = useRouter()
|
||||
const zjList = ref([])
|
||||
const yyList = ref([])
|
||||
// const jcList = ref([])
|
||||
const paramsGetResources = {
|
||||
import { pageWithAttrs } from '@/api/home.js'
|
||||
import { ref } from 'vue'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { useStore } from 'vuex'
|
||||
const store = useStore()
|
||||
const router = useRouter()
|
||||
const zjList = ref([])
|
||||
const yyList = ref([])
|
||||
// const jcList = ref([])
|
||||
const paramsGetResources = {
|
||||
districtId: '',
|
||||
pageNum: 1,
|
||||
pageSize: 5,
|
||||
|
@ -86,19 +96,19 @@ const paramsGetResources = {
|
|||
infoList: [],
|
||||
orderField: 'total', // total 综合 visits 访问量 applyCount 申请量 score 评分 collectCount 收藏量
|
||||
orderType: 'DESC', // ASC 升序 DESC 降序
|
||||
}
|
||||
const getAppResources = (type, obj) => {
|
||||
}
|
||||
const getAppResources = (type, obj) => {
|
||||
paramsGetResources.type = type
|
||||
pageWithAttrs(paramsGetResources).then((res) => {
|
||||
console.log('查询列表============>', res.data.data.records)
|
||||
obj.value = res.data.data.records
|
||||
})
|
||||
}
|
||||
getAppResources('组件服务', zjList)
|
||||
getAppResources('应用资源', yyList)
|
||||
// getAppResources('基础设施', jcList)
|
||||
}
|
||||
getAppResources('组件服务', zjList)
|
||||
getAppResources('应用资源', yyList)
|
||||
// getAppResources('基础设施', jcList)
|
||||
|
||||
function jumpPage(type) {
|
||||
function jumpPage(type) {
|
||||
// 点击内存入store
|
||||
store.commit('home/selectCardsData', {
|
||||
selectCardsnum: type,
|
||||
|
@ -114,8 +124,8 @@ function jumpPage(type) {
|
|||
select: type,
|
||||
},
|
||||
})
|
||||
}
|
||||
const selectOne = (id) => {
|
||||
}
|
||||
const selectOne = (id) => {
|
||||
console.log('点击===============》', id)
|
||||
router.push({
|
||||
path: '/details',
|
||||
|
@ -123,10 +133,10 @@ const selectOne = (id) => {
|
|||
id: id,
|
||||
},
|
||||
})
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.capability-convergence {
|
||||
.capability-convergence {
|
||||
height: 7.2rem;
|
||||
background: url('~@/assets/newHome/Convergence-bg.png') no-repeat;
|
||||
background-size: 100%;
|
||||
|
@ -246,5 +256,5 @@ const selectOne = (id) => {
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
Loading…
Reference in New Issue