From 9a37c5e1b2190c3f6ec71483923922189091dd52 Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Wed, 18 Dec 2024 09:42:01 +0800
Subject: [PATCH] 事件模拟更新

---
 src/views/survey/components/box/fireSource.vue |   86 +++++++++++++++++++++++++++----------------
 1 files changed, 54 insertions(+), 32 deletions(-)

diff --git a/src/views/survey/components/box/fireSource.vue b/src/views/survey/components/box/fireSource.vue
index 6de2786..c985430 100644
--- a/src/views/survey/components/box/fireSource.vue
+++ b/src/views/survey/components/box/fireSource.vue
@@ -1,4 +1,5 @@
 <script setup>
+import { Picture } from '@element-plus/icons-vue'
 
 import { inject, Text } from 'vue'
 const { VITE_APP_BASE } = import.meta.env
@@ -33,20 +34,20 @@
     img: getAssetsFile('yq-jy.png', '/bgicon')
 
   },
-  {
-    id: 3,
-    name: 'riskFirmNum',
-    title: '风险企业数量',
-    content: '1000',
-    img: getAssetsFile('yq-fx.png', '/bgicon')
-  },
-  {
-    id: 4,
-    name: 'proTarNum',
-    title: '保护目标数量',
-    content: '1000',
-    img: getAssetsFile('yq-bh.png', '/bgicon')
-  },
+  // {
+  //   id: 3,
+  //   name: 'riskFirmNum',
+  //   title: '风险企业数量',
+  //   content: '1000',
+  //   img: getAssetsFile('yq-fx.png', '/bgicon')
+  // },
+  // {
+  //   id: 4,
+  //   name: 'proTarNum',
+  //   title: '保护目标数量',
+  //   content: '1000',
+  //   img: getAssetsFile('yq-bh.png', '/bgicon')
+  // },
   {
     id: 5,
     name: 'spaceNum',
@@ -70,7 +71,7 @@
 
 })
 // 获取详情
-function getData() {
+function getData () {
   getDetail().then(res => {
     state.parkInfo = res.data.data
     parkInfoList.forEach(item => {
@@ -91,8 +92,18 @@
     <div class="box-content">
       <div>
         <div class="box-content-img">
-          <img :src="state.parkInfo.imageUrls" alt="">
-          {{ state.parkInfo.remark }}
+          <!-- <img :src="state.parkInfo.imageUrls" alt=""> -->
+          <el-image style="width: 100px; height: 100px" :src="state.parkInfo.imageUrls" :zoom-rate="1.2" :max-scale="7"
+            :min-scale="0.2" :preview-src-list="[state.parkInfo.imageUrls]" :initial-index="4" fit="cover">
+            <template #error>
+              <div class="image-slot">
+                <el-icon>
+                  <Picture />
+                </el-icon>
+              </div>
+            </template>
+          </el-image>
+          <span>{{ state.parkInfo.remark }}</span>
         </div>
       </div>
     </div>
@@ -100,15 +111,14 @@
     <div class="container">
       <div class="box-content-sj" v-for="item in parkInfoList" :key="item.id">
         <img :src="item.img" alt="">
-
         <div class="r">
           <div class="box-content-text-title">
             {{ item.content }}
+            <text v-if="item.unit">({{ item.unit }})</text>
           </div>
 
           <div class="box-content-text-content">
             {{ item.title }}
-            <text v-if="item.unit">({{ item.unit }})</text>
           </div>
         </div>
       </div>
@@ -131,25 +141,31 @@
 }
 
 .box-content-img {
-  height: 360px;
-  overflow: scroll;
+
+  height: 280px;
+  line-height: 28px;
   // 隐藏滚动条
   scrollbar-width: none;
-  // overflow-y: auto;
+  overflow-x: hidden;
+  overflow-y: auto;
 }
 
-.box-content-img img {
+.box-content-img span {
+  // 行距
+  line-height: 25px;
+  // 字体间隙
+  letter-spacing: 1px;
+}
+
+.box-content-img .el-image {
   float: left;
   margin: 5px;
+  margin-right: 15px;
   /* 宽度可以根据实际情况调整 */
-  width: 120px;
-  height: 120px;
+  width: 130px;
+  height: 130px;
 }
 
-.box-content-title img {
-  width: 80px;
-  height: 80px;
-}
 
 .box-content-text {
   padding-left: 5px;
@@ -170,7 +186,7 @@
 
 .box-content-sj {
   /* 每个盒子占据大约31%的宽度,留出一些空间用于间距 */
-  min-width: 30%;
+  min-width: 40%;
   /* 最小宽度,防止在非常小的屏幕上变得太窄 */
   box-sizing: border-box;
   // border: 1px solid #ccc;
@@ -186,7 +202,7 @@
   }
 
   .r {
-    margin-left: 6px;
+    margin-left: 1px;
     flex: 1;
     display: flex;
     flex-direction: column;
@@ -195,7 +211,7 @@
     .box-content-text-title,
     .box-content-text-content {
       margin-top: 5px;
-      font-size: 10px;
+      font-size: 13px;
       text-align: center;
     }
 
@@ -203,6 +219,12 @@
       font-size: 16px;
       font-weight: bold;
     }
+
+    .box-content-text-title text {
+      margin-top: 5px;
+      font-size: 10px;
+      text-align: center;
+    }
   }
 }
 </style>
\ No newline at end of file

--
Gitblit v1.9.3