From 05b395de8d54e71512ccd2fec9f8af9156335947 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=99=BD=E5=87=A4=E5=90=89?= Date: Thu, 3 Jul 2025 20:37:35 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E4=BF=AE=E5=A4=8D=E6=B5=8B=E8=AF=95?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E7=94=B5=E6=B5=81=E6=98=BE=E7=A4=BA=E6=B2=A1?= =?UTF-8?q?=E6=9C=89=E4=BF=9D=E7=95=99=E5=B0=8F=E6=95=B0=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/debug/index.vue | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/views/debug/index.vue b/src/views/debug/index.vue index 3d1983f..28ccf57 100644 --- a/src/views/debug/index.vue +++ b/src/views/debug/index.vue @@ -13,6 +13,11 @@ const h2O2SensorData = ref(homeStore.h2O2SensorData const sprayPumpGpmValue = ref(5) const airLeakDetectTestMode = ref('disinfection') +const formatValue = (v?: number) => + v === 0 || v == null + ? '--' + : roundNumber(v, 2) + watchEffect(() => { const hdData = homeStore.h2O2SensorData if (hdData && hdData.length) { @@ -194,21 +199,21 @@ const printerDoTest = () => {
空压机电流 - {{ debugStore.debugPageState?.airCompressorCurrent ?? '--' }} + {{ formatValue(debugStore.debugPageState?.airCompressorCurrent) }} A
风机电流 - {{ debugStore.debugPageState?.blowerCurrent ?? '--' }} + {{ formatValue(debugStore.debugPageState?.blowerCurrent) }} A
加热片电流 - {{ debugStore.debugPageState?.heaterCurrent ?? '--' }} + {{ formatValue(debugStore.debugPageState?.heaterCurrent) }} A