Browse Source

Merge remote-tracking branch 'origin/master'

S0025136190 1 year ago
parent
commit
c25e97edae

+ 1 - 0
Web/index.html

@@ -6,6 +6,7 @@
   <meta name="viewport" content="width=device-width, initial-scale=1.0" />
   <link rel="icon" href="/src/assets/public/favicon.ico" />
   <title>上云无人机管理平台</title>
+  <script type="text/javascript" src="/src/components/easyPlayer/depend/EasyPlayer-element.min.js"></script>
 </head>
 
 <body>

+ 49 - 73
Web/src/components/GMap.vue

@@ -32,9 +32,11 @@
       <div class="drag-title pl5 pr5 flex-align-center flex-row flex-justify-between"
         style="border-bottom: 1px solid #515151; height: 18%;">
         <span>{{ osdVisible.callsign }}</span>
-        <span><a class="fz16" style="color: white;" @click="() => osdVisible.visible = false">
+        <span>
+          <a class="fz16" style="color: white;" @click="() => osdVisible.visible = false">
             <CloseOutlined />
-          </a></span>
+          </a>
+        </span>
       </div>
       <div style="height: 82%;">
         <div class="flex-column flex-align-center flex-justify-center"
@@ -49,71 +51,59 @@
         <div class="osd">
           <a-row>
             <a-col span="16"
-              :style="deviceInfo.device.mode_code === EModeCode.Disconnected ? 'color: red; font-weight: 700;' : 'color: rgb(25,190,107)'">{{
-                EModeCode[deviceInfo.device.mode_code] }}</a-col>
+              :style="deviceInfo.device.mode_code === EModeCode.Disconnected ? 'color: red; font-weight: 700;' : 'color: rgb(25,190,107)'">
+              <span>
+                {{ EModeCode[deviceInfo.device.mode_code] }}
+              </span>
+              <span>
+                飞行状态
+              </span>
+            </a-col>
           </a-row>
           <a-row>
-            <a-col span="6">
-              <a-tooltip title="Signal strength">
-                <span>HD</span>
-                <span class="ml10">{{ deviceInfo.gateway?.transmission_signal_quality }}</span>
-              </a-tooltip>
+            <a-col span="8">
+              <span class="openLiveButton">
+                开启直播
+              </span>
             </a-col>
+          </a-row>
+          <a-row>
             <a-col span="6">
-              <a-tooltip title="RC Battery Level">
+              <a-tooltip title="GPS卫星数">
                 <span>
-                  <ThunderboltOutlined class="fz14" />
+                  GPS
+                  <WifiOutlined />
                 </span>
-                <span class="ml10">{{ deviceInfo.gateway && deviceInfo.gateway.capacity_percent !== str ?
-                  deviceInfo.gateway?.capacity_percent + ' %' : deviceInfo.gateway?.capacity_percent }}</span>
+                <span class="ml10">{{ deviceInfo.device.position_state.gps_number }}</span>
               </a-tooltip>
             </a-col>
-
             <a-col span="6">
-              <a-tooltip title="Drone Battery Level">
+              <a-tooltip title="RTK">
                 <span>
-                  <ThunderboltOutlined class="fz14" />
+                  RTK
                 </span>
-                <span class="ml10">{{ deviceInfo.device.battery.capacity_percent !== str ?
-                  deviceInfo.device.battery.capacity_percent + ' %' : deviceInfo.device.battery.capacity_percent
-                  }}</span>
+                <span class="ml10">{{ deviceInfo.device.position_state.rtk_number }}</span>
               </a-tooltip>
             </a-col>
-          </a-row>
-          <a-row>
-            <a-tooltip title="RTK Fixed">
-              <a-col span="6" class="flex-row flex-align-center flex-justify-start">
-                <span>Fixed</span>
-                <span class="ml10 circle"
-                  :style="deviceInfo.device.position_state.is_fixed === 1 ? 'backgroud: rgb(25,190,107);' : ' background: red;'"></span>
-              </a-col>
-            </a-tooltip>
             <a-col span="6">
-              <a-tooltip title="GPS">
-                <span>GPS</span>
-                <span class="ml10">{{ deviceInfo.device.position_state.gps_number }}</span>
+              <a-tooltip title="电量">
+                <span>电量</span>
+                <span class="ml10">
+                  {{ deviceInfo.device.battery.capacity_percent + '%' }}
+                </span>
               </a-tooltip>
             </a-col>
             <a-col span="6">
-              <a-tooltip title="RTK">
-                <span>
-                  <TrademarkOutlined class="fz14" />
-                </span>
-                <span class="ml10">{{ deviceInfo.device.position_state.rtk_number }}</span>
+              <a-tooltip title="风向速度">
+                <span>W.S</span>
+                <span class="ml10">{{ deviceInfo.device.wind_speed === str ? str : (deviceInfo.device.wind_speed /
+                  10).toFixed(2) + ' m/s' }}</span>
               </a-tooltip>
             </a-col>
           </a-row>
           <a-row>
             <a-col span="6">
-              <a-tooltip title="Flight Mode">
-                <span>
-                  <ControlOutlined class="fz16" />
-                </span>
-                <span class="ml10">{{ EGear[deviceInfo.device.gear] }}</span>
-              </a-tooltip>
-            </a-col>
-            <a-col span="6">
-              <a-tooltip title="Altitude above sea level">
+              <a-tooltip title="海拔高度">
                 <span>ASL</span>
                 <span class="ml10">
                   {{ deviceInfo.device.height === str ? str : deviceInfo.device.height.toFixed(2) + ' m' }}
