| | |
| | | <a-collapse :bordered="false" expandIconPosition="right" accordion style="background: #232323;"> |
| | | <a-collapse-panel :key="EDeviceTypeName.Dock" header="机场" style="border-bottom: 1px solid #4f4f4f;"> |
| | | <div v-if="onlineDocks.data.length === 0" style="height: 150px; color: white;"> |
| | | <a-empty style="color: #fff;" :image="simpleImage" description="暂无数据" :image-style="{ height: '60px' }" /> |
| | | <a-empty style="color: #fff;" :image="simpleImage" description="暂无数据" |
| | | :image-style="{ height: '60px' }"/> |
| | | </div> |
| | | <div v-else class="fz12" style="color: white;"> |
| | | <div v-for="dock in onlineDocks.data" :key="dock.sn" |
| | |
| | | <!-- // 机场设备标题 --> |
| | | <div style="width: 80%; height: 30px; line-height: 30px; font-size: 16px;"> |
| | | <a-tooltip :title="`${dock.gateway.callsign} - ${dock.callsign ?? 'No Drone'}`"> |
| | | <div class="text-hidden" style="max-width: 200px;">{{ dock.gateway.callsign }} - {{ dock.callsign ?? |
| | | 'No Drone' }}</div> |
| | | <div class="text-hidden" style="max-width: 200px;">{{ dock.gateway.callsign }} - {{ |
| | | dock.callsign ?? |
| | | 'No Drone' |
| | | }} |
| | | </div> |
| | | </a-tooltip> |
| | | </div> |
| | | <!-- // 机场设备状态 --> |
| | |
| | | </span> |
| | | <div class="font-bold text-hidden" style="max-width: 80px;" |
| | | :style="dockInfo[dock.gateway.sn] && dockInfo[dock.gateway.sn].basic_osd?.mode_code !== EDockModeCode.Disconnected ? 'color: #00ee8b' : 'color: red;'"> |
| | | {{ dockInfo[dock.gateway.sn] ? EDockModeText[dockInfo[dock.gateway.sn].basic_osd?.mode_code] : |
| | | EDockModeText[EDockModeCode.Disconnected] }} |
| | | {{ |
| | | dockInfo[dock.gateway.sn] ? EDockModeText[dockInfo[dock.gateway.sn].basic_osd?.mode_code] : |
| | | EDockModeText[EDockModeCode.Disconnected] |
| | | }} |
| | | </div> |
| | | </div> |
| | | <div class="mr5 flex-align-center flex-row" style="width: 85px; margin-right: 0; height: 18px;"> |
| | |
| | | hmsInfo[dock.gateway.sn][0].level === EHmsLevel.WARN ? 'warn-blink' : 'notice-blink'" |
| | | style="width: 18px; height: 16px; text-align: center;"> |
| | | <span :style="hmsInfo[dock.gateway.sn].length > 99 ? 'font-size: 11px' : 'font-size: 12px'">{{ |
| | | hmsInfo[dock.gateway.sn].length }}</span> |
| | | hmsInfo[dock.gateway.sn].length |
| | | }}</span> |
| | | <span class="fz10">{{ hmsInfo[dock.gateway.sn].length > 99 ? '+' : '' }}</span> |
| | | </div> |
| | | <a-popover trigger="click" placement="bottom" color="black" |
| | |
| | | </span> |
| | | <div class="font-bold text-hidden" style="max-width: 80px" |
| | | :style="deviceInfo[dock.sn] && deviceInfo[dock.sn].mode_code !== EModeCode.Disconnected ? 'color: #00ee8b' : 'color: red;'"> |
| | | {{ deviceInfo[dock.sn] ? EModeText[deviceInfo[dock.sn].mode_code] : |
| | | EModeText[EModeCode.Disconnected] }} |
| | | {{ |
| | | deviceInfo[dock.sn] ? EModeText[deviceInfo[dock.sn].mode_code] : |
| | | EModeText[EModeCode.Disconnected] |
| | | }} |
| | | </div> |
| | | </div> |
| | | <div class="mr5 flex-align-center flex-row" style="width: 85px; margin-right: 0; height: 18px;"> |
| | |
| | | hmsInfo[dock.sn][0].level === EHmsLevel.WARN ? 'warn-blink' : 'notice-blink'" |
| | | 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> |
| | | hmsInfo[dock.sn].length |
| | | }}</span> |
| | | <span class="fz10">{{ hmsInfo[dock.sn].length > 99 ? '+' : '' }}</span> |
| | | </div> |
| | | <a-popover trigger="click" placement="bottom" color="black" v-model:visible="hmsVisible[dock.sn]" |
| | | <a-popover trigger="click" placement="bottom" color="black" |
| | | v-model:visible="hmsVisible[dock.sn]" |
| | | @visibleChange="readHms(hmsVisible[dock.sn], dock.sn)" |
| | | :overlayStyle="{ width: '200px', height: '300px' }"> |
| | | <div :class="hmsInfo[dock.sn][0].level === EHmsLevel.CAUTION ? 'caution' : |
| | |
| | | <a-collapse :bordered="false" expandIconPosition="right" accordion style="background: #232323;"> |
| | | <a-collapse-panel :key="EDeviceTypeName.Aircraft" header="在线设备" style="border-bottom: 1px solid #4f4f4f;"> |
| | | <div v-if="onlineDevices.data.length === 0" style="height: 150px; color: white;"> |
| | | <a-empty :image="simpleImage" style="color: #fff;" description="暂无数据" :image-style="{ height: '60px' }" /> |
| | | <a-empty :image="simpleImage" style="color: #fff;" description="暂无数据" |
| | | :image-style="{ height: '60px' }"/> |
| | | </div> |
| | | <div v-else class="fz12" style="color: white;"> |
| | | <div v-for="device in onlineDevices.data" :key="device.sn" |
| | |
| | | <div style="background: #535759; width: 100%;"></div> |
| | | <div class="capacity-percent" :style="{ width: deviceInfo[device.sn].battery.capacity_percent + '%' }"> |
| | | </div> |
| | | <div class="return-home" :style="{ width: deviceInfo[device.sn].battery.return_home_power + '%' }"></div> |
| | | <div class="return-home" |
| | | :style="{ width: deviceInfo[device.sn].battery.return_home_power + '%' }"></div> |
| | | <div class="landing" :style="{ width: deviceInfo[device.sn].battery.landing_power + '%' }"></div> |
| | | <div class="battery" :style="{ left: deviceInfo[device.sn].battery.capacity_percent + '%' }"></div> |
| | | </div> |
| | |
| | | <div style="float: left; padding: 5px 5px 8px 8px; width: 88%"> |
| | | <div style="width: 100%; height: 100%;"> |
| | | <a-tooltip> |
| | | <template #title>{{ device.model ? `${device.model} - ${device.callsign}` : 'No Drone' }}</template> |
| | | <span class="text-hidden" style="max-width: 200px; display: block; height: 20px;">{{ device.model ? |
| | | `${device.model} - ${device.callsign}` : 'No Drone' }}</span> |
| | | <template #title>{{ |
| | | device.model ? `${device.model} - ${device.callsign}` : 'No Drone' |
| | | }} |
| | | </template> |
| | | <span class="text-hidden" style="max-width: 200px; display: block; height: 20px;">{{ |
| | | device.model ? |
| | | `${device.model} - ${device.callsign}` : 'No Drone' |
| | | }}</span> |
| | | </a-tooltip> |
| | | </div> |
| | | <div class="mt5" style="background: #595959;"> |
| | |
| | | </span> |
| | | <span class="font-bold" |
| | | :style="deviceInfo[device.sn] && deviceInfo[device.sn].mode_code !== EModeCode.Disconnected ? 'color: #00ee8b' : 'color: red;'"> |
| | | {{ deviceInfo[device.sn] ? EModeCode[deviceInfo[device.sn].mode_code] : |
| | | EModeCode[EModeCode.Disconnected] }} |
| | | {{ |
| | | deviceInfo[device.sn] ? EModeCode[deviceInfo[device.sn].mode_code] : |
| | | EModeCode[EModeCode.Disconnected] |
| | | }} |
| | | </span> |
| | | </div> |
| | | </div> |
| | |
| | | <a-tooltip> |
| | | <template #title>{{ device.gateway.model }} - {{ device.gateway.callsign }} </template> |
| | | <div class="text-hidden" style="max-width: 200px;">{{ device.gateway.model }} - {{ |
| | | device.gateway.callsign }}</div> |
| | | device.gateway.callsign |
| | | }} |
| | | </div> |
| | | </a-tooltip> |
| | | </div> |
| | | </div> |
| | |
| | | import { OnlineDevice, EModeCode, OSDVisible, EDockModeCode, DeviceOsd, EDockModeText, EModeText } from '/@/types/device' |
| | | import { useMyStore } from '/@/store' |
| | | import { getDeviceTopo, getUnreadDeviceHms, updateDeviceHms, testBind } from '/@/api/manage' |
| | | import { RocketOutlined, EyeInvisibleOutlined, EyeOutlined, RobotOutlined, DoubleRightOutlined } from '@ant-design/icons-vue' |
| | | import { |
| | | RocketOutlined, |
| | | EyeInvisibleOutlined, |
| | | EyeOutlined, |
| | | RobotOutlined, |
| | | DoubleRightOutlined |
| | | } from '@ant-design/icons-vue' |
| | | import { EHmsLevel } from '/@/types/enums' |
| | | import { cesiumOperation } from '/@/hooks/use-cesium-tsa' |
| | | |
| | | const { appContext } = getCurrentInstance() |
| | | const global = appContext.config.globalProperties |
| | | const route = useRoute() |
| | |
| | | return val |
| | | } |
| | | }) |
| | | |
| | | watch( |
| | | () => store.state.osdVisible.visible, |
| | | (newVal, oldVal) => { |
| | | osdVisible.value.visible = newVal |
| | | }, |
| | | { |
| | | deep: true, |
| | | }) |
| | | |
| | | const getResource = (name: string) => { |
| | | return new URL(`/src/assets/icons/${name}`, import.meta.url).href |
| | | } |