feat(cat): MY_RIG follows the radio that is connected

With one rig, MY_RIG belonged in Operating conditions and nowhere else.
With several, that becomes the wrong place: operating conditions describe
a PLAN — 'on 20 m I use the beam and the 7300' — while the question a
logged QSO asks is which radio was keying.

So each saved radio carries its own MY_RIG, consulted BEFORE the per-band
station. When the two disagree — a second rig borrowed for one evening on
20 m — the one that is transmitting is the true answer.

Left empty it changes nothing at all: the old chain (band default, then
the profile's rig) answers exactly as it did, which is what every
single-radio station will keep doing without touching a setting.
This commit is contained in:
2026-08-27 01:03:27 +02:00
parent 9d21af9f7c
commit f98a831195
5 changed files with 57 additions and 3 deletions
+12
View File
@@ -3266,7 +3266,19 @@ function SettingsModalImpl({ onClose, onSaved, initialSection, onMainPaneChanged
<Trash2 className="size-3.5" />
</Button>
</div>
{/* MY_RIG follows the radio, not the profile.
Operating conditions describe a PLAN "on 20 m I use the beam
and the 7300" while this is the fact of which rig is keying.
Empty leaves the old chain alone. */}
<div className="flex items-center gap-2">
<Label className="shrink-0 w-24">{t('cat.radioMyRig')}</Label>
<Input className="h-9 flex-1" placeholder={t('cat.radioMyRigPh')}
value={(radios.find((r: any) => r.id === activeRadio)?.my_rig) ?? ''}
onChange={(e) => setRadios((l) => l.map((r: any) => r.id === activeRadio ? { ...r, my_rig: e.target.value } : r))}
onBlur={() => { SaveRadios(radios as any).catch(() => {}); }} />
</div>
<p className="text-[11px] text-muted-foreground">{t('cat.radioHint')}</p>
<p className="text-[11px] text-muted-foreground">{t('cat.radioMyRigHint')}</p>
</div>
<label className="flex items-center gap-2 text-sm cursor-pointer">
File diff suppressed because one or more lines are too long
+2
View File
@@ -3573,6 +3573,7 @@ export namespace main {
id: string;
name: string;
settings: CATSettings;
my_rig: string;
static createFrom(source: any = {}) {
return new RadioConfig(source);
@@ -3583,6 +3584,7 @@ export namespace main {
this.id = source["id"];
this.name = source["name"];
this.settings = this.convertValues(source["settings"], CATSettings);
this.my_rig = source["my_rig"];
}
convertValues(a: any, classs: any, asMap: boolean = false): any {