@@ -121,7 +111,7 @@
               </a-tooltip>
             </a-col>
             <a-col span="6">
-              <a-tooltip title="Altitude above takeoff level">
+              <a-tooltip title="离地高度">
                 <span>ALT</span>
                 <span class="ml10">
                   {{ deviceInfo.device.elevation === str ? str : deviceInfo.device.elevation.toFixed(2) + ' m' }}
@@ -129,18 +119,7 @@
               </a-tooltip>
             </a-col>
             <a-col span="6">
-              <a-tooltip title="Distance to Home Point">
-                <span>H</span>
-                <span class="ml10">
-                  {{ deviceInfo.device.home_distance === str ? str : deviceInfo.device.home_distance.toFixed(2) + ' m'
-                  }}
-                </span>
-              </a-tooltip>
-            </a-col>
-          </a-row>
-          <a-row>
-            <a-col span="6">
-              <a-tooltip title="Horizontal Speed">
+              <a-tooltip title="水平速度">
                 <span>H.S</span>
                 <span class="ml10">
                   {{ deviceInfo.device.horizontal_speed === str ? str :
@@ -149,20 +128,11 @@
               </a-tooltip>
             </a-col>
             <a-col span="6">
-              <a-tooltip title="Vertical Speed">
-                <span>V.S</span>
-                <span class="ml10">
-                  {{ deviceInfo.device.vertical_speed === str ? str :
-                    deviceInfo.device.vertical_speed.toFixed(2) + ' m/s' }}
-                </span>
-              </a-tooltip>
-            </a-col>
-            <a-col span="6">
-              <a-tooltip title="Wind Speed">
-                <span>W.S</span>
+              <a-tooltip title="当前高度">
+                <span>H</span>
                 <span class="ml10">
-                  {{ deviceInfo.device.wind_speed === str ? str : (deviceInfo.device.wind_speed /
-                    10).toFixed(2) + ' m/s' }}
+                  {{ deviceInfo.device.home_distance === str ? str : deviceInfo.device.home_distance.toFixed(2) + ' m'
+                  }}
                 </span>
               </a-tooltip>
             </a-col>
@@ -372,8 +342,8 @@
           <a-row>
             <a-col span="16"
               :style="!deviceInfo.device || deviceInfo.device?.mode_code === EModeCode.Disconnected ? 'color: red; font-weight: 700;' : 'color: rgb(25,190,107)'">
-              {{ !deviceInfo.device ? EModeCode[EModeCode.Disconnected] : EModeCode[deviceInfo.device?.mode_code]
-              }}</a-col>
+              {{ !deviceInfo.device ? EModeCode[EModeCode.Disconnected] : EModeCode[deviceInfo.device?.mode_code] }}
+            </a-col>
           </a-row>
           <a-row>
             <a-col span="6">
@@ -1137,6 +1107,12 @@ export default defineComponent({
   opacity: 0.8;
 }
 
+.openLiveButton {
+  padding: 5px;
+  border: 1px solid #5c5c5c;
+  cursor: pointer;
+}
+
 .osd>div:not(.dock-control-panel) {
   margin-top: 5px;
   padding-left: 5px;

File diff suppressed because it is too large
+ 508 - 0
Web/src/components/easyPlayer/depend/EasyPlayer-element.min.js


BIN
Web/src/components/easyPlayer/depend/EasyPlayer.wasm


+ 28 - 0
Web/src/components/easyPlayer/index.vue

@@ -0,0 +1,28 @@
+<template>
+    <easy-player :video-url="'1'" />
+</template>
+
+<script lang="ts" setup>
+interface Props {
+    record: any,
+    fieldName: string,
+};
+
+const props = withDefaults(defineProps<Props>(), {
+
+});
+</script>
+
+<style lang="scss" scoped>
+.customCell {
+    display: flex;
+    flex-direction: column;
+    justify-content: center;
+
+    &-item {
+        height: 40px;
+        display: flex;
+        align-items: center;
+    }
+}
+</style>

+ 0 - 1
Web/src/pages/page-pilot/pilot-liveshare.vue

@@ -13,7 +13,6 @@
         </a-select-option>
       </a-select>
     </div>
-
     <div class="ml10 mr10" style="width: 96%; margin-top: -10px;">
       <a-divider />
     </div>

+ 1 - 4
Web/src/pages/page-web/projects/tsa.vue

@@ -96,7 +96,7 @@
                           style="width: 18px; height: 16px; text-align: center;">
                           <span :style="hmsInfo[dock.sn].length > 99 ? 'font-size: 11px' : 'font-size: 12px'">{{
                             hmsInfo[dock.sn].length
-                            }}</span>
+                          }}</span>
                           <span class="fz10">{{ hmsInfo[dock.sn].length > 99 ? '+' : '' }}</span>
                         </div>
                         <a-popover trigger="click" placement="bottom" color="black"
@@ -229,9 +229,6 @@
       <a-button style="margin-right: 10px;" type="primary" @click="onClickGoHome">
         返回
       </a-button>
-      <a-button type="primary" @click="openLivestreamOthers">
-        直播测试
-      </a-button>
     </div>
   </div>
 </template>

Some files were not shown because too many files changed in this diff