mirror of
https://github.com/OpenSquawk/OpenSquawk
synced 2026-08-09 02:56:02 +08:00
Build decision flow editor and runtime integration
This commit is contained in:
@@ -955,6 +955,8 @@ const {
|
||||
currentStep,
|
||||
initializeFlight,
|
||||
updateFrequencyVariables,
|
||||
fetchRuntimeTree,
|
||||
isReady: engineReady,
|
||||
processPilotTransmission,
|
||||
buildLLMContext,
|
||||
applyLLMDecision,
|
||||
@@ -1069,6 +1071,14 @@ onMounted(async () => {
|
||||
})
|
||||
}
|
||||
|
||||
try {
|
||||
await fetchRuntimeTree()
|
||||
} catch (err) {
|
||||
console.error('Failed to load decision tree runtime', err)
|
||||
error.value = 'Decision engine konnte nicht initialisiert werden.'
|
||||
return
|
||||
}
|
||||
|
||||
if (typeof window !== 'undefined') {
|
||||
const storedVatsimId = window.localStorage.getItem(STORAGE_KEYS.vatsimId)
|
||||
if (storedVatsimId) {
|
||||
@@ -1606,6 +1616,17 @@ const loadFlightPlans = async () => {
|
||||
}
|
||||
|
||||
const startMonitoring = async (flightPlan: any) => {
|
||||
try {
|
||||
if (!engineReady.value) {
|
||||
await fetchRuntimeTree()
|
||||
}
|
||||
} catch (err) {
|
||||
console.error('Failed to prepare decision engine', err)
|
||||
error.value = 'Entscheidungsbaum konnte nicht geladen werden.'
|
||||
return
|
||||
}
|
||||
|
||||
error.value = ''
|
||||
selectedPlan.value = flightPlan
|
||||
initializeFlight(flightPlan)
|
||||
currentScreen.value = 'monitor'
|
||||
|
||||
Reference in New Issue
Block a user