fix: bug where worked filter did not work in cluster
This commit is contained in:
@@ -2316,8 +2316,14 @@ export default function App() {
|
|||||||
}
|
}
|
||||||
if (clusterStatusFilter.size > 0) {
|
if (clusterStatusFilter.size > 0) {
|
||||||
const k = spotStatusKey(s.dx_call, s.band ?? '', s.comment ?? '', s.freq_hz);
|
const k = spotStatusKey(s.dx_call, s.band ?? '', s.comment ?? '', s.freq_hz);
|
||||||
const st = spotStatus[k]?.status || '';
|
const e = spotStatus[k];
|
||||||
if (!clusterStatusFilter.has(st as SpotStatusKey)) return false;
|
const st = (e?.status || '') as SpotStatusKey;
|
||||||
|
// A previously-worked call counts as WORKED for filtering even when its
|
||||||
|
// entity status is still new-band/new-slot (the grid flags it WKD CALL),
|
||||||
|
// matching the "Hide worked" toggle. Additive: it still matches its own
|
||||||
|
// entity status too, so it stays visible under NEW BAND / NEW SLOT.
|
||||||
|
const matches = clusterStatusFilter.has(st) || (!!e?.worked_call && clusterStatusFilter.has('worked'));
|
||||||
|
if (!matches) return false;
|
||||||
}
|
}
|
||||||
if (clusterHideWorked) {
|
if (clusterHideWorked) {
|
||||||
const k = spotStatusKey(s.dx_call, s.band ?? '', s.comment ?? '', s.freq_hz);
|
const k = spotStatusKey(s.dx_call, s.band ?? '', s.comment ?? '', s.freq_hz);
|
||||||
|
|||||||
Reference in New Issue
Block a user