diff --git a/photon-client/src/stores/settings/GeneralSettingsStore.ts b/photon-client/src/stores/settings/GeneralSettingsStore.ts index f9614bcd3b..e5f3458236 100644 --- a/photon-client/src/stores/settings/GeneralSettingsStore.ts +++ b/photon-client/src/stores/settings/GeneralSettingsStore.ts @@ -28,7 +28,9 @@ export const useSettingsStore = defineStore("settings", { hardwarePlatform: undefined, mrCalWorking: true, availableModels: [], - supportedBackends: [] + supportedBackends: [], + conflictingHostname: false, + conflictingCameras: "" }, network: { ntServerAddress: "", @@ -107,7 +109,9 @@ export const useSettingsStore = defineStore("settings", { gpuAcceleration: data.general.gpuAcceleration || undefined, mrCalWorking: data.general.mrCalWorking, availableModels: data.general.availableModels || undefined, - supportedBackends: data.general.supportedBackends || [] + supportedBackends: data.general.supportedBackends || [], + conflictingHostname: data.general.conflictingHostname || false, + conflictingCameras: data.general.conflictingCameras || "" }; this.lighting = data.lighting; this.network = data.networkSettings; diff --git a/photon-client/src/types/SettingTypes.ts b/photon-client/src/types/SettingTypes.ts index 0933d6b6ee..cec92713fb 100644 --- a/photon-client/src/types/SettingTypes.ts +++ b/photon-client/src/types/SettingTypes.ts @@ -10,6 +10,8 @@ export interface GeneralSettings { mrCalWorking: boolean; availableModels: ObjectDetectionModelProperties[]; supportedBackends: string[]; + conflictingHostname: boolean; + conflictingCameras: string; } export interface ObjectDetectionModelProperties { diff --git a/photon-client/src/views/DashboardView.vue b/photon-client/src/views/DashboardView.vue index 5537394517..c42efbdf60 100644 --- a/photon-client/src/views/DashboardView.vue +++ b/photon-client/src/views/DashboardView.vue @@ -6,6 +6,7 @@ import StreamConfigCard from "@/components/dashboard/StreamConfigCard.vue"; import PipelineConfigCard from "@/components/dashboard/ConfigOptions.vue"; import { useCameraSettingsStore } from "@/stores/settings/CameraSettingsStore"; import { useStateStore } from "@/stores/StateStore"; +import { useSettingsStore } from "@/stores/settings/GeneralSettingsStore"; const cameraViewType = computed({ get: (): number[] => { @@ -50,22 +51,49 @@ const arducamWarningShown = computed(() => { ); }); +const conflictingHostnameShown = computed(() => { + return useSettingsStore().general.conflictingHostname; +}); + +const conflictingCameraShown = computed(() => { + return useSettingsStore().general.conflictingCameras.length > 0; +}); + const showCameraSetupDialog = ref(useCameraSettingsStore().needsCameraConfiguration);