From ea35de5eb534fcea20fc6024517f5895a4b98160 Mon Sep 17 00:00:00 2001 From: James Pattinson Date: Fri, 12 Dec 2025 12:24:33 -0500 Subject: [PATCH] Cancel Confirm --- web/admin.html | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/web/admin.html b/web/admin.html index e83ae1e..f131aa7 100644 --- a/web/admin.html +++ b/web/admin.html @@ -2793,6 +2793,13 @@ async function updateLocalFlightStatusFromTable(flightId, status) { if (!accessToken) return; + // Show confirmation for cancel actions + if (status === 'CANCELLED') { + if (!confirm('Are you sure you want to cancel this flight? This action cannot be easily undone.')) { + return; + } + } + try { const response = await fetch(`/api/v1/local-flights/${flightId}/status`, { method: 'PATCH', @@ -2841,6 +2848,13 @@ async function updateLocalFlightStatus(status) { if (!currentLocalFlightId || !accessToken) return; + // Show confirmation for cancel actions + if (status === 'CANCELLED') { + if (!confirm('Are you sure you want to cancel this flight? This action cannot be easily undone.')) { + return; + } + } + try { const response = await fetch(`/api/v1/local-flights/${currentLocalFlightId}/status`, { method: 'PATCH',