From c1020ac702abc42cdf50730bf346323c1c1b1683 Mon Sep 17 00:00:00 2001 From: Shawn Date: Wed, 20 May 2026 17:55:16 -0400 Subject: [PATCH] =?UTF-8?q?feat:=20add=20=F0=9F=93=8D=20GPS=20button=20nex?= =?UTF-8?q?t=20to=20parking=5Flocation=20to=20fill=20current=20coordinates?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- static/index.html | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/static/index.html b/static/index.html index 29f2579..1b060b0 100644 --- a/static/index.html +++ b/static/index.html @@ -2693,11 +2693,6 @@ const asset = await api(`/api/assets/search?machine_id=${encodeURIComponent(machineId)}`); autoCheckin(asset.id); showScannedAsset(asset); - // F1: Auto check-in when scanning an existing asset - AppState.currentAssetId = asset.id; - autoCheckin(asset.id); - setScanStatus(`Checked in: ${asset.name}`, 'success'); - document.getElementById('checkinCard').style.display = 'none'; } catch (e) { if (e.message === 'Asset not found' || e.message.includes('404')) { showNewAssetForm(machineId); @@ -3443,6 +3438,14 @@ dirBtn.style.display = 'none'; } + // Navigate button — show when asset has GPS and user has GPS + const navBtn = document.getElementById('detailNavigateBtn'); + if (a.latitude != null && a.longitude != null && AppState.gpsLat != null) { + navBtn.style.display = 'inline-flex'; + } else { + navBtn.style.display = 'none'; + } + // Keys + Badges const keys = a.keys || []; const badges = a.badges || (Array.isArray(a.badge_names) ? a.badge_names : []);