From 2bec9c838d2d688025698de8ec1de401ffd7dd1f Mon Sep 17 00:00:00 2001
From: wxr <464027401@qq.com>
Date: 星期二, 11 八月 2020 14:13:55 +0800
Subject: [PATCH] 20200811

---
 HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs |   25 ++++++++++++++++++++-----
 1 files changed, 20 insertions(+), 5 deletions(-)

diff --git a/HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs b/HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs
index b12f9e7..5f8cf52 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/FoolHeating/FloorHeatingPageBLL.cs
@@ -74,7 +74,10 @@
                 fh.curTemp--;
                 arcBar.Progress = fh.curTemp;
                 btnTemp.Text = fh.curTemp.ToString();
-                Control.Send(CommandType_A.write, fh);
+                //Control.Send(CommandType_A.write, fh);
+                System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
+                d.Add("temp", fh.curTemp.ToString());
+                Control.SendWriteCommand(fh, d);
             };
             btnPlus.MouseUpEventHandler = (sender, e) =>
             {
@@ -85,13 +88,19 @@
                 fh.curTemp++;
                 arcBar.Progress = fh.curTemp;
                 btnTemp.Text = fh.curTemp.ToString();
-                Control.Send(CommandType_A.write, fh);
+                //Control.Send(CommandType_A.write, fh);
+                System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
+                d.Add("temp", fh.curTemp.ToString());
+                Control.SendWriteCommand(fh, d);
             };
             arcBar.OnStopTrackingTouchEvent = (sender, e) =>
             {
                 fh.curTemp = arcBar.Progress;
                 btnTemp.Text = fh.curTemp.ToString();
-                Control.Send(CommandType_A.write, fh);
+                //Control.Send(CommandType_A.write, fh);
+                System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
+                d.Add("temp", fh.curTemp.ToString());
+                Control.SendWriteCommand(fh, d);
             };
             arcBar.OnProgressChangedEvent = (sender, e) =>
             {
@@ -113,7 +122,10 @@
             {
                 btnSwitch.IsSelected = !btnSwitch.IsSelected;
                 fh.on_off = btnSwitch.IsSelected ? "on" : "off";
-                Control.Send(CommandType_A.write, fh);
+                //Control.Send(CommandType_A.write, fh);
+                System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
+                d.Add("on_off", fh.on_off.ToString());
+                Control.SendWriteCommand(fh, d);
             };
         }
 
@@ -131,7 +143,10 @@
             {
                 btn1.IsSelected = btn2.IsSelected = true;
                 fh.curMode = curMode;
-                Control.Send(CommandType_A.write, fh);
+                //Control.Send(CommandType_A.write, fh);
+                System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
+                d.Add("mode", fh.curModeIndex.ToString());
+                Control.SendWriteCommand(fh, d);
                 dialog.Close();
             };
             btn1.MouseUpEventHandler = eventHandler1;

--
Gitblit v1.8.0