add icaoBlacklist

This commit is contained in:
Matthias Wirth
2024-07-20 23:12:45 +02:00
parent e0e2e21988
commit a36d699fa8
4 changed files with 15 additions and 1 deletions

View File

@@ -13,6 +13,7 @@
- icao=icao - selects and isolates the selected plane(s). Separate multiple with commas.
- noIsolation - show other planes and not only the ones selected by ?icao
- icaoFilter=hex1,hex2,hex3 - Only show the mentioned hex IDs, no other aircraft will ever be displayed
- icaoBlacklist=hex1,hex2,hex3 - Never show the mentioned hex IDs
- reg=registration - Direct link to specific aircraft registration(s). Separate multiple with commas. ?icao is preferred as this option takes longer to load.
- filterAltMin=500 - filter minimum altitute to 500 ft
- filterAltMax=5000 - filter maximum altitute to 5000 ft

View File

@@ -369,6 +369,10 @@ HideCols = [
// aiscatcher_server = "http://192.168.1.113:8100"; // update with your server address
// aiscatcher_refresh = 15; // refresh interval in seconds
// icaoFilter = [ "123456", "888888" ]; // only show these icaos
// icaoBlacklist = [ "123456", "888888" ]; // never show these icaos
/*
tableColors = {
unselected: {

View File

@@ -379,6 +379,9 @@ let audio_url = ""; // show html5 audio player for this URL
let aiscatcher_server = "";
let aiscatcher_refresh = 15;
let icaoFilter = null;
let icaoBlacklist = null;
// legacy variables
let OutlineMlatColor = null;

View File

@@ -82,7 +82,6 @@ let pendingFetches = 0;
let firstFetch = true;
let debugCounter = 0;
let pathName = window.location.pathname.replace(/\/+/, '/') || "/";
let icaoFilter = null;
let sourcesFilter = null;
let sources = ['adsb', ['uat', 'adsr'], 'mlat', 'tisb', 'modeS', 'other', 'adsc'];
let flagFilter = null;
@@ -194,6 +193,9 @@ function processAircraft(ac, init, uat) {
if (icaoFilter && !icaoFilter.includes(hex))
return;
if (icaoBlacklist && icaoBlacklist.includes(hex))
return;
const type = isArray ? ac[7] : ac.type;
if (g.historyKeep && !g.historyKeep[hex] && type != 'adsc') {
return;
@@ -1047,6 +1049,10 @@ function earlyInitPage() {
icaoFilter = value.toLowerCase().split(',');
}
if (value = usp.get('icaoBlacklist')) {
icaoBlacklist = value.toLowerCase().split(',');
}
if (value = usp.getFloat('filterMaxRange')) {
filterMaxRange = value;
}