Explorar el Código

增加断面米深间隔

zk hace 1 año
padre
commit
b28eaf1cb5
Se han modificado 3 ficheros con 101 adiciones y 3 borrados
  1. 17 1
      src/utils/UIInteractions.js
  2. 21 2
      src/views/home/Header.vue
  3. 63 0
      src/views/home/cpns/MiForChange.vue

+ 17 - 1
src/utils/UIInteractions.js

@@ -375,6 +375,18 @@ export function ueCallCloseRlt() {    // 关闭轮渡客流
   })
 }
 
+
+
+export function ueCallChangeMi (consmi) {    //更改米深
+  callUIInteractionFormat({
+    "ActionName":"close_water",
+    "Parameters":{"mi":consmi}
+
+  })
+}
+
+
+
 export function ueCallFlyToHD() {    // 定位到航道视角
   callUIInteractionFormat({
     "ActionName":"fly",
@@ -413,7 +425,11 @@ export function ueCallFlyToSXDX() {    // 定位到水下地形水上视角新
 export function ueCallFlyToSP() {    // 定位到视频视角
   callUIInteractionFormat({
     "ActionName":"fly",
-    "Parameters":{"x":251135.859375,"y":-82312.960938,"z":16717.919922,"roll_x":0.000003,"roll_y":-43.600452,"roll_z":-120.054901 }
+    // "Parameters":{"x":251135.859375,"y":-82312.960938,"z":16717.919922,"roll_x":0.000003,"roll_y":-43.600452,"roll_z":-120.054901 }  之前旧视角
+    // "Parameters":{"x":260363.53125,"y":-85049.40625,"z":29117.736328,"roll_x":0.000003,"roll_y":-49.960373,"roll_z":-119.297333 }
+    // "Parameters":{"x":252294.0187,"y":-81416.5337,"z":10800,"roll_x":0.000003,"roll_y":-49.960373,"roll_z":-119.297333 }港务大厦
+    // "Parameters":{"x":254878.484375,"y":80966.054688,"z":11625.779297,"roll_x":0.000004,"roll_y":-24.339344,"roll_z":-131.197723 }港务大厦调整
+    "Parameters":{"x":254739.46875,"y":-88544.71875,"z":27800.070312,"roll_x":0.000003,"roll_y":-57,"roll_z":-119.227257 }
   })
 }
 

+ 21 - 2
src/views/home/Header.vue

@@ -36,6 +36,7 @@
         </li>
       </ul>
     </div>
+    <MiForChange v-if="miForChangeShow"/>
     <water-level v-if="waterDeepShow"/>
   </div>
 </template>
@@ -57,7 +58,7 @@ export default {
     ueCallOpenRlt, ueCallCloseRlt, ueCallFlyToHD, ueCallFlyToSP, ueCallFlyToZrcb, ueCallGetNowTime
   } from '@/utils/UIInteractions'
   import WaterLevel from './cpns/WaterLevel.vue'
-
+  import MiForChange from './cpns/MiForChange.vue'
   onMounted(() => [
     getWeather()
   ])
@@ -84,6 +85,7 @@ export default {
     { name: '船舶', status: true },
     { name: '视频', status: false },
     { name: '水下地形', status: false },
+    { name: '断面', status: false },
     { name: '中燃船舶', status: false },
   ])
   
@@ -114,8 +116,17 @@ export default {
           break
         case 4:
           bus.emit('toggle_sxdx', true)
+          clickWeeather.value=true
           break
         case 5:
+          if (clickWeeather.value) {
+            miForChangeShow.value = true
+            subList[index].status = true
+          }else {
+            subList[index].status = false
+          }
+          break
+        case 6:
           ueCallFlyToZrcb()
           break
       }
@@ -134,15 +145,21 @@ export default {
           ueCallCloseVideoFusion()
           break
         case 4:
+          clickWeeather.value=false
+          miForChangeShow.value = false
+          subList[index+1].status = false
           bus.emit('toggle_sxdx', false)
           break
         case 5:
+          miForChangeShow.value = false
+          break
+        case 6:
           ueCallfullExtent()
           break
       }
     }
   }
-
+  const clickWeeather = ref(false)
   const temperature = ref('8')
   const time = useDateFormat(useNow(), 'HH:mm')
   const date = useDateFormat(useNow(), 'YYYY.MM.DD')
@@ -150,6 +167,8 @@ export default {
 
   const waterDeepShow = ref(false)
 
+  const miForChangeShow = ref(false)
+
   function toggleScene() {
     bus.emit('toggleSceneBox')
   }

+ 63 - 0
src/views/home/cpns/MiForChange.vue

@@ -0,0 +1,63 @@
+<template>
+  <div>
+    <div id="MiForChange">
+      <ul>
+        <li v-for="item,index in hightLightSomeOne" :class="{'highlight': item.status}">
+          <span @click="showMi(item,index)">{{ item.name }}</span>
+        </li>
+      </ul>
+    </div>
+
+  </div>
+</template>
+
+<script>
+export default {
+  name: 'MiForChange'
+}
+</script>
+
+<script setup>
+import 'element-plus/es/components/date-picker/style/css'
+import {
+  ueCallChangeMi
+} from '@/utils/UIInteractions'
+import {reactive} from "vue";
+
+const hightLightSomeOne = reactive([
+  { name: '50m', status: false },
+  { name: '100m', status: false }
+])
+
+// eslint-disable-next-line no-unused-vars
+function showMi(mi,index){
+  hightLightSomeOne[index].status= !hightLightSomeOne[index].status
+  ueCallChangeMi(mi.name)
+}
+
+</script>
+
+<style lang="scss" scoped>
+#MiForChange {
+  position: absolute;
+  height: 40px;
+  bottom: -37px;
+  left: 63%;
+  transform: translateX(-50%);
+  display: flex;
+  align-items: center;
+  ul li{
+    ransform: translateX(-50%);
+    list-style: none;
+    float: left;
+    margin-right: 10px;
+    font-size: 18px;
+    font-weight: bold;
+    .highlight{
+      background: #1A5482;
+    }
+  }
+}
+
+
+</style>