webapp: create interface for NtpConfig

This commit is contained in:
Thomas Basler 2022-10-17 20:04:20 +02:00
parent c52f1eeaa2
commit 05eb741833
2 changed files with 7 additions and 5 deletions

View File

@ -0,0 +1,5 @@
export interface NtpConfig {
ntp_server: string,
ntp_timezone: string,
ntp_timezone_descr: string
}

View File

@ -88,6 +88,7 @@
<script lang="ts"> <script lang="ts">
import { defineComponent } from 'vue'; import { defineComponent } from 'vue';
import BootstrapAlert from "@/components/BootstrapAlert.vue"; import BootstrapAlert from "@/components/BootstrapAlert.vue";
import type { NtpConfig } from "@/types/NtpConfig";
export default defineComponent({ export default defineComponent({
components: { components: {
@ -97,11 +98,7 @@ export default defineComponent({
return { return {
dataLoading: true, dataLoading: true,
timezoneLoading: true, timezoneLoading: true,
ntpConfigList: { ntpConfigList: {} as NtpConfig,
ntp_server: "",
ntp_timezone: "",
ntp_timezone_descr: ""
},
timezoneList: {}, timezoneList: {},
timezoneSelect: "", timezoneSelect: "",
mcuTime: new Date(), mcuTime: new Date(),