|
|
|
@ -35,7 +35,8 @@ |
|
|
|
@platform-icon-updated="onPlatformIconUpdated" |
|
|
|
@platform-icon-removed="onPlatformIconRemoved" |
|
|
|
@viewer-ready="onViewerReady" |
|
|
|
@drawing-entities-changed="onDrawingEntitiesChanged" /> |
|
|
|
@drawing-entities-changed="onDrawingEntitiesChanged" |
|
|
|
@platform-style-saved="onPlatformStyleSaved" /> |
|
|
|
<div v-show="!screenshotMode" class="map-overlay-text"> |
|
|
|
<!-- <i class="el-icon-location-outline text-3xl mb-2 block"></i> --> |
|
|
|
<!-- <p>二维GIS地图区域</p> |
|
|
|
@ -193,7 +194,7 @@ |
|
|
|
@open-waypoint-dialog="openWaypointDialog" |
|
|
|
@add-waypoint="addWaypoint" |
|
|
|
@cancel-route="cancelRoute" |
|
|
|
@toggle-route-visibility="toggleRouteVisibility" |
|
|
|
@toggle-route-visibility="(route, opts) => toggleRouteVisibility(route, opts)" |
|
|
|
@toggle-route-lock="handleToggleRouteLockFromPanel" |
|
|
|
@view-conflict="viewConflict" |
|
|
|
@resolve-conflict="resolveConflict" |
|
|
|
@ -646,9 +647,20 @@ export default { |
|
|
|
|
|
|
|
// 用户 |
|
|
|
userAvatar: 'https://cube.elemecdn.com/0/88/03b0d39583f48206768a7534e55bcpng.png', |
|
|
|
/** 当前连接的 WebSocket sessionId 集合(用于过滤自己发出的同步消息,避免重复应用) */ |
|
|
|
mySyncSessionIds: [], |
|
|
|
}; |
|
|
|
}, |
|
|
|
watch: { |
|
|
|
'$route.query.roomId': { |
|
|
|
handler(newRoomId) { |
|
|
|
if (newRoomId != null && String(newRoomId) !== String(this.currentRoomId)) { |
|
|
|
this.currentRoomId = newRoomId; |
|
|
|
this.connectRoomWebSocket(); |
|
|
|
if (newRoomId) this.getRoomDetail(); |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
timeProgress: { |
|
|
|
handler() { |
|
|
|
this.updateTimeFromProgress(); |
|
|
|
@ -977,6 +989,7 @@ export default { |
|
|
|
this.selectedRouteDetails = { ...this.selectedRouteDetails, waypoints: sortedWaypoints }; |
|
|
|
} |
|
|
|
this.$message.success('已添加航点'); |
|
|
|
this.wsConnection?.sendSyncWaypoints?.(routeId); |
|
|
|
} catch (e) { |
|
|
|
this.$message.error(e.msg || e.message || '添加航点失败'); |
|
|
|
console.error(e); |
|
|
|
@ -1082,6 +1095,7 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
this.$message.success(isHold ? '已设为普通航点' : '已设为盘旋航点'); |
|
|
|
this.wsConnection?.sendSyncWaypoints?.(routeId); |
|
|
|
} catch (e) { |
|
|
|
this.$message.error(e.msg || e.message || '切换失败'); |
|
|
|
console.error(e); |
|
|
|
@ -1187,6 +1201,7 @@ export default { |
|
|
|
} |
|
|
|
this.$message.success('航点位置已更新'); |
|
|
|
this.$nextTick(() => this.updateDeductionPositions()); |
|
|
|
this.wsConnection?.sendSyncWaypoints?.(routeId); |
|
|
|
// 航点拖拽后,根据新位置重算导弹发射位置并更新 Redis |
|
|
|
if (this.currentRoomId && routeForPlatform && waypoints.length > 0) { |
|
|
|
this.updateMissilePositionsAfterRouteEdit(this.currentRoomId, routeId, routeForPlatform.platformId != null ? routeForPlatform.platformId : 0, waypoints); |
|
|
|
@ -1258,6 +1273,8 @@ export default { |
|
|
|
avatar: m.avatar ? (m.avatar.startsWith('http') ? m.avatar : (baseUrl + m.avatar)) : '' |
|
|
|
})); |
|
|
|
this.onlineCount = this.wsOnlineMembers.length; |
|
|
|
const myId = this.$store.getters.id; |
|
|
|
this.mySyncSessionIds = (members || []).filter(m => myId != null && String(m.userId) === String(myId)).map(m => m.sessionId).filter(Boolean); |
|
|
|
}, |
|
|
|
onMemberJoined: (member) => { |
|
|
|
const baseUrl = (process.env.VUE_APP_BACKEND_URL || (window.location.origin + (process.env.VUE_APP_BASE_API || ''))); |
|
|
|
@ -1275,10 +1292,17 @@ export default { |
|
|
|
this.wsOnlineMembers = [...this.wsOnlineMembers, m]; |
|
|
|
this.onlineCount = this.wsOnlineMembers.length; |
|
|
|
} |
|
|
|
const myId = this.$store.getters.id; |
|
|
|
if (myId != null && String(member.userId) === String(myId) && member.sessionId) { |
|
|
|
if (!this.mySyncSessionIds.includes(member.sessionId)) { |
|
|
|
this.mySyncSessionIds = [...this.mySyncSessionIds, member.sessionId]; |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
onMemberLeft: (member, sessionId) => { |
|
|
|
this.wsOnlineMembers = this.wsOnlineMembers.filter(m => m.id !== sessionId && m.id !== member.sessionId); |
|
|
|
this.onlineCount = this.wsOnlineMembers.length; |
|
|
|
this.mySyncSessionIds = this.mySyncSessionIds.filter(s => s !== sessionId && s !== member.sessionId); |
|
|
|
}, |
|
|
|
onChatMessage: (msg) => { |
|
|
|
this.chatMessages = [...this.chatMessages, msg]; |
|
|
|
@ -1302,10 +1326,31 @@ export default { |
|
|
|
const newer = existing.filter(m => (m.timestamp || 0) > maxTs); |
|
|
|
this.$set(this.privateChatMessages, targetUserId, [...history, ...newer]); |
|
|
|
}, |
|
|
|
onSyncRouteVisibility: (routeId, visible, senderSessionId) => { |
|
|
|
if (this.isMySyncSession(senderSessionId)) return; |
|
|
|
this.applySyncRouteVisibility(routeId, visible); |
|
|
|
}, |
|
|
|
onSyncWaypoints: (routeId, senderSessionId) => { |
|
|
|
if (this.isMySyncSession(senderSessionId)) return; |
|
|
|
this.applySyncWaypoints(routeId); |
|
|
|
}, |
|
|
|
onSyncPlatformIcons: (senderSessionId) => { |
|
|
|
if (this.isMySyncSession(senderSessionId)) return; |
|
|
|
this.applySyncPlatformIcons(); |
|
|
|
}, |
|
|
|
onSyncRoomDrawings: (senderSessionId) => { |
|
|
|
if (this.isMySyncSession(senderSessionId)) return; |
|
|
|
this.applySyncRoomDrawings(); |
|
|
|
}, |
|
|
|
onSyncPlatformStyles: (senderSessionId) => { |
|
|
|
if (this.isMySyncSession(senderSessionId)) return; |
|
|
|
this.applySyncPlatformStyles(); |
|
|
|
}, |
|
|
|
onConnected: () => {}, |
|
|
|
onDisconnected: () => { |
|
|
|
this.onlineCount = 0; |
|
|
|
this.wsOnlineMembers = []; |
|
|
|
this.mySyncSessionIds = []; |
|
|
|
this.chatMessages = []; |
|
|
|
this.privateChatMessages = {}; |
|
|
|
}, |
|
|
|
@ -1320,10 +1365,154 @@ export default { |
|
|
|
this.wsConnection = null; |
|
|
|
} |
|
|
|
this.wsOnlineMembers = []; |
|
|
|
this.mySyncSessionIds = []; |
|
|
|
this.onlineCount = 0; |
|
|
|
this.chatMessages = []; |
|
|
|
this.privateChatMessages = {}; |
|
|
|
}, |
|
|
|
/** 判断是否为当前连接发出的同步消息(避免自己发的消息再应用一次) */ |
|
|
|
isMySyncSession(senderSessionId) { |
|
|
|
if (!senderSessionId) return false; |
|
|
|
return Array.isArray(this.mySyncSessionIds) && this.mySyncSessionIds.includes(senderSessionId); |
|
|
|
}, |
|
|
|
/** 收到其他设备的航线显隐同步:直接应用变更,不经过 selectRoute 的 toggle 逻辑,避免互相干扰 */ |
|
|
|
async applySyncRouteVisibility(routeId, visible) { |
|
|
|
const route = this.routes.find(r => r.id === routeId); |
|
|
|
if (!route) return; |
|
|
|
if (visible) { |
|
|
|
if (this.activeRouteIds.includes(routeId)) return; |
|
|
|
try { |
|
|
|
const res = await getRoutes(route.id); |
|
|
|
if (res.code !== 200 || !res.data) return; |
|
|
|
const waypoints = res.data.waypoints || []; |
|
|
|
this.activeRouteIds = [...this.activeRouteIds, route.id]; |
|
|
|
this.selectedRouteId = res.data.id; |
|
|
|
this.selectedRouteDetails = { |
|
|
|
id: res.data.id, |
|
|
|
name: res.data.callSign, |
|
|
|
waypoints: waypoints, |
|
|
|
platformId: route.platformId, |
|
|
|
platform: route.platform, |
|
|
|
attributes: route.attributes |
|
|
|
}; |
|
|
|
const routeIndex = this.routes.findIndex(r => r.id === route.id); |
|
|
|
if (routeIndex > -1) { |
|
|
|
this.$set(this.routes, routeIndex, { ...this.routes[routeIndex], waypoints }); |
|
|
|
} |
|
|
|
if (waypoints.length > 0 && this.$refs.cesiumMap) { |
|
|
|
const roomId = this.currentRoomId; |
|
|
|
if (roomId && route.platformId) { |
|
|
|
try { |
|
|
|
const styleRes = await getPlatformStyle({ roomId, routeId: route.id, platformId: route.platformId }); |
|
|
|
if (styleRes.data) this.$refs.cesiumMap.setPlatformStyle(route.id, styleRes.data); |
|
|
|
} catch (_) {} |
|
|
|
} |
|
|
|
this.$refs.cesiumMap.renderRouteWaypoints(waypoints, route.id, route.platformId, route.platform, this.parseRouteStyle(route.attributes)); |
|
|
|
} |
|
|
|
} catch (_) {} |
|
|
|
} else { |
|
|
|
const idx = this.activeRouteIds.indexOf(routeId); |
|
|
|
if (idx > -1) { |
|
|
|
this.activeRouteIds = this.activeRouteIds.filter(id => id !== routeId); |
|
|
|
if (this.$refs.cesiumMap) this.$refs.cesiumMap.removeRouteById(routeId); |
|
|
|
if (this.selectedRouteDetails && this.selectedRouteDetails.id === routeId) { |
|
|
|
if (this.activeRouteIds.length > 0) { |
|
|
|
const lastId = this.activeRouteIds[this.activeRouteIds.length - 1]; |
|
|
|
const res = await getRoutes(lastId); |
|
|
|
if (res.code === 200 && res.data) { |
|
|
|
const fromList = this.routes.find(r => r.id === lastId); |
|
|
|
this.selectedRouteId = res.data.id; |
|
|
|
this.selectedRouteDetails = { |
|
|
|
id: res.data.id, |
|
|
|
name: res.data.callSign, |
|
|
|
waypoints: res.data.waypoints || [], |
|
|
|
platformId: fromList?.platformId, |
|
|
|
platform: fromList?.platform, |
|
|
|
attributes: fromList?.attributes |
|
|
|
}; |
|
|
|
} |
|
|
|
} else { |
|
|
|
this.selectedRouteId = null; |
|
|
|
this.selectedRouteDetails = null; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
/** 收到其他设备的航点变更同步:拉取最新数据并重绘 */ |
|
|
|
async applySyncWaypoints(routeId) { |
|
|
|
try { |
|
|
|
const res = await getRoutes(routeId); |
|
|
|
if (res.code !== 200 || !res.data) return; |
|
|
|
const waypoints = res.data.waypoints || []; |
|
|
|
const route = this.routes.find(r => r.id === routeId); |
|
|
|
if (route) { |
|
|
|
this.$set(route, 'waypoints', waypoints); |
|
|
|
} |
|
|
|
if (this.selectedRouteId === routeId && this.selectedRouteDetails) { |
|
|
|
this.selectedRouteDetails = { ...this.selectedRouteDetails, waypoints }; |
|
|
|
} |
|
|
|
if (this.activeRouteIds.includes(routeId) && this.$refs.cesiumMap && waypoints.length > 0) { |
|
|
|
const r = this.routes.find(rr => rr.id === routeId); |
|
|
|
if (r) { |
|
|
|
this.$refs.cesiumMap.removeRouteById(routeId); |
|
|
|
this.$refs.cesiumMap.renderRouteWaypoints(waypoints, routeId, r.platformId, r.platform, this.parseRouteStyle(r.attributes)); |
|
|
|
this.$nextTick(() => this.updateDeductionPositions()); |
|
|
|
} |
|
|
|
} |
|
|
|
} catch (e) { |
|
|
|
console.warn('applySyncWaypoints failed', e); |
|
|
|
} |
|
|
|
}, |
|
|
|
/** 收到其他设备的平台图标变更同步:拉取最新数据并重绘 */ |
|
|
|
applySyncPlatformIcons() { |
|
|
|
const rId = this.currentRoomId; |
|
|
|
if (!rId || !this.$refs.cesiumMap || typeof this.$refs.cesiumMap.loadRoomPlatformIcons !== 'function') return; |
|
|
|
listRoomPlatformIcons(rId).then(res => { |
|
|
|
if (res.code === 200 && res.data) this.$refs.cesiumMap.loadRoomPlatformIcons(rId, res.data); |
|
|
|
}).catch(() => {}); |
|
|
|
}, |
|
|
|
/** 收到其他设备的空域图形变更同步:拉取最新房间数据并重绘 */ |
|
|
|
applySyncRoomDrawings() { |
|
|
|
if (!this.currentRoomId || !this.$refs.cesiumMap || typeof this.$refs.cesiumMap.loadFrontendDrawings !== 'function') return; |
|
|
|
getRooms(this.currentRoomId).then(res => { |
|
|
|
if (res.code === 200 && res.data) { |
|
|
|
this.roomDetail = this.roomDetail ? { ...this.roomDetail, frontendDrawings: res.data.frontendDrawings } : { ...res.data }; |
|
|
|
if (res.data.frontendDrawings) { |
|
|
|
this.$refs.cesiumMap.loadFrontendDrawings(res.data.frontendDrawings); |
|
|
|
} else { |
|
|
|
this.$refs.cesiumMap.clearDrawingEntities(); |
|
|
|
} |
|
|
|
} |
|
|
|
}).catch(() => {}); |
|
|
|
}, |
|
|
|
/** 收到其他设备的探测区/威力区样式变更同步:刷新平台图标与航线样式 */ |
|
|
|
async applySyncPlatformStyles() { |
|
|
|
const rId = this.currentRoomId; |
|
|
|
if (!rId || !this.$refs.cesiumMap) return; |
|
|
|
if (typeof this.$refs.cesiumMap.loadRoomPlatformIcons === 'function') { |
|
|
|
try { |
|
|
|
const res = await listRoomPlatformIcons(rId); |
|
|
|
if (res.code === 200 && res.data) this.$refs.cesiumMap.loadRoomPlatformIcons(rId, res.data); |
|
|
|
} catch (_) {} |
|
|
|
} |
|
|
|
for (const routeId of this.activeRouteIds || []) { |
|
|
|
const route = this.routes.find(r => r.id === routeId); |
|
|
|
if (!route || !route.platformId) continue; |
|
|
|
try { |
|
|
|
const styleRes = await getPlatformStyle({ roomId: rId, routeId, platformId: route.platformId }); |
|
|
|
if (styleRes.data && this.$refs.cesiumMap) { |
|
|
|
this.$refs.cesiumMap.setPlatformStyle(routeId, styleRes.data); |
|
|
|
if (styleRes.data.detectionZoneVisible !== false && styleRes.data.detectionZoneRadius != null && Number(styleRes.data.detectionZoneRadius) > 0) { |
|
|
|
this.$refs.cesiumMap.ensureDetectionZoneForRoute(routeId, styleRes.data.detectionZoneRadius, styleRes.data.detectionZoneColor || 'rgba(0, 150, 255, 0.35)', styleRes.data.detectionZoneOpacity); |
|
|
|
} |
|
|
|
if (styleRes.data.powerZoneVisible !== false && styleRes.data.powerZoneRadius != null && Number(styleRes.data.powerZoneRadius) > 0) { |
|
|
|
this.$refs.cesiumMap.ensurePowerZoneForRoute(routeId, styleRes.data.powerZoneRadius, styleRes.data.powerZoneAngle ?? 120, styleRes.data.powerZoneColor || 'rgba(255, 0, 0, 0.3)', styleRes.data.powerZoneOpacity); |
|
|
|
} |
|
|
|
} |
|
|
|
} catch (_) {} |
|
|
|
} |
|
|
|
}, |
|
|
|
// 平台编辑弹窗相关方法 |
|
|
|
openPlatformDialog(platform) { |
|
|
|
this.selectedPlatform = JSON.parse(JSON.stringify(platform)); |
|
|
|
@ -1496,6 +1685,7 @@ export default { |
|
|
|
this.selectedRouteDetails.attributes = updatedRoute.attributes; |
|
|
|
} |
|
|
|
this.$message.success(updatedRoute.waypoints && updatedRoute.waypoints.length > 0 ? '航线与航点已保存' : '航线更新成功'); |
|
|
|
this.wsConnection?.sendSyncWaypoints?.(updatedRoute.id); |
|
|
|
const routeStyle = updatedRoute.routeStyle || this.parseRouteStyle(updatedRoute.attributes); |
|
|
|
if (this.$refs.cesiumMap && this.activeRouteIds.includes(updatedRoute.id)) { |
|
|
|
const route = this.routes.find(r => r.id === updatedRoute.id); |
|
|
|
@ -1774,6 +1964,7 @@ export default { |
|
|
|
if (platformToRemove && this.$refs.cesiumMap) { |
|
|
|
if (platformToRemove.serverId) { |
|
|
|
await delRoomPlatformIcon(platformToRemove.serverId).catch(() => {}); |
|
|
|
this.wsConnection?.sendSyncPlatformIcons?.(); |
|
|
|
if (typeof this.$refs.cesiumMap.removePlatformIconByServerId === 'function') { |
|
|
|
this.$refs.cesiumMap.removePlatformIconByServerId(platformToRemove.serverId); |
|
|
|
} |
|
|
|
@ -1863,6 +2054,7 @@ export default { |
|
|
|
this.showWaypointDialog = false; |
|
|
|
this.$message.success('航点信息已持久化至数据库'); |
|
|
|
this.$nextTick(() => this.updateDeductionPositions()); |
|
|
|
this.wsConnection?.sendSyncWaypoints?.(this.selectedRouteDetails.id); |
|
|
|
// 航点编辑后,根据新位置重算导弹发射位置并更新 Redis |
|
|
|
if (roomId && sd.waypoints && sd.waypoints.length > 0) { |
|
|
|
this.updateMissilePositionsAfterRouteEdit(roomId, sd.id, sd.platformId != null ? sd.platformId : 0, sd.waypoints); |
|
|
|
@ -1954,6 +2146,7 @@ export default { |
|
|
|
const frontendDrawingsStr = JSON.stringify(drawingsData); |
|
|
|
await updateRooms({ id: this.currentRoomId, frontendDrawings: frontendDrawingsStr }); |
|
|
|
if (this.roomDetail) this.roomDetail.frontendDrawings = frontendDrawingsStr; |
|
|
|
this.wsConnection?.sendSyncRoomDrawings?.(); |
|
|
|
}, |
|
|
|
/** 将任意日期字符串格式化为 yyyy-MM-dd HH:mm:ss,供日期选择器使用 */ |
|
|
|
formatKTimeForPicker(val) { |
|
|
|
@ -2403,6 +2596,7 @@ export default { |
|
|
|
entityData.serverId = res.data.id |
|
|
|
entityData.roomId = this.currentRoomId |
|
|
|
this.$message.success('平台图标已保存到当前房间') |
|
|
|
this.wsConnection?.sendSyncPlatformIcons?.() |
|
|
|
} |
|
|
|
} catch (e) { |
|
|
|
console.warn('Parse platform drag data or save failed', e) |
|
|
|
@ -2421,13 +2615,21 @@ export default { |
|
|
|
lat: entityData.lat, |
|
|
|
heading: entityData.heading != null ? entityData.heading : 0, |
|
|
|
iconScale: entityData.iconScale != null ? entityData.iconScale : 1 |
|
|
|
}).then(() => {}).catch(() => {}) |
|
|
|
}).then(() => { |
|
|
|
this.wsConnection?.sendSyncPlatformIcons?.() |
|
|
|
}).catch(() => {}) |
|
|
|
}, 500) |
|
|
|
}, |
|
|
|
/** 平台图标从地图删除时同步删除服务端记录 */ |
|
|
|
onPlatformIconRemoved({ serverId }) { |
|
|
|
if (!serverId) return |
|
|
|
delRoomPlatformIcon(serverId).then(() => {}).catch(() => {}) |
|
|
|
delRoomPlatformIcon(serverId).then(() => { |
|
|
|
this.wsConnection?.sendSyncPlatformIcons?.() |
|
|
|
}).catch(() => {}) |
|
|
|
}, |
|
|
|
/** 探测区/威力区样式保存后通知其他设备同步 */ |
|
|
|
onPlatformStyleSaved() { |
|
|
|
this.wsConnection?.sendSyncPlatformStyles?.() |
|
|
|
}, |
|
|
|
|
|
|
|
handleScaleUnitChange(unit) { |
|
|
|
@ -3285,6 +3487,7 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
this.$message.success('已添加盘旋航点'); |
|
|
|
this.wsConnection?.sendSyncWaypoints?.(routeId); |
|
|
|
} catch (e) { |
|
|
|
this.$message.error(e.msg || '添加盘旋失败'); |
|
|
|
console.error(e); |
|
|
|
@ -3374,6 +3577,7 @@ export default { |
|
|
|
this.selectedRouteDetails = null; |
|
|
|
} |
|
|
|
} |
|
|
|
this.wsConnection?.sendSyncRouteVisibility?.(route.id, false); |
|
|
|
this.$message.info(`已取消航线: ${route.name}`); |
|
|
|
return; |
|
|
|
} |
|
|
|
@ -3420,6 +3624,7 @@ export default { |
|
|
|
} else { |
|
|
|
this.$message.warning('该航线暂无坐标数据,无法在地图展示'); |
|
|
|
} |
|
|
|
this.wsConnection?.sendSyncRouteVisibility?.(route.id, true); |
|
|
|
} |
|
|
|
} catch (error) { |
|
|
|
console.error("获取航线详情失败:", error); |
|
|
|
@ -3534,16 +3739,17 @@ export default { |
|
|
|
this.$message.success(nextLocked ? '航线已上锁,无法修改' : '航线已解锁,可以编辑'); |
|
|
|
}, |
|
|
|
|
|
|
|
toggleRouteVisibility(route) { |
|
|
|
async toggleRouteVisibility(route, opts) { |
|
|
|
const index = this.activeRouteIds.indexOf(route.id); |
|
|
|
const fromPlanSwitch = opts && opts.fromPlanSwitch; |
|
|
|
|
|
|
|
if (index > -1) { |
|
|
|
// 航线已显示,隐藏它 |
|
|
|
// 使用过滤创建新数组,确保 Vue 能够检测到变化 |
|
|
|
this.activeRouteIds = this.activeRouteIds.filter(id => id !== route.id); |
|
|
|
if (this.$refs.cesiumMap) { |
|
|
|
this.$refs.cesiumMap.removeRouteById(route.id); |
|
|
|
} |
|
|
|
if (!fromPlanSwitch) this.wsConnection?.sendSyncRouteVisibility?.(route.id, false); |
|
|
|
if (this.selectedRouteDetails && this.selectedRouteDetails.id === route.id) { |
|
|
|
if (this.activeRouteIds.length > 0) { |
|
|
|
const lastId = this.activeRouteIds[this.activeRouteIds.length - 1]; |
|
|
|
@ -3570,7 +3776,8 @@ export default { |
|
|
|
} |
|
|
|
} else { |
|
|
|
// 航线已隐藏,显示它 |
|
|
|
this.selectRoute(route); |
|
|
|
await this.selectRoute(route); |
|
|
|
if (!fromPlanSwitch) this.wsConnection?.sendSyncRouteVisibility?.(route.id, true); |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
|