This commit is contained in:
2025-10-13 23:33:56 +05:30
parent ec248f9c95
commit 5b46ac98ad
2 changed files with 9 additions and 1 deletions

Binary file not shown.

View File

@@ -76,7 +76,15 @@
}
function getMatchingSpotsForCallsign(callsign) {
return watchlistSpots.filter(s => s.dx === callsign || s.dx.startsWith(callsign));
const spots = watchlistSpots.filter(s => s.dx === callsign || s.dx.startsWith(callsign));
// ✅ Trier les spots par heure décroissante (plus récent en premier)
return spots.sort((a, b) => {
// Comparer les heures UTC (format "HH:MM")
const timeA = a.utcTime || "00:00";
const timeB = b.utcTime || "00:00";
return timeB.localeCompare(timeA);
});
}
async function addToWatchlist() {