空闲面板显示和路径执行初始化

This commit is contained in:
mmc
2026-06-02 15:42:58 +08:00
parent 5f011fd435
commit 920944bfd9
4 changed files with 36 additions and 5 deletions

View File

@@ -105,10 +105,15 @@ export default function DeviceOverviewPage({ onViewStatus, selectedSn, onDeviceS
console.error('数据请求失败', err);
}
};
const freePlaneData = useMemo(() => {
if (!planedevices) return;
const data = planedevices.filter(item => item.modeStatistics !== 'running').length || 0;
return data;
}, [planedevices])
useEffect(() => {
fetchAllData();
}, [userInfo, stationId]);
}, [stationId]);
useEffect(() => {
fetchTaskStats();
}, [devicesAll.length]);
@@ -456,7 +461,7 @@ export default function DeviceOverviewPage({ onViewStatus, selectedSn, onDeviceS
}
};
fetchUavState();
}, [isUAV, selectedDevice]);
}, [selectedDevice]);
return (
<Content style={{ margin: '0 8', }}>