From 13ae1c92c3d605441df59fec9f1e7f48320fb3a0 Mon Sep 17 00:00:00 2001 From: Eddasol Date: Thu, 28 Nov 2024 15:28:40 +0100 Subject: [PATCH] Preselect robot if there is only one robot --- .../components/Pages/InspectionPage/ScheduleMissionDialogs.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/frontend/src/components/Pages/InspectionPage/ScheduleMissionDialogs.tsx b/frontend/src/components/Pages/InspectionPage/ScheduleMissionDialogs.tsx index 02ae3de0..ba27fc2b 100644 --- a/frontend/src/components/Pages/InspectionPage/ScheduleMissionDialogs.tsx +++ b/frontend/src/components/Pages/InspectionPage/ScheduleMissionDialogs.tsx @@ -65,6 +65,7 @@ export const ScheduleMissionDialog = (props: IProps): JSX.Element => { r.status === RobotStatus.Recharging) && r.isarConnected ) + const onSelectedRobot = (selectedRobot: Robot) => { if (filteredRobots) setSelectedRobot(selectedRobot) } @@ -151,6 +152,7 @@ export const ScheduleMissionDialog = (props: IProps): JSX.Element => { )} r.name + ' (' + r.model.type + ')'} options={filteredRobots}