Explorar o código

fix(cockpit): 监控详情接入方式对齐参考系统 sourceType 字段

参考 city-life-line 排水视频设备页与后端 VideoDeviceRecord 的实际字段口径,
把设备的接入方式键从 accessType 对齐为 sourceType(GB28181/MANUAL),
面板展示保持「国标接入/手工接入」。仅改字段名,不改数据来源。

journey 16/16、hosts 15/15 通过;按 AGENTS.md 跳过 build/浏览器验证。
ChenJZ hai 4 horas
pai
achega
efeec7e342
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      src/modules/cockpit/components/VideoMonitorPanel.vue

+ 4 - 1
src/modules/cockpit/components/VideoMonitorPanel.vue

@@ -120,7 +120,10 @@ const ptzEnabled = computed(() => {
 const ptzReason = computed(() => state.value.cleanupError ? '会话释放未确认,暂停控制' : PTZ_UNCONFIRMED)
 // Access mode and GB identifiers come straight from the binding; blanks show as a dash.
 const ACCESS_TEXT = { GB28181: '国标接入', MANUAL: '手工接入' }
-const accessTypeText = computed(() => ACCESS_TEXT[state.value.device?.accessType] || state.value.device?.accessType || '—')
+const accessTypeText = computed(() => {
+    const type = state.value.device?.sourceType || state.value.device?.accessType
+    return ACCESS_TEXT[type] || type || '—'
+})
 const gbText = computed(() => {
     const device = state.value.device
     return device?.gbDeviceId || device?.gbChannelId