From abfc074c35e8bd66ec0641173bfd703051ca701a Mon Sep 17 00:00:00 2001
From: 13404089107 <puwei@sinata.cn>
Date: 星期一, 07 四月 2025 17:00:51 +0800
Subject: [PATCH] fix

---
 src/components/datascreen/CenterPanel.vue |  331 ++++++++++++++++++++++++++++++++++++++++++++----------
 1 files changed, 268 insertions(+), 63 deletions(-)

diff --git a/src/components/datascreen/CenterPanel.vue b/src/components/datascreen/CenterPanel.vue
index 261dc02..5887936 100644
--- a/src/components/datascreen/CenterPanel.vue
+++ b/src/components/datascreen/CenterPanel.vue
@@ -7,46 +7,66 @@
           <img src="@/assets/center-top-left.png" alt="">
           <div>
             <div class="label">申请总户数(户)</div>
-            <div class="value">8888</div>
+            <div class="value">{{ data.houseHoldCount }}</div>
           </div>
 
         </div>
         <div class="data-item">
           <img src="@/assets/center-top-right.png" alt="">
           <div>
-            <div class="label">本月应补偿总额(万元)</div>
-            <div class="value">8888 <span>环比</span><span class="value-change value-change-down">-4%</span></div>
+            <div class="label">本季应补偿总额(万元)</div>
+            <div class="value">{{ data.monthCompensationAmount }} <span>环比</span><span
+                class="value-change value-change-down">{{ data.monthCompensationAmountRate }}</span></div>
           </div>
         </div>
         <div class="data-item">
           <img src="@/assets/center-top-right.png" alt="">
           <div>
-            <div class="label">下月应补偿总额(万元)</div>
-            <div class="value">8888 <span>环比</span><span class="value-change value-change-up">+4%</span></div>
+            <div class="label">下季应补偿总额(万元)</div>
+            <div class="value">{{ data.nextMonthCompensationAmount }} <span>环比</span><span
+                class="value-change value-change-up">{{ data.nextMonthCompensationAmountRate }}</span></div>
           </div>
         </div>
       </div>
     </div>
 
     <!-- 中间地图 -->
-    <div class="center-middle panel-item">
-      <div class="map-title">辖区分布</div>
-      <div class="map-chart">
-        <v-chart class="chart" :option="mapOption" autoresize />
-      </div>
+    <div class="center-middle">
+      <Map :data="data" />
     </div>
 
     <!-- 中间下部数据 -->
-    <div class="center-bottom panel-item">
-      <div class="box-title">处理进度</div>
-      <div class="progress-list">
-        <div class="progress-item" v-for="(item, index) in progressList" :key="index">
-          <div class="progress-info">
-            <span class="label">{{ item.label }}</span>
-            <span class="value">{{ item.value }}</span>
+    <div class="center-bott">
+      <div class="bottom-search">
+        <div class="search-box">
+          <input type="text" placeholder="请输入户主名称进行搜索" v-model="searchText" @keydown="searchForText($event)">
+          <img src="@/assets/search.png" class="search-icon" alt="">
+        </div>
+      </div>
+      <div class="center-bottom panel-item">
+        <div class="compensation-table">
+          <div class="table-header">
+            <div class="batch-number txt-center">安置批次</div>
+            <div class="household-count txt-center">户主名称</div>
+            <div class="people-count txt-center">安置人数</div>
+            <div class="progress-wrapper txt-center">补偿阶段</div>
           </div>
-          <div class="progress-bar">
-            <div class="progress" :style="{ width: item.percentage + '%' }"></div>
+          <div class="table-content">
+            <div class="table-row" v-for="(item, index) in data.quarterProcessResponses" :key="index">
+              <div class="batch-number text-center">{{ item.batchNumber }}</div>
+              <div class="household-count text-center">{{ item.householdHead }}</div>
+              <div class="people-count text-center">{{ item.currentCount }}</div>
+              <div class="progress-wrapper">
+                <div class="progress-bar">
+                  <div class="progress-fill">
+                    <div class="progress-color" :style="{ width: item.process*5 + '%' }"
+                      :class="item.process <= 5 ? 'progress-yellow' : item.process <= 10 && item.process > 5 ? 'progress-green' : item.process <= 15 && item.process > 10 ? 'progress-blue' : 'progress-gray'">
+                    </div>
+                  </div>
+                </div>
+                <div class="progress-text">{{ item.process }}/20</div>
+              </div>
+            </div>
           </div>
         </div>
       </div>
