From 9470ac56dd964de9c10ae73fe1a068e21aef2fde Mon Sep 17 00:00:00 2001
From: 陈嘉乐 <cjl@hdlchina.com.cn>
Date: 星期一, 08 三月 2021 19:09:34 +0800
Subject: [PATCH] 2021-3-8-5

---
 HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/Matching.cs |   22 +++++++++++-----------
 1 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/Matching.cs b/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/Matching.cs
index ec6420f..caf97eb 100644
--- a/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/Matching.cs
+++ b/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/Matching.cs
@@ -196,11 +196,11 @@
                     var library = libraryList[index];
                     var control = GetControl(spk, testBtn.TextID, library);
                     Method method = new Method();
-                    method.ThreadAddControl(control, this,(control1) => {
+                    method.ThreadAddControl(control, this,(cont) => { 
                         MainPage.BasePageView.RemoveViewByTag("PirView");
                         AddControlComplete addControlComplete = new AddControlComplete();
                         MainPage.BasePageView.AddChidren(addControlComplete);
-                        addControlComplete.Show(control1,true);
+                        addControlComplete.Show(cont,true);
                         MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
                     });
 
@@ -222,11 +222,11 @@
             string value = "";
             switch (spk)
             {
-                case SPK.AcStandard:
+                case SPK.AcIr:
                     {
                         switch (textInt)
                         {
-                            case StringId.dianshi:
+                            case StringId.dianyuan:
                                 {
                                     key = "on_off";
                                     value = "on";
@@ -273,21 +273,22 @@
                     }
                     break;
             }
-            ButtonObj buttonObj = new ButtonObj();
-            buttonObj.Key = key;
+            AttributesStatus buttonObj = new AttributesStatus();
+            buttonObj.key = key;
             buttonObj.value = value;
 
             Control control = new Control();
             control.spk = spk;
             control.name = spk;
-            control.group_id = library.irIndex;
+            control.groupId = library.irIndex;
             control.type = "library";
             control.status.Add(buttonObj);
+            control.deviceId = Pir.currPir.deviceId;
             string[] strings = library.irCode.Split(',');
-            for (int array = 0; array < strings.Length; array++)
+            for (int arrayStr = 0; arrayStr < strings.Length; arrayStr++) 
             {
-                //var intValue = Convert.ToInt32(strings[array],16);
-                control.library.Add(strings[array]);
+                //var intValue = Convert.ToInt32(strings[arrayStr],16);
+                control.library.Add(strings[arrayStr].Replace("0x",""));
             }
 
             return control;
@@ -309,7 +310,6 @@
             {
                 try
                 {
-                    //鍙戦�佹寜閿垹闄わ紱
                     responsePackNew = PirSend.CodeTest(control);
                 }
                 catch { }

--
Gitblit v1.8.0