mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
[CodeFactor] Apply fixes
This commit is contained in:
parent
436420f854
commit
19eb6ee6e9
|
@ -4,10 +4,14 @@ import pinia from "../../store/index";
|
|||
setActivePinia(pinia);
|
||||
|
||||
import { sendModemCQ } from "../../js/api.js";
|
||||
|
||||
</script>
|
||||
<template>
|
||||
<div class="fill h-100" style="width: calc(100% - 24px);">
|
||||
<a class="btn btn-sm btn-secondary d-flex justify-content-center align-items-center object-fill border rounded w-100 h-100" @click="sendModemCQ" title="Send a CQ call!">CQ</a>
|
||||
<div class="fill h-100" style="width: calc(100% - 24px)">
|
||||
<a
|
||||
class="btn btn-sm btn-secondary d-flex justify-content-center align-items-center object-fill border rounded w-100 h-100"
|
||||
@click="sendModemCQ"
|
||||
title="Send a CQ call!"
|
||||
>CQ</a
|
||||
>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
@ -33,7 +33,7 @@ var dxcallPing = ref("");
|
|||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
style="min-width: 3rem; text-transform: uppercase; height: 31px;"
|
||||
style="min-width: 3rem; text-transform: uppercase; height: 31px"
|
||||
placeholder="DXcall"
|
||||
pattern="[A-Z]*"
|
||||
maxlength="11"
|
||||
|
@ -78,8 +78,6 @@ var dxcallPing = ref("");
|
|||
>
|
||||
Call CQ
|
||||
</button>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
@ -7,7 +7,6 @@ setActivePinia(pinia);
|
|||
import { useStateStore } from "../../store/stateStore.js";
|
||||
const state = useStateStore(pinia);
|
||||
|
||||
|
||||
function set_hamlib_mode() {
|
||||
setModemRigMode(state.mode);
|
||||
}
|
||||
|
@ -29,11 +28,20 @@ function set_hamlib_rf_level() {
|
|||
<div class="me-2">
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-text">QRG</span>
|
||||
<span class="input-group-text">{{ state.frequency / 1000 }} kHz</span>
|
||||
<span class="input-group-text"
|
||||
>{{ state.frequency / 1000 }} kHz</span
|
||||
>
|
||||
|
||||
<button class="btn btn-secondary dropdown-toggle" v-bind:class="{
|
||||
<button
|
||||
class="btn btn-secondary dropdown-toggle"
|
||||
v-bind:class="{
|
||||
disabled: state.hamlib_status === 'disconnected',
|
||||
}" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvasFrequency" aria-controls="offcanvasExample"></button>
|
||||
}"
|
||||
type="button"
|
||||
data-bs-toggle="offcanvas"
|
||||
data-bs-target="#offcanvasFrequency"
|
||||
aria-controls="offcanvasExample"
|
||||
></button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -8,17 +8,26 @@ const state = useStateStore(pinia);
|
|||
</script>
|
||||
<template>
|
||||
<div class="w-100">
|
||||
<div class="input-group input-group-sm" style="width: calc(100% - 24px);">
|
||||
|
||||
|
||||
<div class="input-group input-group-sm" style="width: calc(100% - 24px)">
|
||||
<span class="input-group-text">Hz</span>
|
||||
|
||||
|
||||
<input type="text" class="form-control" style="min-width: 3em;" placeholder="mycall" v-model=state.frequency readonly>
|
||||
<a class="btn btn-secondary dropdown-toggle" v-bind:class="{
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
style="min-width: 3em"
|
||||
placeholder="mycall"
|
||||
v-model="state.frequency"
|
||||
readonly
|
||||
/>
|
||||
<a
|
||||
class="btn btn-secondary dropdown-toggle"
|
||||
v-bind:class="{
|
||||
disabled: state.hamlib_status === 'disconnected',
|
||||
}" type="button" data-bs-toggle="offcanvas" data-bs-target="#offcanvasFrequency"></a>
|
||||
|
||||
}"
|
||||
type="button"
|
||||
data-bs-toggle="offcanvas"
|
||||
data-bs-target="#offcanvasFrequency"
|
||||
></a>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
@ -11,20 +11,34 @@ import { useStateStore } from "../../store/stateStore.js";
|
|||
|
||||
const state = useStateStore(pinia);
|
||||
|
||||
function updateMyCall()
|
||||
{
|
||||
function updateMyCall() {
|
||||
setConfig();
|
||||
}
|
||||
|
||||
</script>
|
||||
<template>
|
||||
<div class="w-100">
|
||||
<div class="input-group input-group-sm" style="width: calc(100% - 24px);">
|
||||
|
||||
<input type="text" class="form-control" style="min-width: 3em;" placeholder="mycall" v-model=settings.remote.STATION.mycall>
|
||||
<div class="input-group input-group-sm" style="width: calc(100% - 24px)">
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
style="min-width: 3em"
|
||||
placeholder="mycall"
|
||||
v-model="settings.remote.STATION.mycall"
|
||||
/>
|
||||
<span class="input-group-text">-</span>
|
||||
<input type="text" class="form-control" style="min-width: 2em;max-width: 2.5em;" placeholder="id" v-model=settings.remote.STATION.myssid>
|
||||
<a class="btn btn-sm btn-secondary" title="Apply changes to callsign/ssid" @click="updateMyCall"><i class="bi bi-check"></i></a>
|
||||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
style="min-width: 2em; max-width: 2.5em"
|
||||
placeholder="id"
|
||||
v-model="settings.remote.STATION.myssid"
|
||||
/>
|
||||
<a
|
||||
class="btn btn-sm btn-secondary"
|
||||
title="Apply changes to callsign/ssid"
|
||||
@click="updateMyCall"
|
||||
><i class="bi bi-check"></i
|
||||
></a>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
@ -18,7 +18,7 @@ var dxcallPing = ref("");
|
|||
<input
|
||||
type="text"
|
||||
class="form-control"
|
||||
style="min-width: 3rem; text-transform: uppercase; height: 31px;"
|
||||
style="min-width: 3rem; text-transform: uppercase; height: 31px"
|
||||
placeholder="DXcall"
|
||||
pattern="[A-Z]*"
|
||||
maxlength="11"
|
||||
|
@ -28,7 +28,7 @@ var dxcallPing = ref("");
|
|||
/>
|
||||
<a
|
||||
class="btn btn-sm btn-secondary"
|
||||
style="max-width: 3em;"
|
||||
style="max-width: 3em"
|
||||
id="sendPing"
|
||||
type="button"
|
||||
data-bs-placement="bottom"
|
||||
|
|
|
@ -7,5 +7,10 @@ import { useStateStore } from "../../store/stateStore.js";
|
|||
const state = useStateStore(pinia);
|
||||
</script>
|
||||
<template>
|
||||
<div class="d-flex justify-content-center align-items-center object-fill border rounded w-100 h-100" :class="state.ptt_state === true ? 'text-bg-warning' : 'text-bg-light'">TX</div>
|
||||
<div
|
||||
class="d-flex justify-content-center align-items-center object-fill border rounded w-100 h-100"
|
||||
:class="state.ptt_state === true ? 'text-bg-warning' : 'text-bg-light'"
|
||||
>
|
||||
TX
|
||||
</div>
|
||||
</template>
|
||||
|
|
|
@ -114,12 +114,11 @@ export function getModemState() {
|
|||
}
|
||||
|
||||
export function setModemFrequency(newFrequency) {
|
||||
console.error("setModemFrequency needs implemented")
|
||||
console.error("setModemFrequency needs implemented");
|
||||
}
|
||||
export function setModemRigMode(mode) {
|
||||
console.error("setModemRigMode needs implemented")
|
||||
console.error("setModemRigMode needs implemented");
|
||||
}
|
||||
export function setModemRigPowerLvl(power) {
|
||||
console.error("setModemRigPowerLvl needs implemented")
|
||||
console.error("setModemRigPowerLvl needs implemented");
|
||||
}
|
||||
;
|
|
@ -21,8 +21,7 @@ export function initWaterfall(id) {
|
|||
|
||||
export function addDataToWaterfall(data) {
|
||||
data = JSON.parse(data);
|
||||
if (data.constructor !== Array)
|
||||
return;
|
||||
if (data.constructor !== Array) return;
|
||||
spectrums.forEach((element) => {
|
||||
//console.log(element);
|
||||
element.addData(data);
|
||||
|
|
Loading…
Reference in a new issue