From f50879b46a238c74b23c0c8fc8af8208c3c17ef8 Mon Sep 17 00:00:00 2001 From: wwp <782568523@qq.com> Date: Thu, 24 Oct 2024 11:35:04 +0800 Subject: [PATCH] =?UTF-8?q?bug=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/formDormitory/index.vue | 35 +++++++++++++++++-- monitorMobile/pages/earlyWarning/detail.vue | 8 +++++ monitorMobile/pages/earlyWarning/index.vue | 13 +++++-- 3 files changed, 52 insertions(+), 4 deletions(-) diff --git a/SafeCampus.WEB/src/views/userManage/dormitory/components/formDormitory/index.vue b/SafeCampus.WEB/src/views/userManage/dormitory/components/formDormitory/index.vue index 1255029..4757d91 100644 --- a/SafeCampus.WEB/src/views/userManage/dormitory/components/formDormitory/index.vue +++ b/SafeCampus.WEB/src/views/userManage/dormitory/components/formDormitory/index.vue @@ -133,18 +133,49 @@ async function handleSubmit() { } }); } - +watch( + () => visibleDormitory.value, + newVal => + nextTick(() => { + if (newVal) { + getCreamaList(); + } + }), + { deep: true, immediate: true } +); /** 关闭表单*/ function onClose() { visibleDormitory.value = false; - getCreamaList(); + // getCreamaList(); } onMounted(() => { getCreamaList(); }); const getCreamaList = () => { userManageDormitoryApi.getBuildCameraList().then((res: any) => { + console.log(sysDormitoryProps.record, 89); + creamaData.value = res.data; + let dormitoryData = sysDormitoryProps.record; + let insObj = reactive({ + sensorId: "", + sensorName: "" + }); + let outObj = reactive({ + sensorId: "", + sensorName: "" + }); + if (dormitoryData.insCameraId) { + insObj.sensorId = dormitoryData.insCameraId; + insObj.sensorName = dormitoryData.insCameraName; + creamaData.value.push(insObj); + } + if (dormitoryData.outCameraId && dormitoryData.insCameraId != dormitoryData.outCameraId) { + outObj.sensorId = dormitoryData.outCameraId; + outObj.sensorName = dormitoryData.outCameraName; + creamaData.value.push(outObj); + } + console.log(creamaData.value); }); }; // 暴露给父组件的方法 diff --git a/monitorMobile/pages/earlyWarning/detail.vue b/monitorMobile/pages/earlyWarning/detail.vue index 19741f2..a6d39a8 100644 --- a/monitorMobile/pages/earlyWarning/detail.vue +++ b/monitorMobile/pages/earlyWarning/detail.vue @@ -68,6 +68,14 @@ -- + + + 处理时间: + + + {{ detailData.handTime || "--" }} + + 备注信息: diff --git a/monitorMobile/pages/earlyWarning/index.vue b/monitorMobile/pages/earlyWarning/index.vue index 8f8fad0..1160012 100644 --- a/monitorMobile/pages/earlyWarning/index.vue +++ b/monitorMobile/pages/earlyWarning/index.vue @@ -131,7 +131,7 @@ - 姓名:{{item.sceneName || '--'}} + 姓名:{{item.personName || '--'}} @@ -174,7 +174,7 @@ - 时间:{{item.tick}} + 预警时间:{{item.tick}} @@ -733,6 +733,15 @@ font-size: 26rpx; font-family: 'PingFang SC'; width: calc(100% - 140rpx); + .midContent { + overflow: hidden; + word-wrap: break-word; + white-space: pre-wrap; + // font-size: 14px; + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-line-clamp: 1; + } } }