From 73a9ae225888adae528d9b06233f65da04d883db Mon Sep 17 00:00:00 2001
From: 付延余 <f-yanyu@outlook.com>
Date: 星期五, 20 五月 2022 13:42:22 +0800
Subject: [PATCH] 其他业务

---
 src/pages/components/shebaoZhengjiShouru/shebaoZhengjiShouruForm.vue |   43 ++++++++++++++++++++++++++++++-------------
 1 files changed, 30 insertions(+), 13 deletions(-)

diff --git a/src/pages/components/shebaoZhengjiShouru/shebaoZhengjiShouruForm.vue b/src/pages/components/shebaoZhengjiShouru/shebaoZhengjiShouruForm.vue
index cec2e7f..5279232 100644
--- a/src/pages/components/shebaoZhengjiShouru/shebaoZhengjiShouruForm.vue
+++ b/src/pages/components/shebaoZhengjiShouru/shebaoZhengjiShouruForm.vue
@@ -3,34 +3,30 @@
     <div class="danwei-box">鍗曚綅锛氫汉</div>
     <div class="shebaoZhengjiShouruForm-table">
       <el-table
+        :cell-style="handleCellStyle"
+        :max-height="tableHeight"
         border
         style="width: 100%"
         :data="tableData">
         <el-table-column
-          width="200"
           align="center"
           prop="area"
           label="鍘匡紙甯傘�佸尯锛�">
         </el-table-column>
         <el-table-column
           align="center"
-          prop="enterprise"
-          label="浼佷笟鍏昏�佷繚闄╁熀閲戝緛缂存敹鍏�">
+          prop="inJobs"
+          :label="label">
         </el-table-column>
         <el-table-column
           align="center"
-          prop="resident"
-          label="鍩庝埂灞呮皯鍏昏�佷繚闄╁熀閲戝緛缂存敹鍏�">
+          prop="income"
+          label="寰佺即鏀跺叆锛堜竾鍏冿級">
         </el-table-column>
         <el-table-column
           align="center"
-          prop="injuryInsurance"
-          label="宸ヤ激淇濋櫓鍩洪噾寰佺即鏀跺叆">
-        </el-table-column>
-        <el-table-column
-          align="center"
-          prop="careerInsurance"
-          label="澶变笟淇濋櫓鍩洪噾寰佺即鏀跺叆">
+          prop="average"
+          label="浜哄潎锛堝厓锛�">
         </el-table-column>
       </el-table>
     </div>
@@ -38,6 +34,7 @@
 </template>
 
 <script>
+  import nowSize from "../../../libs/nowSize";
     export default {
         name: "shebaoZhengjiShouruForm",
         props: {
@@ -46,12 +43,32 @@
                 default: () => {
                     return []
                 }
+            },
+            label: {
+                type: String,
+                default: '鍦ㄨ亴鑱屽伐锛堜汉锛�'
             }
         },
         data() {
             return {
-                tableData: []
+                tableHeight: window.innerHeight - nowSize(380)
             }
+        },
+        methods: {
+            getHeight() {
+                this.tableHeight = window.innerHeight - nowSize(350)
+            },
+            handleCellStyle({rowIndex, columnIndex}) {
+                if(columnIndex == 0) {
+                    return { background:'#51D2FF' }
+                }
+            },
+        },
+        created() {
+            window.addEventListener('resize', this.getHeight)
+        },
+        destroyed() {
+            window.addEventListener('resize', this.getHeight)
         }
     }
 </script>

--
Gitblit v1.9.1