From 885282ea7f3977668b19fdd2258c484e7f0dc368 Mon Sep 17 00:00:00 2001 From: nocnico Date: Mon, 2 Jun 2025 22:26:41 +0200 Subject: [PATCH] Fix AircraftMarker SDS Form avail for Everyone --- .../map/_components/AircraftMarkerTabs.tsx | 118 +++++++++--------- 1 file changed, 62 insertions(+), 56 deletions(-) diff --git a/apps/dispatch/app/_components/map/_components/AircraftMarkerTabs.tsx b/apps/dispatch/app/_components/map/_components/AircraftMarkerTabs.tsx index 9554bf2b..9e305161 100644 --- a/apps/dispatch/app/_components/map/_components/AircraftMarkerTabs.tsx +++ b/apps/dispatch/app/_components/map/_components/AircraftMarkerTabs.tsx @@ -290,6 +290,8 @@ const SDSTab = ({ const [note, setNote] = useState(""); const queryClient = useQueryClient(); + const dispatcherConnected = useDispatchConnectionStore((s) => s.status) === "connected"; + const sendSdsMutation = useMutation({ mutationFn: async ({ id, message }: { id: number; message: MissionSdsLog }) => { await sendSdsMessageAPI(id, message); @@ -309,65 +311,69 @@ const SDSTab = ({ return (
-
- {!isChatOpen ? ( - - ) : ( -
- setNote(e.target.value)} - /> - + ) : ( +
+ setNote(e.target.value)} + /> + + - + }} + > + + +
+ )}
- )} -
-
+
+
+ )}
    {log.map((entry, index) => { const sdsEntry = entry as MissionSdsLog;