@@ -55,22 +75,93 @@
 </template>
 
 <script>
+import Map from './map.vue';
 export default {
   name: 'CenterPanel',
+  props: {
+    data: {
+      type: Object,
+      default: () => { },
+    },
+    searchText: {
+      type: String,
+      default: '', 
+    }
+  },
+  components: {
+    Map
+  },
   data() {
     return {
-      mapOption: {},
       progressList: [
         { label: '已受理', value: '2021103000001', percentage: 90 },
         { label: '已审核', value: '2021103000002', percentage: 70 },
         { label: '已完成', value: '2021103000003', percentage: 50 }
+      ],
+      // searchText: '', // 搜索文本
+      compensationList: [
+
       ]
     };
+  },
+  methods: {
+    searchForText(event) {
+      if (event.key === 'Enter') { // 监听回车键事件
+        this.$emit('searchForText', this.searchText); // 触发搜索事件并传递搜索文本
+      }
+    }
   }
 };
 </script>
 
 <style lang="less" scoped>
+.pl-20 {
+  padding-left: 20px;
+}
+
+.bottom-search {
+  display: flex;
+  justify-content: flex-end;
+  margin-bottom: 8px;
+}
+
+.search-box {
+  width: 180px;
+  display: flex;
+  align-items: center;
+  height: 30px;
+  background: rgba(2, 0, 77, 0.4);
+  box-shadow: inset 0px 0px 34px 0px rgba(17, 40, 255, 0.66);
+  border-radius: 4px;
+  border: 2px solid #0D53B7;
+
+}
+
+input {
+  height: 30px;
+  width: 100%;
+  line-height: 30px;
+  padding-left: 9px;
+  background: transparent;
+  border: none;
+  font-size: 12px;
+  font-family: SourceHanSansCN, SourceHanSansCN;
+  font-weight: 400;
+  font-size: 12px;
+  color: rgba(255, 255, 255, 0.7);
+  outline: none;
+}
+
+.search-icon {
+  width: 14px;
+  height: 14px;
+  margin-left: 17px;
+}
+
+.text-center {
+  text-align: center;
+}
+
 .center-panel {
   position: absolute;
   left: 481px;
@@ -79,9 +170,9 @@
   bottom: 20px;
   display: flex;
   flex-direction: column;
+  justify-content: space-between;
 
   .panel-item {
-    background: rgba(0, 0, 255, 0.1);
     border-radius: 10px;
   }
 
@@ -92,67 +183,185 @@
   }
 
   .center-middle {
-    flex: 1;
-
-    .map-title {
-      font-size: 24px;
-      color: #7cb9e8;
-    }
-
-    .map-chart {
-      height: calc(100% - 44px);
-    }
+    position: fixed;
+    top: 281px;
   }
 
   .center-bottom {
     height: 245px;
+    background: url('@/assets/center-bottom-bg.png') no-repeat center center;
+    background-size: 100% 100%;
+    padding: 20px;
 
-    .progress-list {
-      height: calc(100% - 35px);
+    .compensation-table {
+      height: 100%;
       display: flex;
       flex-direction: column;
-      justify-content: space-around;
 
-      .progress-item {
-        .progress-info {
-          display: flex;
-          justify-content: space-between;
+      .table-header {
+        display: flex;
+        align-items: center;
+        color: rgba(255, 255, 255, 0.6);
+        font-size: 12px;
+        // margin-top: 20px;
+        margin-bottom: 15px;
 
-          .label {
-            color: #7cb9e8;
-          }
-
-          .value {
-            color: #00ffff;
-          }
+        >div {
+          margin-right: 40px;
         }
 
-        .progress-bar {
-          width: 100%;
-          height: 6px;
-          background: rgba(0, 255, 255, 0.1);
-          border-radius: 3px;
+        .batch-number {
+          width: 150px;
+        }
 
-          .progress {
-            height: 100%;
-            background: linear-gradient(to right, #00ffff, #7cb9e8);
-            border-radius: 3px;
-            transition: width 0.3s ease;
+        .household-count {
+          width: 80px;
+          text-align: center;
+        }
+
+        .people-count {
+          width: 100px;
+          text-align: center;
+        }
+
+        .progress-wrapper {
+          flex: 1;
+          padding-right: 20px;
+          padding-left: 20px;
+        }
+      }
+
+      .table-content {
+        // flex: 1;
+        height: 174px;
+        display: flex;
+        overflow-y: auto;
+        scrollbar-width: none;
+        /* Firefox */
+        -ms-overflow-style: none;
+
+        /* IE 和 Edge */
+        &::-webkit-scrollbar {
+          display: none;
+          /* Chrome, Safari 和 Opera */
+        }
+
+        flex-direction: column;
+        // justify-content: space-between;
+
+        .table-row {
+          display: flex;
+          align-items: center;
+          color: #fff;
+          font-size: 14px;
+          padding: 8px 0;
+          margin-bottom: 5px;
+          box-sizing: border-box;
+
+          >div {
+            margin-right: 40px;
+          }
+
+          .batch-number {
+            width: 150px;
+          }
+
+          .household-count {
+            width: 80px;
+            text-align: center;
+          }
+
+          .people-count {
+            width: 100px;
+            text-align: center;
+          }
+
+          .progress-wrapper {
+            flex: 1;
+            display: flex;
+            align-items: center;
+
+            .progress-bar {
+              flex: 1;
+              height: 10px;
+              background: rgba(255, 255, 255, 0.1);
+              border-radius: 5px;
+              margin-right: 15px;
+              overflow: hidden;
+
+              .progress-fill {
+                height: 100%;
+                display: flex;
+
+                .progress-yellow {
+                  height: 100%;
+                  background: #FEDB65 !important;
+                }
+
+                .progress-blue {
+                  height: 100%;
+                  background: #00C6FF !important;
+                }
+
+                .progress-green {
+                  height: 100%;
+                  background: rgba(0, 220, 171, 1) !important;
+                }
+
+                .progress-gray {
+                  height: 100%;
+                  background: rgba(0, 242, 240, 1) !important;
+                }
+
+
+
+              }
+            }
+
+            .progress-text {
+              width: 50px;
+              text-align: right;
+            }
+          }
+
+          &:nth-child(2n + 1) {
+            background: url('@/assets/bg.png') no-repeat center center;
+            border: 2px solid;
+            border-image: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(1, 10, 40, 0), rgba(255, 255, 255, 0.6)) 2 2;
+          }
+
+          &:nth-child(2n) {
+            background: url('@/assets/unbg.png') no-repeat center center;
+            border: 2px solid;
+            border-image: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(1, 10, 40, 0), rgba(255, 255, 255, 0.2)) 2 2;
+          }
+
+          &:last-child {
+            margin-bottom: 0;
           }
         }
       }
     }
   }
 
+  .txt-center {
+    text-align: center;
+    font-size: 12px;
+    color: #19ECFF;
+    line-height: 18px;
+  }
+
   .map-data {
     display: flex;
-    justify-content: center;
+    justify-content: space-between;
+    padding-left: 94px;
+    padding-right: 94px;
     height: 100%;
     align-items: center;
 
     .data-item {
       display: flex;
-      width: 268px;
+      flex-shrink: 0;
 
       img {
         width: 94px;
@@ -179,11 +388,11 @@
         }
 
         .value-change-up {
-          color: #00ffff;
+          color: #FEDB65;
         }
 
         .value-change-down {
-          color: #FEDB65;
+          color: #00ffff;
         }
       }
     }
@@ -194,9 +403,5 @@
     color: #7cb9e8;
   }
 
-  .chart {
-    width: 100%;
-    height: calc(100% - 35px);
-  }
 }
 </style>
\ No newline at end of file

--
Gitblit v1.7.1