|
@@ -1,11 +1,22 @@
|
|
|
<template>
|
|
<template>
|
|
|
<div class="door-content-r">
|
|
<div class="door-content-r">
|
|
|
<div class="content-r-btn">
|
|
<div class="content-r-btn">
|
|
|
- <a-button preIcon="ant-design:pause-circle-outlined" type="primary"
|
|
|
|
|
- @click="handlerOpenOrClose('open')">同步开启</a-button>
|
|
|
|
|
- <a-button preIcon="ant-design:play-circle-outlined" type="primary" style="margin: 0px 10px"
|
|
|
|
|
- @click="handlerOpenOrClose('close')">同步关闭</a-button>
|
|
|
|
|
- <a-button preIcon="ant-design:clock-circle-outlined" type="primary" @click="handlerTimeSet">定时设置</a-button>
|
|
|
|
|
|
|
+ <a-button type="primary" @click="handlerOpenOrClose('open')">
|
|
|
|
|
+ 同步开启
|
|
|
|
|
+ </a-button>
|
|
|
|
|
+ <!-- <a-button type="primary" @click="handlerOpenOrClose('open')">
|
|
|
|
|
+ <SvgIcon class="icon-style" size="14" color="#30b3fc" name="open-door" />
|
|
|
|
|
+ 同步开启
|
|
|
|
|
+ </a-button> -->
|
|
|
|
|
+ <a-button type="primary" style="margin: 0px 10px" @click="handlerOpenOrClose('close')">
|
|
|
|
|
+ <SvgIcon class="icon-style" size="14" color="#30b3fc" name="close-door" />
|
|
|
|
|
+ 同步关闭
|
|
|
|
|
+ </a-button>
|
|
|
|
|
+ <a-button type="primary" @click="handlerTimeSet">
|
|
|
|
|
+ <SvgIcon class="icon-style" size="14" color="#30b3fc" name="time-setting-door" />
|
|
|
|
|
+ 定时设置
|
|
|
|
|
+ </a-button>
|
|
|
|
|
+ <a-button style="margin: 0px 10px" type="primary">操作日志</a-button>
|
|
|
</div>
|
|
</div>
|
|
|
<div class="content-r-container">
|
|
<div class="content-r-container">
|
|
|
<div class="content-r-box" v-for="(item, index) in infoDatas" :key="index">
|
|
<div class="content-r-box" v-for="(item, index) in infoDatas" :key="index">
|
|
@@ -15,15 +26,9 @@
|
|
|
</div>
|
|
</div>
|
|
|
<div class="box-content">
|
|
<div class="box-content">
|
|
|
<!-- 二三维信息 -->
|
|
<!-- 二三维信息 -->
|
|
|
- <gateDualSVG v-if="index == 0" ref="modelRef0"></gateDualSVG>
|
|
|
|
|
- <gateDualSVG1 v-if="index == 1" ref="modelRef1"></gateDualSVG1>
|
|
|
|
|
- <gateDualSVG2 v-if="index == 2" ref="modelRef2"></gateDualSVG2>
|
|
|
|
|
- <gateDualSVG3 v-if="index == 3" ref="modelRef3"></gateDualSVG3>
|
|
|
|
|
- <gateDualSVG4 v-if="index == 4" ref="modelRef4"></gateDualSVG4>
|
|
|
|
|
- <gateDualSVG5 v-if="index == 5" ref="modelRef5"></gateDualSVG5>
|
|
|
|
|
- <gateDualSVG6 v-if="index == 6" ref="modelRef6"></gateDualSVG6>
|
|
|
|
|
- <gateDualSVG7 v-if="index == 7" ref="modelRef7"></gateDualSVG7>
|
|
|
|
|
- <gateDualSVG8 v-if="index == 8" ref="modelRef8"></gateDualSVG8>
|
|
|
|
|
|
|
+ <!-- <gateDualSVG :ref="`modelRef${index}`" :indexCode="index"></gateDualSVG> -->
|
|
|
|
|
+ <component :ref="`modelRef${index}`" :indexCode="index"
|
|
|
|
|
+ :is="getModelComponent(globalConfig.is2DModel, item.deviceType)" />
|
|
|
</div>
|
|
</div>
|
|
|
<img src="@/assets/images/camera.png" alt="" @click="handlerCamera(item, index)" />
|
|
<img src="@/assets/images/camera.png" alt="" @click="handlerCamera(item, index)" />
|
|
|
</div>
|
|
</div>
|
|
@@ -34,33 +39,27 @@
|
|
|
<timeSetModal :visibleTime="visibleTime" @handleCancelTime="handleCancelTime" @handleOk="handleOkTime">
|
|
<timeSetModal :visibleTime="visibleTime" @handleCancelTime="handleCancelTime" @handleOk="handleOkTime">
|
|
|
</timeSetModal>
|
|
</timeSetModal>
|
|
|
<!--30s延时提示弹窗-->
|
|
<!--30s延时提示弹窗-->
|
|
|
- <tipModal :visible="visibletip" @handleCancel="handleCancelTip"></tipModal>
|
|
|
|
|
|
|
+ <tipModal></tipModal>
|
|
|
<!-- 摄像头信息 -->
|
|
<!-- 摄像头信息 -->
|
|
|
- <Modals :visible="modalVisible" :destroyOnClose="true" @cancel="handleCancelCamera">
|
|
|
|
|
|
|
+ <Modal :visible="modalVisible" :centered="true" :destroyOnClose="true" @cancel="handleCancelCamera">
|
|
|
<CameraModal :cameraData="cameraData"></CameraModal>
|
|
<CameraModal :cameraData="cameraData"></CameraModal>
|
|
|
- </Modals>
|
|
|
|
|
|
|
+ </Modal>
|
|
|
</div>
|
|
</div>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script setup lang="ts">
|
|
<script setup lang="ts">
|
|
|
-import { reactive, ref, inject, watch, onMounted, h } from 'vue';
|
|
|
|
|
|
|
+import { reactive, ref, inject, watch, onMounted, h, shallowRef } from 'vue';
|
|
|
import syncModal from './syncModal.vue';
|
|
import syncModal from './syncModal.vue';
|
|
|
import timeSetModal from './timeSetModal.vue';
|
|
import timeSetModal from './timeSetModal.vue';
|
|
|
import CameraModal from './cameraModal.vue';
|
|
import CameraModal from './cameraModal.vue';
|
|
|
-import Modals from './Modal.vue';
|
|
|
|
|
|
|
+import Modal from './Modal.vue';
|
|
|
import tipModal from './tipModal.vue'
|
|
import tipModal from './tipModal.vue'
|
|
|
-import gateDualSVG from './gateDualSVG.vue'
|
|
|
|
|
-import gateDualSVG1 from './gateDualSVG1.vue'
|
|
|
|
|
-import gateDualSVG2 from './gateDualSVG2.vue'
|
|
|
|
|
-import gateDualSVG3 from './gateDualSVG3.vue'
|
|
|
|
|
-import gateDualSVG4 from './gateDualSVG4.vue'
|
|
|
|
|
-import gateDualSVG5 from './gateDualSVG5.vue'
|
|
|
|
|
-import gateDualSVG6 from './gateDualSVG6.vue'
|
|
|
|
|
-import gateDualSVG7 from './gateDualSVG7.vue'
|
|
|
|
|
-import gateDualSVG8 from './gateDualSVG8.vue'
|
|
|
|
|
|
|
+// import gateDualSVG from './gateDualSVG.vue'
|
|
|
import { useRouter } from 'vue-router';
|
|
import { useRouter } from 'vue-router';
|
|
|
import { devicecontrol, insertSyncRule, GetSyncRule } from '../airdoor.api'
|
|
import { devicecontrol, insertSyncRule, GetSyncRule } from '../airdoor.api'
|
|
|
|
|
+import { getModelComponent } from '../airdoor.data'
|
|
|
import { useMessage } from '/@/hooks/web/useMessage';
|
|
import { useMessage } from '/@/hooks/web/useMessage';
|
|
|
|
|
+import { SvgIcon } from '/@/components/Icon';
|
|
|
|
|
|
|
|
let props = defineProps({
|
|
let props = defineProps({
|
|
|
infoData: {
|
|
infoData: {
|
|
@@ -69,10 +68,6 @@ let props = defineProps({
|
|
|
return [];
|
|
return [];
|
|
|
},
|
|
},
|
|
|
},
|
|
},
|
|
|
- visibleTs30: {
|
|
|
|
|
- type: Boolean,
|
|
|
|
|
- default: false
|
|
|
|
|
- }
|
|
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
const { createMessage } = useMessage();
|
|
const { createMessage } = useMessage();
|
|
@@ -98,11 +93,12 @@ const modelRef5 = ref(null);
|
|
|
const modelRef6 = ref(null);
|
|
const modelRef6 = ref(null);
|
|
|
const modelRef7 = ref(null);
|
|
const modelRef7 = ref(null);
|
|
|
const modelRef8 = ref(null);
|
|
const modelRef8 = ref(null);
|
|
|
-const visibletip = ref(false)
|
|
|
|
|
|
|
+// const modelComponent = shallowRef(getModelComponent(globalConfig.is2DModel));
|
|
|
|
|
|
|
|
|
|
|
|
|
//同步开启/关闭--弹窗
|
|
//同步开启/关闭--弹窗
|
|
|
function handlerOpenOrClose(data) {
|
|
function handlerOpenOrClose(data) {
|
|
|
|
|
+ console.log('111kaiqi')
|
|
|
visible.value = true;
|
|
visible.value = true;
|
|
|
visibleStatus.value = data
|
|
visibleStatus.value = data
|
|
|
}
|
|
}
|
|
@@ -148,20 +144,18 @@ async function handleOkTime(param) {
|
|
|
function handleCancelTime(param) {
|
|
function handleCancelTime(param) {
|
|
|
visibleTime.value = param;
|
|
visibleTime.value = param;
|
|
|
}
|
|
}
|
|
|
-//关闭定时弹窗
|
|
|
|
|
-function handleCancelTip(param) {
|
|
|
|
|
- visibletip.value = param
|
|
|
|
|
-}
|
|
|
|
|
//详情跳转
|
|
//详情跳转
|
|
|
function handlerDetail(id) {
|
|
function handlerDetail(id) {
|
|
|
router.push(`/monitorChannel/monitor-gate?id=${id}&deviceType=gate`);
|
|
router.push(`/monitorChannel/monitor-gate?id=${id}&deviceType=gate`);
|
|
|
}
|
|
}
|
|
|
//摄像头切换
|
|
//摄像头切换
|
|
|
function handlerCamera(item, index) {
|
|
function handlerCamera(item, index) {
|
|
|
|
|
+ console.log(item,'cemarea')
|
|
|
modalVisible.value = true;
|
|
modalVisible.value = true;
|
|
|
cameraData = Object.assign({}, item)
|
|
cameraData = Object.assign({}, item)
|
|
|
}
|
|
}
|
|
|
function handleCancelCamera(param) {
|
|
function handleCancelCamera(param) {
|
|
|
|
|
+ console.log(param,'990099')
|
|
|
modalVisible.value = param;
|
|
modalVisible.value = param;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -169,43 +163,42 @@ function handleCancelCamera(param) {
|
|
|
function monitorAnimation(selectData, index) {
|
|
function monitorAnimation(selectData, index) {
|
|
|
if (index == 0) {
|
|
if (index == 0) {
|
|
|
modelRef0.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
modelRef0.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
- } else if (index == 1) {
|
|
|
|
|
- modelRef1.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
- } else if (index == 2) {
|
|
|
|
|
- modelRef2.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
- } else if (index == 3) {
|
|
|
|
|
- modelRef3.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
- } else if (index == 4) {
|
|
|
|
|
- modelRef4.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
- } else if (index == 5) {
|
|
|
|
|
- modelRef5.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
- }else if (index == 6) {
|
|
|
|
|
- modelRef6.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
- }else if (index == 7) {
|
|
|
|
|
- modelRef7.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
- }else if (index == 8) {
|
|
|
|
|
- modelRef8.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
}
|
|
}
|
|
|
|
|
+ // else if (index == 1) {
|
|
|
|
|
+ // modelRef1.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
+ // } else if (index == 2) {
|
|
|
|
|
+ // modelRef2.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
+ // } else if (index == 3) {
|
|
|
|
|
+ // modelRef3.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
+ // } else if (index == 4) {
|
|
|
|
|
+ // modelRef4.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
+ // } else if (index == 5) {
|
|
|
|
|
+ // modelRef5.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
+ // } else if (index == 6) {
|
|
|
|
|
+ // modelRef6.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
+ // } else if (index == 7) {
|
|
|
|
|
+ // modelRef7.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
+ // } else if (index == 8) {
|
|
|
|
|
+ // modelRef8.value[0]?.animate?.(selectData.frontGateOpen == '1', selectData.midGateOpen == '1', selectData.rearGateOpen == '1');
|
|
|
|
|
+ // }
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
watch(() => props.infoData, (newV, oldV) => {
|
|
watch(() => props.infoData, (newV, oldV) => {
|
|
|
console.log(newV, 'new---')
|
|
console.log(newV, 'new---')
|
|
|
infoDatas.value = newV
|
|
infoDatas.value = newV
|
|
|
- if (newV.length) {
|
|
|
|
|
- setTimeout(() => {
|
|
|
|
|
- newV.forEach((el: any, index: number) => {
|
|
|
|
|
- el = Object.assign(el, el.readData)
|
|
|
|
|
- monitorAnimation(el, index);
|
|
|
|
|
- })
|
|
|
|
|
- }, 1000)
|
|
|
|
|
|
|
+ // if (newV.length) {
|
|
|
|
|
+ // setTimeout(() => {
|
|
|
|
|
+ // newV.forEach((el: any, index: number) => {
|
|
|
|
|
+ // el = Object.assign(el, el.readData)
|
|
|
|
|
+ // monitorAnimation(el, index);
|
|
|
|
|
+ // })
|
|
|
|
|
+ // }, 1000)
|
|
|
|
|
|
|
|
- }
|
|
|
|
|
-})
|
|
|
|
|
-watch(() => props.visibleTs30, (newV, oldV) => {
|
|
|
|
|
- console.log(newV,'gaunbi')
|
|
|
|
|
- visibletip.value = newV
|
|
|
|
|
|
|
+ // }
|
|
|
})
|
|
})
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
</script>
|
|
</script>
|
|
|
|
|
|
|
|
<style lang="less" scoped>
|
|
<style lang="less" scoped>
|
|
@@ -214,17 +207,24 @@ watch(() => props.visibleTs30, (newV, oldV) => {
|
|
|
@{theme-deepblue} {
|
|
@{theme-deepblue} {
|
|
|
.door-content-r {
|
|
.door-content-r {
|
|
|
--image-camera_bg: url('/@/assets/images/themify/deepblue/vent/camera_bg.png');
|
|
--image-camera_bg: url('/@/assets/images/themify/deepblue/vent/camera_bg.png');
|
|
|
|
|
+ --image-btn: url(/@/assets/images/themify/deepblue/files/details/btn.png);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
.door-content-r {
|
|
.door-content-r {
|
|
|
--image-camera_bg: url('/@/assets/images/vent/camera_bg.png');
|
|
--image-camera_bg: url('/@/assets/images/vent/camera_bg.png');
|
|
|
|
|
+ --image-btn: url(/@/assets/images/files/details/btn.png);
|
|
|
width: 100%;
|
|
width: 100%;
|
|
|
height: 100%;
|
|
height: 100%;
|
|
|
|
|
|
|
|
|
|
+ .icon-style {
|
|
|
|
|
+ margin-right: 5px;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
.content-r-btn {
|
|
.content-r-btn {
|
|
|
width: 100%;
|
|
width: 100%;
|
|
|
height: 40px;
|
|
height: 40px;
|
|
|
|
|
+ padding: 0px 10px;
|
|
|
display: flex;
|
|
display: flex;
|
|
|
// align-items: center;
|
|
// align-items: center;
|
|
|
}
|
|
}
|
|
@@ -238,9 +238,9 @@ watch(() => props.visibleTs30, (newV, oldV) => {
|
|
|
|
|
|
|
|
.content-r-box {
|
|
.content-r-box {
|
|
|
position: relative;
|
|
position: relative;
|
|
|
- width: 514px;
|
|
|
|
|
- height: 300px;
|
|
|
|
|
- margin: 10px;
|
|
|
|
|
|
|
+ width: 376px;
|
|
|
|
|
+ height: 270px;
|
|
|
|
|
+ margin: 10px 5px;
|
|
|
background: var(--image-camera_bg);
|
|
background: var(--image-camera_bg);
|
|
|
background-size: 100% 100%;
|
|
background-size: 100% 100%;
|
|
|
|
|
|
|
@@ -286,4 +286,11 @@ watch(() => props.visibleTs30, (newV, oldV) => {
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+::v-deep .zxm-btn-primary {
|
|
|
|
|
+ background-color: transparent;
|
|
|
|
|
+ border: none;
|
|
|
|
|
+ background: var(--image-btn) no-repeat !important;
|
|
|
|
|
+ background-size: 100% 100% !important;
|
|
|
|
|
+}
|
|
|
</style>
|
|
</style>
|