webapp: Added defineComponent to all components

This commit is contained in:
Thomas Basler 2022-06-21 20:27:03 +02:00
parent c8075d533f
commit cd35261570
20 changed files with 70 additions and 40 deletions

View File

@ -74,9 +74,10 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import BootstrapAlert from "@/components/partials/BootstrapAlert.vue"; import BootstrapAlert from "@/components/partials/BootstrapAlert.vue";
export default { export default defineComponent({
components: { components: {
BootstrapAlert, BootstrapAlert,
}, },
@ -133,5 +134,5 @@ export default {
); );
}, },
}, },
}; });
</script> </script>

View File

@ -80,9 +80,10 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import SparkMD5 from "spark-md5"; import SparkMD5 from "spark-md5";
export default { export default defineComponent({
data() { data() {
return { return {
loading: true, loading: true,
@ -179,5 +180,5 @@ export default {
mounted() { mounted() {
this.loading = false; this.loading = false;
}, },
}; });
</script> </script>

View File

@ -70,10 +70,11 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import InverterChannelInfo from "@/components/partials/InverterChannelInfo"; import InverterChannelInfo from "@/components/partials/InverterChannelInfo";
import bootstrap from "bootstrap/dist/js/bootstrap.js"; import bootstrap from "bootstrap/dist/js/bootstrap.js";
export default { export default defineComponent({
components: { components: {
InverterChannelInfo, InverterChannelInfo,
}, },
@ -153,5 +154,5 @@ export default {
this.isFirstFetchAfterConnect = true; this.isFirstFetchAfterConnect = true;
}, },
}, },
}; });
</script> </script>

View File

@ -110,9 +110,10 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import BootstrapAlert from "@/components/partials/BootstrapAlert.vue"; import BootstrapAlert from "@/components/partials/BootstrapAlert.vue";
export default { export default defineComponent({
components: { components: {
BootstrapAlert, BootstrapAlert,
}, },
@ -245,5 +246,5 @@ export default {
this.editInverterData.type = ""; this.editInverterData.type = "";
}, },
}, },
}; });
</script> </script>

View File

@ -211,9 +211,10 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import BootstrapAlert from "@/components/partials/BootstrapAlert.vue"; import BootstrapAlert from "@/components/partials/BootstrapAlert.vue";
export default { export default defineComponent({
components: { components: {
BootstrapAlert, BootstrapAlert,
}, },
@ -260,5 +261,5 @@ export default {
); );
}, },
}, },
}; });
</script> </script>

View File

@ -90,7 +90,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
data() { data() {
return { return {
mqttDataList: [], mqttDataList: [],
@ -106,5 +108,5 @@ export default {
.then((data) => (this.mqttDataList = data)); .then((data) => (this.mqttDataList = data));
}, },
}, },
}; });
</script> </script>

View File

@ -168,9 +168,10 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import BootstrapAlert from "@/components/partials/BootstrapAlert.vue"; import BootstrapAlert from "@/components/partials/BootstrapAlert.vue";
export default { export default defineComponent({
components: { components: {
BootstrapAlert, BootstrapAlert,
}, },
@ -217,5 +218,5 @@ export default {
); );
}, },
}, },
}; });
</script> </script>

View File

@ -15,17 +15,18 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import WifiStationInfo from "./partials/WifiStationInfo.vue"; import WifiStationInfo from "./partials/WifiStationInfo.vue";
import WifiApInfo from "./partials/WifiApInfo.vue"; import WifiApInfo from "./partials/WifiApInfo.vue";
import InterfaceStationInfo from "./partials/InterfaceStationInfo.vue"; import InterfaceStationInfo from "./partials/InterfaceStationInfo.vue";
import InterfaceApInfo from "./partials/InterfaceApInfo.vue"; import InterfaceApInfo from "./partials/InterfaceApInfo.vue";
export default { export default defineComponent({
components: { components: {
WifiStationInfo, WifiStationInfo,
WifiApInfo, WifiApInfo,
InterfaceStationInfo, InterfaceStationInfo,
InterfaceApInfo, InterfaceApInfo,
}, },
}; });
</script> </script>

View File

