diff --git a/src/components/charts/HistoryAllPrintStatus.vue b/src/components/charts/HistoryAllPrintStatus.vue index 30afc6a0..0d90803e 100644 --- a/src/components/charts/HistoryAllPrintStatus.vue +++ b/src/components/charts/HistoryAllPrintStatus.vue @@ -80,7 +80,7 @@ export default class HistoryAllPrintStatus extends Mixins(BaseMixin) { } get chart(): ECharts | null { - return this.$refs.historyAllPrintStatus ?? null + return this.$refs.historyAllPrintStatus?.chart ?? null } mounted() { diff --git a/src/components/charts/HistoryFilamentUsage.vue b/src/components/charts/HistoryFilamentUsage.vue index 46f2023a..fdc8b70a 100644 --- a/src/components/charts/HistoryFilamentUsage.vue +++ b/src/components/charts/HistoryFilamentUsage.vue @@ -110,7 +110,7 @@ export default class HistoryPrinttimeAvg extends Mixins(BaseMixin) { } get chart(): ECharts | null { - return this.$refs.historyFilamentUsage ?? null + return this.$refs.historyFilamentUsage?.chart ?? null } mounted() { diff --git a/src/components/charts/HistoryPrinttimeAvg.vue b/src/components/charts/HistoryPrinttimeAvg.vue index 591cdf2f..a13ae5f1 100644 --- a/src/components/charts/HistoryPrinttimeAvg.vue +++ b/src/components/charts/HistoryPrinttimeAvg.vue @@ -95,7 +95,7 @@ export default class HistoryPrinttimeAvg extends Mixins(BaseMixin) { } get chart(): ECharts | null { - return this.$refs.historyPrinttimeAvg ?? null + return this.$refs.historyPrinttimeAvg?.chart ?? null } mounted() { diff --git a/src/components/charts/TempChart.vue b/src/components/charts/TempChart.vue index 4edd127e..5d294235 100644 --- a/src/components/charts/TempChart.vue +++ b/src/components/charts/TempChart.vue @@ -27,8 +27,6 @@ interface echartsTooltipObj { components: {}, }) export default class TempChart extends Mixins(BaseMixin) { - convertName = convertName - declare $refs: { tempchart: any } @@ -196,7 +194,7 @@ export default class TempChart extends Mixins(BaseMixin) { } get chart(): ECharts | null { - return this.$refs.tempchart ?? null + return this.$refs.tempchart?.chart ?? null } get maxHistory() { diff --git a/src/pages/Heightmap.vue b/src/pages/Heightmap.vue index 3f3c7b7e..3943d942 100644 --- a/src/pages/Heightmap.vue +++ b/src/pages/Heightmap.vue @@ -649,7 +649,7 @@ export default class PageHeightmap extends Mixins(BaseMixin, ControlMixin) { } get chart(): ECharts | null { - return this.$refs.heightmap ?? null + return this.$refs.heightmap?.chart ?? null } get profiles() {