mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
Rename function
This commit is contained in:
parent
6f2c5ac5f3
commit
377048b90a
|
@ -9,7 +9,7 @@ import { GridStack } from "gridstack";
|
|||
import { useStateStore } from "../store/stateStore.js";
|
||||
const state = useStateStore(pinia);
|
||||
import { setModemFrequency } from "../js/api";
|
||||
import { saveSettingsToConfig, settingsStore } from "../store/settingsStore";
|
||||
import { saveLocalSettingsToConfig, settingsStore } from "../store/settingsStore";
|
||||
|
||||
import active_heard_stations from "./grid/grid_active_heard_stations.vue";
|
||||
import mini_heard_stations from "./grid/grid_active_heard_stations_mini.vue";
|
||||
|
@ -306,7 +306,7 @@ function saveGridLayout()
|
|||
cfg[i] = [items.value[i].x, items.value[i].y, items.value[i].w,items.value[i].h, widget ];
|
||||
}
|
||||
settingsStore.local.grid_layout=JSON.stringify(cfg);
|
||||
saveSettingsToConfig();
|
||||
saveLocalSettingsToConfig();
|
||||
}
|
||||
|
||||
function addNewWidget2(componentToAdd :gridWidget,saveToConfig :boolean) {
|
||||
|
|
|
@ -102,7 +102,7 @@ export const settingsStore = reactive({
|
|||
|
||||
//Save settings for GUI to config file
|
||||
settingsStore.local = nconf.get("local");
|
||||
saveSettingsToConfig();
|
||||
saveLocalSettingsToConfig();
|
||||
|
||||
export function onChange() {
|
||||
setConfig(settingsStore.remote).then((conf) => {
|
||||
|
@ -118,11 +118,11 @@ export function getRemote() {
|
|||
|
||||
watch(settingsStore.local, (oldValue, newValue) => {
|
||||
//This function watches for changes, and triggers a save of local settings
|
||||
saveSettingsToConfig();
|
||||
saveLocalSettingsToConfig();
|
||||
});
|
||||
|
||||
export function saveSettingsToConfig() {
|
||||
export function saveLocalSettingsToConfig() {
|
||||
nconf.set("local", settingsStore.local);
|
||||
nconf.save();
|
||||
console.log("Settings saved!");
|
||||
//console.log("Settings saved!");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue