From 36df175693c8224f2987f9e6e54e12c0c010db2f Mon Sep 17 00:00:00 2001
From: songshankun <songshankun@foxmail.com>
Date: 星期一, 25 九月 2023 15:36:11 +0800
Subject: [PATCH] style: 联系人模块样式调整

---
 src/components/makepager/TableCommonView.vue |   93 +++++++++++++++++++++++++++++++++++++++++-----
 1 files changed, 83 insertions(+), 10 deletions(-)

diff --git a/src/components/makepager/TableCommonView.vue b/src/components/makepager/TableCommonView.vue
index e390ee3..54c5b14 100644
--- a/src/components/makepager/TableCommonView.vue
+++ b/src/components/makepager/TableCommonView.vue
@@ -5,13 +5,15 @@
       border
       :data="tableList.tableInfomation"
       tooltip-effect="dark"
+      :height="'calc(100% - 0px)'"
       style="width: 100%"
       :lazy="tableList.lazy"
       :show-summary="showSummary.show"
       :summary-method="getSummaries"
       :span-method="arraySpanMethod"
       @selection-change="handleSelectionChange"
-      :header-cell-style="{ background: '#ECF4FF', color: '#666' }"
+      :header-cell-style="{ background: '#f1f3f8', color: '#000009' , 'font-size': '12px','font-family':'PingFangSC'}"
+      size="mini"
     >
       <el-table-column v-if="selectBox" type="selection" width="40"> </el-table-column>
       <el-table-column
@@ -92,11 +94,21 @@
             </ul>
             <div v-else class="no-product">{{ "--" }}</div>
           </div>
-          <div v-else-if="item.isProductCommon" class="product-view">
+          <div v-else-if="item.isProductPrice" class="product-view">
             <ul v-if="scope.row.products && scope.row.products.length > 0">
               <li v-for="(item, index) in scope.row.products" :key="index">
                 <div :class="scope.row.products.length === 1 ? 'name-view no-bottom' : 'name-view'">
-                  {{ item.prop === "price" ? item.price : item.total }}
+                  {{ item.price }}
+                </div>
+              </li>
+            </ul>
+            <div v-else class="no-product">{{ "--" }}</div>
+          </div>
+          <div v-else-if="item.isProductTotal" class="product-view">
+            <ul v-if="scope.row.products && scope.row.products.length > 0">
+              <li v-for="(item, index) in scope.row.products" :key="index">
+                <div :class="scope.row.products.length === 1 ? 'name-view no-bottom' : 'name-view'">
+                  {{ item.total }}
                 </div>
               </li>
             </ul>
@@ -194,6 +206,37 @@
               }
             }, 0)
             sums[index + 1]
+            if (column.property === "taxUnitPrice") {
+              let sumPrice = 0
+              this.tableList.tableInfomation.map((item) => {
+                item.products.map((val) => {
+                  console.log(val.price)
+                  sumPrice += parseFloat(val.price)
+                })
+              })
+              console.log((sums[index + 1] = sumPrice))
+              console.log(sumPrice)
+            }
+            if (column.property === "priceTax") {
+              let sumPrice = 0
+              this.tableList.tableInfomation.map((item) => {
+                item.products.map((val) => {
+                  console.log(val.price)
+                  sumPrice += parseFloat(val.total)
+                })
+              })
+              sums[index + 1] = sumPrice
+            }
+            if (column.property === "productAmount") {
+              let sumPrice = 0
+              this.tableList.tableInfomation.map((item) => {
+                item.products.map((val) => {
+                  console.log(val.price)
+                  sumPrice += parseFloat(val.amount)
+                })
+              })
+              sums[index + 1] = sumPrice
+            }
           }
         })
         // console.log(sums)
@@ -284,9 +327,8 @@
 <!-- Add "scoped" attribute to limit CSS to this component only -->
 <style lang="scss" scoped>
 .table-view {
-  // margin-top: 20px;
-  margin-right: 10px;
-  // margin-bottom: 40px;
+  position: relative;
+  height: 100%;
   .blue {
     width: 70px;
     text-align: center;
@@ -310,7 +352,7 @@
         border-bottom: 1px solid #ebeef5;
       }
       .no-bottom {
-        border-bottom: 0px;
+        border-bottom: 0;
       }
     }
     .no-product {
@@ -320,9 +362,40 @@
   }
 }
 ::v-deep {
-  .el-table__footer-wrapper tbody td.el-table__cell {
-    background-color: #fff;
-    text-align: right;
+  .el-table__footer-wrapper {
+    tbody td.el-table__cell {
+      background-color: #fff;
+      font-weight: bold;
+    }
   }
 }
+
+::v-deep .el-table .cell {
+  font-size: 12px;
+  line-height: 17px;
+  font-family: PingFangSC;
+  color: rgba(0, 0, 0, 0.9);
+  .el-button--text {
+    width: auto;
+    height: auto;
+    font-family: PingFangSC-Medium, sans-serif;
+  }
+}
+::v-deep .el-table .el-table__cell {
+  padding: 6px 0 !important;
+  height: 35px;
+  text-align: center;
+}
+
+::v-deep{
+  .el-table .cell .el-button--text.el-button--small{
+    padding: 4px 0;
+  }
+}
+
+::v-deep .el-table .el-table__cell {
+  padding: 6px 0 !important;
+  height: 35px;
+  text-align: center;
+}
 </style>

--
Gitblit v1.8.0