|
|
@@ -18,6 +18,7 @@
|
|
|
<div class="l-flex--row c-table__header">
|
|
|
<div class="l-flex__auto c-sibling-item">
|
|
|
<button
|
|
|
+ v-if="hasEditPermission"
|
|
|
class="o-button"
|
|
|
@click="addbtn"
|
|
|
>
|
|
|
@@ -60,25 +61,28 @@
|
|
|
class="video"
|
|
|
muted
|
|
|
autoplay
|
|
|
-
|
|
|
:poster="require('@/assets//video-post.png')"
|
|
|
/>
|
|
|
<div
|
|
|
v-show="!video.online"
|
|
|
class="offLine"
|
|
|
- >设备离线</div>
|
|
|
+ >
|
|
|
+ 设备离线
|
|
|
+ </div>
|
|
|
<div class="o-video_buttom l-flex--row">
|
|
|
<div class="l-flex__auto">{{ video.name }}</div>
|
|
|
- <img
|
|
|
- :src="imgUrl.edit"
|
|
|
- class="o-video_edit"
|
|
|
- @click.stop="editbtn(video)"
|
|
|
- >
|
|
|
- <img
|
|
|
- :src="imgUrl.delete"
|
|
|
- class="o-video_delete"
|
|
|
- @click.stop="deletebtn(video)"
|
|
|
- >
|
|
|
+ <template v-if="hasEditPermission">
|
|
|
+ <img
|
|
|
+ class="o-video_edit"
|
|
|
+ :src="imgUrl.edit"
|
|
|
+ @click.stop="editbtn(video)"
|
|
|
+ >
|
|
|
+ <img
|
|
|
+ class="o-video_delete"
|
|
|
+ :src="imgUrl.delete"
|
|
|
+ @click.stop="deletebtn(video)"
|
|
|
+ >
|
|
|
+ </template>
|
|
|
</div>
|
|
|
</div>
|
|
|
</el-col>
|
|
|
@@ -221,12 +225,13 @@
|
|
|
/>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
-
|
|
|
<template #footer>
|
|
|
<button
|
|
|
class="o-button"
|
|
|
@click="add('cameraForm')"
|
|
|
- >确定</button>
|
|
|
+ >
|
|
|
+ 确定
|
|
|
+ </button>
|
|
|
<button
|
|
|
class="o-button cancel"
|
|
|
@click="handleCloseAddDialog('cameraForm')"
|
|
|
@@ -252,6 +257,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
+import { mapGetters } from 'vuex'
|
|
|
import flvjs from 'flv.js'
|
|
|
import {
|
|
|
getCamera,
|
|
|
@@ -261,14 +267,14 @@ import {
|
|
|
getOnline
|
|
|
} from '@/api/camera'
|
|
|
import { createListOptions } from '@/utils'
|
|
|
-import detail from './compoent/detail.vue'
|
|
|
+import Detail from './components/Detail'
|
|
|
|
|
|
const CAMERA_URL = `${location.protocol === 'https:' ? 'wss' : 'ws'}://${process.env.VUE_APP_GATEWAY || location.host}${process.env.VUE_APP_CAMERA_PROXY}`
|
|
|
|
|
|
export default {
|
|
|
- name: 'Video',
|
|
|
+ name: 'Camera',
|
|
|
components: {
|
|
|
- detail
|
|
|
+ Detail
|
|
|
},
|
|
|
data () {
|
|
|
return {
|
|
|
@@ -312,19 +318,12 @@ export default {
|
|
|
rowNum: 8
|
|
|
}
|
|
|
},
|
|
|
+ computed: {
|
|
|
+ ...mapGetters(['hasEditPermission'])
|
|
|
+ },
|
|
|
created () {
|
|
|
this.getCamera()
|
|
|
},
|
|
|
- mounted () {
|
|
|
- // console.log()
|
|
|
- this.returnList.list = [{ name: '智慧城市大屏', local: '深圳市宝安区卓越时代广场' },
|
|
|
- { name: '智慧城市大屏', local: '深圳市宝安区卓越时代广场' },
|
|
|
- { name: '智慧城市大屏', local: '深圳市宝安区卓越时代广场' }]
|
|
|
- this.$nextTick(() => {
|
|
|
- // this.returnheight = (this.$refs.returnB[0].clientWidth * 9) / 16 + "px";
|
|
|
- this.returnheight = '190px'
|
|
|
- })
|
|
|
- },
|
|
|
beforeDestroy () {
|
|
|
this.destroyPlayer()
|
|
|
},
|
|
|
@@ -553,8 +552,9 @@ video::-webkit-media-controls-enclosure {
|
|
|
position: absolute;
|
|
|
left: 50%;
|
|
|
top: 50%;
|
|
|
- transform: translate(-50%, -50%);
|
|
|
color: #ff0000;
|
|
|
+ text-align: center;
|
|
|
+ transform: translate(-50%, -50%);
|
|
|
}
|
|
|
}
|
|
|
.return {
|