From 48ba446936b51fffafa7c3600c0dadc6ac0e8c20 Mon Sep 17 00:00:00 2001 From: 陈嘉乐 <cjl@hdlchina.com.cn> Date: 星期五, 10 七月 2020 10:52:13 +0800 Subject: [PATCH] 2020-07-10-01 --- ZigbeeApp/Shared/Phone/UserCenter/Device/AirConditioner/AirConditionerModeForm.cs | 21 +++++++++++++++++---- 1 files changed, 17 insertions(+), 4 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/AirConditioner/AirConditionerModeForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/AirConditioner/AirConditionerModeForm.cs index 1cdb3cf..e0c6eb5 100755 --- a/ZigbeeApp/Shared/Phone/UserCenter/Device/AirConditioner/AirConditionerModeForm.cs +++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/AirConditioner/AirConditionerModeForm.cs @@ -52,7 +52,7 @@ } /// <summary> - /// 鍒濆鍖栦腑閮ㄤ俊鎭� + /// 鍒濆鍖栦腑閮ㄤ俊鎭� 鈽嗏槅鈽嗏槅鈽� /// </summary> private void InitMiddleFrame() { @@ -106,7 +106,7 @@ var btnOk = new BottomClickButton(); btnOk.TextID = R.MyInternationalizationString.uSave; bodyFrameLayout.AddChidren(btnOk); - btnOk.ButtonClickEvent += async (sender, e) => + btnOk.ButtonClickEvent += (sender, e) => { if (this.oldReportValue == this.reportValue) { @@ -116,7 +116,7 @@ } //灏嗕簩杩涘埗杞崲涓哄崄杩涘埗 var data = Convert.ToInt32(this.fixValue + this.reportValue, 2); - var result = await HdlDeviceAirConditionerLogic.Current.SetAcModeSupport(deviceAc, data); + var result = HdlDeviceAirConditionerLogic.Current.SetAcModeSupport(deviceAc, data); if (result == true) { //鏇存敼缂撳瓨 @@ -181,10 +181,23 @@ #region 鈻� 璇诲彇绌鸿皟鑷畾涔夋ā寮廮________________ /// <summary> - /// 璇诲彇绌鸿皟鑷畾涔夋ā寮� + /// 璇诲彇绌鸿皟鑷畾涔夋ā寮� 鈽嗏槅鈽嗏槅鈽� /// </summary> private void ReadAirConditionerModeSupport() { + //濡傛灉鏄櫄鎷熶綇瀹� + if (Common.Config.Instance.Home.IsVirtually == true) + { + var data = ModelData.DeviceModelDataLogic.Current.GetAcModeSupport(deviceAc); + //杞崲涓轰簩杩涘埗 + var value = Convert.ToString(data, 2).PadLeft(16, '0'); + //杩欎簲涓缃槸鏀惧湪鍚庨潰鐨� + this.fixValue = value.Substring(0, value.Length - 5); + this.reportValue = value.Substring(this.fixValue.Length); + oldReportValue = reportValue; + return; + } + string mainkeys = Common.LocalDevice.Current.GetDeviceMainKeys(deviceAc); HdlGatewayReceiveLogic.Current.AddAttributeEvent("ReadAirConditionerModeSupport", ReceiveComandDiv.A璁惧灞炴�т笂鎶�, (report) => { -- Gitblit v1.8.0