@ -67,9 +67,10 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import BootstrapAlert from "@/components/partials/BootstrapAlert.vue"; import BootstrapAlert from "@/components/partials/BootstrapAlert.vue";
export default { export default defineComponent({
components: { components: {
BootstrapAlert, BootstrapAlert,
}, },
@ -138,5 +139,5 @@ export default {
); );
}, },
}, },
}; });
</script> </script>

View File

@ -60,7 +60,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
data() { data() {
return { return {
ntpDataList: [], ntpDataList: [],
@ -76,5 +78,5 @@ export default {
.then((data) => (this.ntpDataList = data)); .then((data) => (this.ntpDataList = data));
}, },
}, },
}; });
</script> </script>

View File

@ -13,15 +13,16 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import HardwareInfo from "@/components/partials/HardwareInfo.vue"; import HardwareInfo from "@/components/partials/HardwareInfo.vue";
import FirmwareInfo from "@/components/partials/FirmwareInfo.vue"; import FirmwareInfo from "@/components/partials/FirmwareInfo.vue";
import MemoryInfo from "@/components/partials/MemoryInfo.vue"; import MemoryInfo from "@/components/partials/MemoryInfo.vue";
export default { export default defineComponent({
components: { components: {
HardwareInfo, HardwareInfo,
FirmwareInfo, FirmwareInfo,
MemoryInfo, MemoryInfo,
}, },
}; });
</script> </script>

View File

@ -47,7 +47,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
data() { data() {
return { return {
systemDataList: [], systemDataList: [],
@ -79,5 +81,5 @@ export default {
.then((data) => (this.systemDataList = data)); .then((data) => (this.systemDataList = data));
}, },
}, },
}; });
</script> </script>

View File

@ -25,7 +25,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
props: { props: {
name: String, name: String,
total: Number, total: Number,
@ -36,5 +38,5 @@ export default {
return Math.round((this.used / this.total) * 100); return Math.round((this.used / this.total) * 100);
}, },
}, },
}; });
</script> </script>

View File

@ -31,7 +31,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
data() { data() {
return { return {
systemDataList: [], systemDataList: [],
@ -47,5 +49,5 @@ export default {
.then((data) => (this.systemDataList = data)); .then((data) => (this.systemDataList = data));
}, },
}, },
}; });
</script> </script>

View File

@ -23,7 +23,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
data() { data() {
return { return {
networkDataList: [], networkDataList: [],
@ -39,5 +41,5 @@ export default {
.then((data) => (this.networkDataList = data)); .then((data) => (this.networkDataList = data));
}, },
}, },
}; });
</script> </script>

View File

@ -39,7 +39,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
data() { data() {
return { return {
networkDataList: [], networkDataList: [],
@ -55,5 +57,5 @@ export default {
.then((data) => (this.networkDataList = data)); .then((data) => (this.networkDataList = data));
}, },
}, },
}; });
</script> </script>

View File

@ -25,7 +25,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
props: { props: {
channelData: Object, channelData: Object,
channelNumber: Number, channelNumber: Number,
@ -35,5 +37,5 @@ export default {
return parseFloat(num).toFixed(2); return parseFloat(num).toFixed(2);
}, },
}, },
}; });
</script> </script>

View File

@ -25,9 +25,10 @@
</template> </template>
<script> <script>
import { defineComponent } from 'vue';
import FsInfo from "@/components/partials/FsInfo.vue"; import FsInfo from "@/components/partials/FsInfo.vue";
export default { export default defineComponent({
components: { components: {
FsInfo, FsInfo,
}, },
@ -46,5 +47,5 @@ export default {
.then((data) => (this.systemDataList = data)); .then((data) => (this.systemDataList = data));
}, },
}, },
}; });
</script> </script>

View File

@ -36,7 +36,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
data() { data() {
return { return {
networkDataList: [], networkDataList: [],
@ -52,5 +54,5 @@ export default {
.then((data) => (this.networkDataList = data)); .then((data) => (this.networkDataList = data));
}, },
}, },
}; });
</script> </script>

View File

@ -40,7 +40,9 @@
</template> </template>
<script> <script>
export default { import { defineComponent } from 'vue';
export default defineComponent({
data() { data() {
return { return {
networkDataList: [], networkDataList: [],
@ -69,5 +71,5 @@ export default {
return quality; return quality;
}, },
}, },
}; });
</script> </script>