From 1d22a23583538627184d7f020bffaae80644877c Mon Sep 17 00:00:00 2001 From: Matthew Morley Date: Wed, 30 Aug 2023 14:31:05 -0400 Subject: [PATCH] Add apriltag import button --- photon-client/src/components/app/photon-log-view.vue | 2 +- .../src/components/settings/DeviceControlCard.vue | 8 ++++++-- photon-client/src/components/settings/MetricsCard.vue | 4 ++-- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/photon-client/src/components/app/photon-log-view.vue b/photon-client/src/components/app/photon-log-view.vue index 7018870212..f9abe3b66c 100644 --- a/photon-client/src/components/app/photon-log-view.vue +++ b/photon-client/src/components/app/photon-log-view.vue @@ -98,7 +98,7 @@ document.addEventListener("keydown", e => { v-if="logs.length === 0" style="font-size: 18px; font-weight: 600" > - There are no Logs to show + There are no logs to show { case ImportType.NetworkConfig: settingsEndpoint = "/networkConfig"; break; + case ImportType.ApriltagFieldLayout: + settingsEndpoint = "/aprilTagFieldLayout"; + break; } axios.post(`/settings${settingsEndpoint}`, formData, { @@ -286,7 +290,7 @@ const handleSettingsImport = () => { v-model="importType" label="Type" tooltip="Select the type of settings file you are trying to upload" - :items="['All Settings', 'Hardware Config', 'Hardware Settings', 'Network Config']" + :items="['All Settings', 'Hardware Config', 'Hardware Settings', 'Network Config', 'Apriltag Layout']" :select-cols="10" /> diff --git a/photon-client/src/components/settings/MetricsCard.vue b/photon-client/src/components/settings/MetricsCard.vue index e28919b3c5..cd4bc59bad 100644 --- a/photon-client/src/components/settings/MetricsCard.vue +++ b/photon-client/src/components/settings/MetricsCard.vue @@ -65,12 +65,12 @@ const fetchMetrics = () => { if(error.request) { useStateStore().showSnackbarMessage({ color: "error", - message: "Unable to fetch Metrics! The backend didn't respond." + message: "Unable to fetch metrics! The backend didn't respond." }); } else { useStateStore().showSnackbarMessage({ color: "error", - message: "An error occurred while trying to fetch Metrics." + message: "An error occurred while trying to fetch metrics." }); } })