webapp: create interface for NetworkConfig
This commit is contained in:
parent
a9a6a40eb8
commit
c52f1eeaa2
11
webapp/src/types/NetworkkConfig.ts
Normal file
11
webapp/src/types/NetworkkConfig.ts
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
export interface NetworkConfig {
|
||||||
|
ssid: string,
|
||||||
|
password: string,
|
||||||
|
hostname: string,
|
||||||
|
dhcp: boolean,
|
||||||
|
ipaddress: string,
|
||||||
|
netmask: string,
|
||||||
|
gateway: string,
|
||||||
|
dns1: string,
|
||||||
|
dns2: string
|
||||||
|
}
|
||||||
@ -114,6 +114,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 { NetworkConfig } from "@/types/NetworkkConfig";
|
||||||
|
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
components: {
|
components: {
|
||||||
@ -122,17 +123,7 @@ export default defineComponent({
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
dataLoading: true,
|
dataLoading: true,
|
||||||
networkConfigList: {
|
networkConfigList: {} as NetworkConfig,
|
||||||
ssid: "",
|
|
||||||
password: "",
|
|
||||||
hostname: "",
|
|
||||||
dhcp: false,
|
|
||||||
ipaddress: "",
|
|
||||||
netmask: "",
|
|
||||||
gateway: "",
|
|
||||||
dns1: "",
|
|
||||||
dns2: ""
|
|
||||||
},
|
|
||||||
alertMessage: "",
|
alertMessage: "",
|
||||||
alertType: "info",
|
alertType: "info",
|
||||||
showAlert: false,
|
showAlert: false,
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user