gr 1 year ago
parent
commit
440639eb41

+ 13 - 12
src/views/hdsj/Index.vue

@@ -3,12 +3,12 @@
     <div class="panel-left">
       <div class="pl-b1">
         <span class="title1-left">水深管理</span>
-        <div v-for="item,index in data_ssgl.value" class="plb1-item">
+        <div v-for="item in data_ssgl.value" class="plb1-item">
           <img :src="item.iconUrl" alt="">
           <div>
-            <span @click="handleToggleYuji(index)" :class="{'highlight': index===1&&isYujiOn}">{{ item.title }}</span>
+            <span @click="handleToggleYuji(item)" :class="{'highlight': item.title==='淤积预警'&&isYujiOn}">{{ item.title }}</span>
             <div>
-              <span>{{ item.value }}</span>
+              <span :class="{'is-warning': item.value>0}">{{ item.value }}</span>
               <span>{{ item.unit }}</span>
             </div>
           </div>
@@ -156,17 +156,20 @@ export default {
   onMounted(() => {
     setSjjk(document.getElementById('chart_fstj'), chartData_fstj.value)
     getGctj()
+    bus.on('changeYuJiNum',(val)=> {
+      data_ssgl.value[1].value = val
+    })
   })
   
   const data_ssgl = reactive({value: [
     { title: '维护水深', value:  8, unit: '米', iconUrl: require('@/assets/imgs/page_hdsj/logo-whss.png') },
-    { title: '淤积预警', value:  1, unit: '处', iconUrl: require('@/assets/imgs/page_hdsj/logo-yjyj.png') },
+    { title: '淤积预警', value:  0, unit: '处', iconUrl: require('@/assets/imgs/page_hdsj/logo-yjyj.png') },
   ]})
 
   const isYujiOn = ref(false)
 
-  function handleToggleYuji(index) {
-    if(index===1) {
+  function handleToggleYuji(item) {
+    if(item.title==='淤积预警'&&item.value>0) {
       if(isYujiOn.value === false) {
         ueCallCloseWater()
         ueCallStartYjyj()
@@ -459,6 +462,10 @@ export default {
             color: transparent;
             background: linear-gradient(0deg, rgba(29,128,224,0.9) 0%, rgba(255,255,255,0.9) 70%);
             -webkit-background-clip: text;
+            &.is-warning {
+              background: linear-gradient(0deg, rgba(224,159,29,0.9) 0%, rgba(255,255,255,0.9) 70%);
+              -webkit-background-clip: text;
+            }
           }
           span:nth-child(2) {
             font-size: 14px;
@@ -469,12 +476,6 @@ export default {
         }
       }
     }
-    .plb1-item:nth-last-child(1) {
-      &>div>div>span:nth-child(1) {
-        background: linear-gradient(0deg, rgba(224,159,29,0.9) 0%, rgba(255,255,255,0.9) 70%);
-        -webkit-background-clip: text;
-      }
-    }
   }
 
   .pl-b2 {

+ 9 - 2
src/views/home/cpns/UnderWater.vue

@@ -42,6 +42,7 @@ import 'element-plus/es/components/carousel/style/css'
 import 'element-plus/es/components/carousel-item/style/css'
 import { useNow, useDateFormat } from '@vueuse/core'
 import { ueCallCloseWater, ueCallOpenWater, ueCallChangeShuishen, ueCallFlyToSXDX } from '@/utils/UIInteractions'
+import bus from '@/utils/bus'
 
 
 onMounted(() => {
@@ -49,15 +50,16 @@ onMounted(() => {
   ueCallFlyToSXDX()
   setTimeout(() => {
     ueCallCloseWater()
-    ueCallChangeShuishen('2022.2')
+    ueCallChangeShuishen('2023.1')
   }, 2000);
 })
 
 onBeforeUnmount(() => {
   ueCallOpenWater()
+  bus.emit('changeYuJiNum', 0)
 })
 
-const sxdxCurrent = ref('2022.2')
+const sxdxCurrent = ref('2023.1')
 const currentYear = useDateFormat(useNow(), 'YYYY').value
 
 function initSxdxData() {
@@ -98,6 +100,11 @@ function handleChooseSxdx(i, type) {
     sxdxCurrent.value = i.year+'.2'
     ueCallChangeShuishen(sxdxCurrent.value)
   }
+  if(i.year===2022&&type==='.2') {
+    bus.emit('changeYuJiNum', 1)
+  }else {
+    bus.emit('changeYuJiNum', 0)
+  }
 }
 
 const sxdxData = reactive({value: []})

+ 3 - 1
src/views/home/cpns/boatPanel/BoatDjld.vue

@@ -14,6 +14,8 @@
       <li><span>船舶长度:</span><span>{{ props.boatInfo.shipLength }}米</span></li>
       <li><span>船舶宽度:</span><span>{{ props.boatInfo.shipBreadth }}米</span></li>
       <li><span>船舶类型:</span><span>{{ props.boatInfo.shipTypeName }}</span></li>
+      <li><span>满载吃水:</span><span>{{ props.boatInfo.loadedDraft || '-' }}</span></li>
+      <li style="margin-bottom: 0;"><span>空载吃水:</span><span>{{ props.boatInfo.noLoadedDraft || '-' }}</span></li>
     </ul>
     <ul class="content-ldkll bottom-divider">
       <li><span>本航线行人数</span><span>{{ props.boatInfo.pNumWalking }}</span></li>
@@ -168,7 +170,7 @@ export default {
   flex-direction: column;
 
   .content-cbxx {
-    margin-top: 20px;
+    margin-top: 10px;
   }
 
   .content-ldkll {

+ 6 - 1
src/views/home/cpns/boatPanel/BoatGeneral.vue

@@ -23,6 +23,8 @@
         <li><span>船舶宽度:</span><span>{{ props.boatInfo.shipBreadth }}米</span></li>
         <li><span>船舶类型:</span><span>{{ props.boatInfo.shipTypeName }}</span></li>
         <li><span>航班类型:</span><span>{{ props.boatInfo.typeName || '-' }}</span></li>
+        <li style="margin-bottom: 0;"><span>满载吃水:</span><span>{{ props.boatInfo.loadedDraft || '-' }}</span></li>
+        <li style="margin-bottom: 0;"><span>空载吃水:</span><span>{{ props.boatInfo.noLoadedDraft || '-' }}</span></li>
       </ul>
     </div>
     <ul class="boat-fields content-bgxx bottom-divider" v-if="currentTab==='bgxx'">
@@ -189,7 +191,7 @@ export default {
 
   .content-cbxx {
     .cbxx-top {
-      padding: 0 0 5px 25px;
+      padding: 0 0 0 25px;
       margin-bottom: 20px;
       text-align: left;
       span:first-child {
@@ -205,6 +207,9 @@ export default {
     }
     .boat-fields {
       padding: 0 0 0 25px;
+      li {
+        margin-bottom: 10px;
+      }
     }
   }
 

+ 6 - 1
src/views/home/cpns/boatPanel/BoatKkjk.vue

@@ -19,6 +19,8 @@
       <li><span>船舶宽度:</span><span>{{ props.boatInfo.shipBreadth || '- ' }}米</span></li>
       <li><span>船舶长度:</span><span>{{ props.boatInfo.shipLength || '- ' }}米</span></li>
       <li><span>船舶总吨:</span><span>{{ props.boatInfo.shipGrossTon || '-' }}</span></li>
+      <li><span>满载吃水:</span><span>{{ props.boatInfo.loadedDraft || '-' }}</span></li>
+      <li style="margin-bottom: 0;"><span>空载吃水:</span><span>{{ props.boatInfo.noLoadedDraft || '-' }}</span></li>
     </ul>
     <ul class="boat-fields cf-bgxx bottom-divider" v-if="currentTab==='bgxx'">
       <li><span>停靠泊位:</span><span>--</span></li>
@@ -308,7 +310,10 @@ export default {
   }
 
   .cf-cbxx {
-    margin: 25px 0 16px;
+    margin: 15px 0 16px;
+    li {
+      margin-bottom: 10px;
+    }
   }
 
   .cf-bgxx {

+ 4 - 2
src/views/home/cpns/boatPanel/BoatPjyl.vue

@@ -23,6 +23,8 @@
         <li><span>船舶宽度:</span><span>{{ props.boatInfo.shipBreadth }}米</span></li>
         <li><span>船舶类型:</span><span>{{ props.boatInfo.shipTypeName }}</span></li>
         <li><span>航班类型:</span><span>{{ props.boatInfo.typeName || '-' }}</span></li>
+        <li style="margin-bottom: 0;"><span>满载吃水:</span><span>{{ props.boatInfo.loadedDraft || '-' }}</span></li>
+        <li style="margin-bottom: 0;"><span>空载吃水:</span><span>{{ props.boatInfo.noLoadedDraft || '-' }}</span></li>
       </ul>
       <div class="cbxx-sales bottom-divider">
         <div><span>本次航线售票数</span><span>{{ props.boatInfo.saleNum || '-' }}</span></div>
@@ -331,7 +333,7 @@ export default {
   .content-cbxx {
     .cbxx-top {
       padding-left: 25px;
-      margin-bottom: 25px;
+      margin-bottom: 20px;
       text-align: left;
       span:first-child {
         margin-right: 3px;
@@ -352,7 +354,7 @@ export default {
       padding-left: 25px;
       display: flex;
       align-items: center;
-      margin: 20px 0 15px 0;
+      margin: 20px 0 10px 0;
       &>div {
         width: 50%;
         display: flex;

+ 2 - 2
src/views/home/cpns/boatPanel/Index.vue

@@ -137,7 +137,7 @@ function handleClose() {
   }
 
   .cb-time {
-    margin-top: 18px;
+    margin-top: 15px;
     box-sizing: border-box;
     padding: 0 50px 0 40px;
     display: flex;
@@ -162,7 +162,7 @@ function handleClose() {
   .cb-play {
     box-sizing: border-box;
     padding-left: 52px;
-    margin-top: 19px;
+    margin-top: 18px;
     display: flex;
     align-items: center;
     &>span:not(.btn-disabled):hover {