Before Width: | Height: | Size: 4.2 KiB |
@ -0,0 +1,99 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
const API = {
|
||||||
|
//获取设备列表
|
||||||
|
getinfoList: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/getVideoList',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// getToken:function(){
|
||||||
|
// return axios({
|
||||||
|
// url:'http://192.168.0.45:20000/api/v1/login?username=admin&password=af7548eedff8e737c0e4b2a669497290&url_token_only=true',
|
||||||
|
// method:'post'
|
||||||
|
// })
|
||||||
|
//},
|
||||||
|
//实时直播
|
||||||
|
liveStart: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/stream/start',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//结束直播
|
||||||
|
liveStop: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/stream/stop',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//云台控制
|
||||||
|
cloudControl: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/getCloudControl',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//焦点光圈
|
||||||
|
fiControl: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/getFiControl',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//语音喊话
|
||||||
|
getTalk: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/getTalk',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//开始回放
|
||||||
|
playbackStart: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/playback/start',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//结束回放
|
||||||
|
playbackStop: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/playback/stop',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//回放控制
|
||||||
|
playbackControl: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/playback/control',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//更新监控设备状态
|
||||||
|
deviceChannellist: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/video/control/device/channellist',
|
||||||
|
method: 'post',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//获取字典表
|
||||||
|
getDictList: function (params) {
|
||||||
|
return request({
|
||||||
|
url: '/gatherCommon/dict/list',
|
||||||
|
method: 'get',
|
||||||
|
params
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
export default API
|
After Width: | Height: | Size: 16 KiB |
After Width: | Height: | Size: 22 KiB |
After Width: | Height: | Size: 277 B |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 377 B |
After Width: | Height: | Size: 30 KiB |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 532 B |
After Width: | Height: | Size: 530 B |
After Width: | Height: | Size: 951 B |
After Width: | Height: | Size: 530 B |
After Width: | Height: | Size: 951 B |
After Width: | Height: | Size: 659 B |
After Width: | Height: | Size: 611 B |
After Width: | Height: | Size: 577 B |
After Width: | Height: | Size: 3.6 KiB |
After Width: | Height: | Size: 92 KiB |
After Width: | Height: | Size: 365 B |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 609 B |
After Width: | Height: | Size: 2.3 KiB |
After Width: | Height: | Size: 2.3 KiB |
After Width: | Height: | Size: 743 B |
After Width: | Height: | Size: 548 B |
After Width: | Height: | Size: 701 B |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 2.2 KiB |
After Width: | Height: | Size: 90 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 2.2 KiB |
After Width: | Height: | Size: 90 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 1.7 KiB |
After Width: | Height: | Size: 627 B |
After Width: | Height: | Size: 2.2 KiB |
After Width: | Height: | Size: 90 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 3.4 KiB |
After Width: | Height: | Size: 4.4 KiB |
After Width: | Height: | Size: 165 KiB |
After Width: | Height: | Size: 3.2 KiB |
After Width: | Height: | Size: 251 B |
After Width: | Height: | Size: 238 B |
After Width: | Height: | Size: 267 B |
After Width: | Height: | Size: 240 KiB |
After Width: | Height: | Size: 3.3 KiB |
After Width: | Height: | Size: 9.2 KiB |
After Width: | Height: | Size: 4.1 KiB |
After Width: | Height: | Size: 488 KiB |
After Width: | Height: | Size: 55 KiB |
After Width: | Height: | Size: 9.9 KiB |
After Width: | Height: | Size: 4.2 KiB |
After Width: | Height: | Size: 740 B |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 802 B |
After Width: | Height: | Size: 562 B |
After Width: | Height: | Size: 1.5 KiB |
@ -0,0 +1,124 @@
|
|||||||
|
<template>
|
||||||
|
<div class="player">
|
||||||
|
<!-- <button @click="closeLive()" class="closeLive" v-if="button"></button> -->
|
||||||
|
<LivePlayer :id='"A" + video.index' :videoUrl="video.url" fluent :autoplay="true" :loading="true" live stretch
|
||||||
|
:controls="control" @error="playError">
|
||||||
|
</LivePlayer>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
// import API from "@/api/monitor";
|
||||||
|
// import axios from 'axios'
|
||||||
|
import LivePlayer from '@liveqing/liveplayer'
|
||||||
|
export default {
|
||||||
|
name: "playVideo",
|
||||||
|
components: {
|
||||||
|
LivePlayer
|
||||||
|
},
|
||||||
|
props: {
|
||||||
|
video: {
|
||||||
|
url: "",
|
||||||
|
index: 0,
|
||||||
|
list: {},
|
||||||
|
},
|
||||||
|
control: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false
|
||||||
|
},
|
||||||
|
button: {
|
||||||
|
type: Boolean,
|
||||||
|
default: true
|
||||||
|
},
|
||||||
|
},
|
||||||
|
data() { return { loading: true } },
|
||||||
|
mounted() {
|
||||||
|
this.initVideoPlayer();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
initVideoPlayer() {
|
||||||
|
|
||||||
|
},
|
||||||
|
// closeLive() {
|
||||||
|
// API.liveStop({ villageCode: this.video.list.villageCode, gbsNvrNo: this.video.list.gbsNvrNo, gbsChannelNo: this.video.list.gbsChannelNo })
|
||||||
|
// .then((res) => {
|
||||||
|
// new axios({
|
||||||
|
// url: res.data,
|
||||||
|
// method: 'get'
|
||||||
|
// }).then(() => {
|
||||||
|
// this.$emit("liveClose")
|
||||||
|
|
||||||
|
|
||||||
|
// })
|
||||||
|
// })
|
||||||
|
// },
|
||||||
|
playError(val) {
|
||||||
|
console.log(val, '播放出错回调');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style scoped lang="less">
|
||||||
|
.player {
|
||||||
|
background-color: rgba(0, 0, 0, 0);
|
||||||
|
margin: 0 auto;
|
||||||
|
|
||||||
|
color: white;
|
||||||
|
text-align: center;
|
||||||
|
|
||||||
|
.closeLive {
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
position: absolute;
|
||||||
|
background-color: #fff;
|
||||||
|
background: url("~@/assets/companyFile/常态.png") no-repeat;
|
||||||
|
background-size: 100% 100%;
|
||||||
|
top: 30px;
|
||||||
|
right: 30px;
|
||||||
|
z-index: 11;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
#A5 {
|
||||||
|
width: 85.4%;
|
||||||
|
height: 100%;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.video-js .vjs-tech {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
object-position: center;
|
||||||
|
/* object-fit: cover; */
|
||||||
|
}
|
||||||
|
|
||||||
|
.A1-dimensions {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.A2-dimensions {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.A3-dimensions {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.A4-dimensions {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.A5-dimensions {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
</style>
|
@ -0,0 +1,26 @@
|
|||||||
|
const CopyWebpackPlugin = require('copy-webpack-plugin');
|
||||||
|
module.exports = {
|
||||||
|
publicPath: process.env.NODE_ENV === 'production'
|
||||||
|
? '/production-sub-path/'
|
||||||
|
: '/',
|
||||||
|
configureWebpack: {
|
||||||
|
plugins: [
|
||||||
|
new CopyWebpackPlugin([
|
||||||
|
{ from: 'node_modules/@liveqing/liveplayer/dist/component/crossdomain.xml' },
|
||||||
|
{ from: 'node_modules/@liveqing/liveplayer/dist/component/liveplayer.swf' },
|
||||||
|
{ from: 'node_modules/@liveqing/liveplayer/dist/component/liveplayer-lib.min.js', to: 'js/' },
|
||||||
|
// {
|
||||||
|
// patterns: [{
|
||||||
|
// from: './public/static', to: 'static'
|
||||||
|
// }]
|
||||||
|
// }
|
||||||
|
])
|
||||||
|
],
|
||||||
|
// externals: {
|
||||||
|
// 'BMap': 'BMap',
|
||||||
|
// 'BMap_Symbol_SHAPE_POINT': 'BMap_Symbol_SHAPE_POINT'
|
||||||
|
// }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|