gr 1 year ago
parent
commit
5fa9137d44
1 changed files with 18 additions and 6 deletions
  1. 18 6
      src/views/hdsj/Index.vue

+ 18 - 6
src/views/hdsj/Index.vue

@@ -32,7 +32,7 @@
           </li>
         </ul>
         <span class="title2-left">工程信息</span>
-        <ul class="gcxx-main">
+        <ul class="gcxx-main" :class="{'is-short-list': listData_gcxx.value.length<3}">
           <li class="gcxx-item" v-for="item,index in listData_gcxx.value" @click="handleChangeProject(item.id)">
             <img :src="require('@/assets/imgs/page_hdsj/icon-gcxx.png')" alt="">
             <div>
@@ -44,8 +44,8 @@
                 <span class="status-ywc">已完成</span>
               </div>
               <div>
-                <span>总方量</span><span>{{ item.quantities }}</span>
-                <span>总投资</span><span>{{ item.investment }}</span>
+                <span>总方量</span><span>{{ (item.quantities/10000).toFixed(2) }}</span><span>万方</span>
+                <span>总投资</span><span>{{ Math.floor(item.investment) }}</span><span>万元</span>
               </div>
               <div>
                 <span>{{ item.projectStartTime }}</span><span>至</span><span>{{ item.projectEndTime }}</span>
@@ -521,8 +521,14 @@ export default {
       }
     }
     .gcxx-main {
-      max-height: 36vh;
+      height: 36vh;
       overflow: hidden;
+      display: flex;
+      flex-direction: column;
+      justify-content: space-evenly;
+      &.is-short-list {
+        justify-content: flex-start;
+      }
       .gcxx-item {
         display: flex;
         align-items: flex-start;
@@ -595,15 +601,21 @@ export default {
           &>div:nth-child(2) {
             margin: 8px 0 6px;
             span {
+              margin-right: 10px;
               font-size: 14px;
               font-family: BarlowBold;
               color: #FFFFFF;
               opacity: 0.5;
             }
-            span:nth-child(2n) {
-              margin: 0 12px;
+            span:nth-child(2), span:nth-child(5) {
+              margin-right: 2px;
+              font-size: 16px;
               opacity: 1;
             }
+            span:nth-child(3n) {
+              font-size: 12px;
+              opacity: 0.8;
+            }
             
           }
           &>div:nth-child(3) {