From 474783457240f62d4f926e628fea2abb1c4b8b0d Mon Sep 17 00:00:00 2001
From: wei <kaede@kaededeMacBook-Air.local>
Date: 星期一, 11 十月 2021 14:53:37 +0800
Subject: [PATCH] spk更新异常,安防中心传感器状态无显示

---
 HDL_ON/Entity/Function/SecurityAlarm.cs |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/HDL_ON/Entity/Function/SecurityAlarm.cs b/HDL_ON/Entity/Function/SecurityAlarm.cs
index 902b12c..68cc8d8 100644
--- a/HDL_ON/Entity/Function/SecurityAlarm.cs
+++ b/HDL_ON/Entity/Function/SecurityAlarm.cs
@@ -427,11 +427,11 @@
                 case SPK.SensorSmoke:
                     foreach (var con in condition)
                     {
-                        if (con.value == "true")
+                        if (con.value == "true" || con.value == "alarm")
                         {
                             text += Language.StringByID(StringId.InAlarm) + " ";
                         }
-                        else if (con.value == "false")
+                        else if (con.value == "false" || con.value == "normal")
                         {
                             text += Language.StringByID(StringId.Normal) + " ";
                         }
@@ -453,11 +453,11 @@
                 case SPK.SensorWater:
                     foreach (var con in condition)
                     {
-                        if (con.value == "true")
+                        if (con.value == "true" || con.value == "alarm")
                         {
                             text += Language.StringByID(StringId.WaterLeakage) + " ";
                         }
-                        else if (con.value == "false")
+                        else if (con.value == "false" || con.value == "normal")
                         {
                             text += Language.StringByID(StringId.Normal) + " ";
                         }
@@ -466,11 +466,11 @@
                 case SPK.SensorDoorWindow:
                     foreach (var con in condition)
                     {
-                        if (con.value == "true")
+                        if (con.value == "true" || con.value == "open")
                         {
                             text += Language.StringByID(StringId.Open) + " ";
                         }
-                        else if (con.value == "false")
+                        else if (con.value == "false" || con.value == "close")
                         {
                             text += Language.StringByID(StringId.Close) + " ";
                         }

--
Gitblit v1.8.0