mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
preselect rigctld device
This commit is contained in:
parent
df95f4b82c
commit
df3be3134d
2 changed files with 9 additions and 2 deletions
|
@ -20,7 +20,6 @@ function startStopRigctld() {
|
||||||
|
|
||||||
settings.hamlib_deviceport = (<HTMLInputElement>document.getElementById("hamlib_deviceport")).value;
|
settings.hamlib_deviceport = (<HTMLInputElement>document.getElementById("hamlib_deviceport")).value;
|
||||||
|
|
||||||
|
|
||||||
startRigctld();
|
startRigctld();
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -81,7 +81,15 @@ export const useSettingsStore = defineStore("settingsStore", () => {
|
||||||
function getSerialDevices() {
|
function getSerialDevices() {
|
||||||
var html = "";
|
var html = "";
|
||||||
for (var key in serial_devices.value) {
|
for (var key in serial_devices.value) {
|
||||||
html += `<option value="${serial_devices.value[key]["port"]}">${serial_devices.value[key]["port"]} - ${serial_devices.value[key]["description"]}</option>`;
|
|
||||||
|
let selected = ''
|
||||||
|
if (serial_devices.value[key]["name"] == hamlib_deviceport){
|
||||||
|
selected = "selected"
|
||||||
|
} else {
|
||||||
|
selected = ''
|
||||||
|
}
|
||||||
|
|
||||||
|
html += `<option value="${serial_devices.value[key]["port"]}" ${selected}>${serial_devices.value[key]["port"]} - ${serial_devices.value[key]["description"]}</option>`;
|
||||||
}
|
}
|
||||||
return html;
|
return html;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue