From efad979b6fae76fb37a4de7e94e6bac0a85cb72c Mon Sep 17 00:00:00 2001 From: JLChen <551775569@qq.com> Date: 星期二, 30 十一月 2021 13:14:28 +0800 Subject: [PATCH] 2021-11-30 1.修复乐橙Android,没调用拒接接口问题。 --- HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs | 21 ++++++++++++++++++--- 1 files changed, 18 insertions(+), 3 deletions(-) diff --git a/HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs b/HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs index 5adc74f..996a4e5 100644 --- a/HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs +++ b/HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs @@ -26,6 +26,7 @@ Function function; List<Function> showFunctions; + List<Function> sensorList; /// <summary> /// 褰撳墠鏌ヨ绫诲瀷 /// </summary> @@ -45,6 +46,17 @@ { bodyView = this; function = ss; + showFunctions = new List<Function>(); + showFunctions.Add(ss); + sensorList = FunctionList.List.GetEnvirSensorsList(); + } + + + public EnvironmentalSensorPage(Function ss,List<Function> functions) + { + bodyView = this; + function = ss; + sensorList = functions; showFunctions = new List<Function>(); showFunctions.Add(ss); } @@ -644,9 +656,8 @@ bool initTitleButton = true; - var tempList = FunctionList.List.GetEnvirSensorsList(); - foreach (var tempSensor in tempList) + foreach (var tempSensor in sensorList) { if (tempSensor.sid == function.sid) { @@ -850,7 +861,11 @@ } var sensorType = sr.spk.Split(".")[1]; - var queryType = sr.GetAttrState("spk")==null? "value": sr.GetAttrState("spk"); + var queryType = sr.GetAttrState("spk").ToString(); + if(queryType == "0") + { + queryType = "value"; + } var revertObj = new HttpServerRequest().GetSensorHistory(curQueryType, sr.deviceId, queryType); if (revertObj != null) -- Gitblit v1.8.0