From 610a6a826a00d47320b17478cb5ca5f60abfa291 Mon Sep 17 00:00:00 2001
From: wxr <464027401@qq.com>
Date: 星期二, 24 五月 2022 17:25:16 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/wjc' into Dev-Branch

---
 HDL-ON_Android/Assets/Language.ini                                |    5 +
 HDL_ON/UI/UI2/3-Intelligence/Automation/InpOrOutLogicMethod.cs    |   26 ++++++++
 HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs |   30 +++++++++
 HDL_ON/UI/UI2/FuntionControlView/DoorLock/DoorLockPage.cs         |    2 
 HDL_ON/Common/ApiUtlis.cs                                         |    3 
 HDL_ON/UI/UI2/FuntionControlView/Music/A31MusicModel.cs           |    2 
 HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirMethod.cs             |    2 
 HDL_ON/UI/UI2/3-Intelligence/Automation/TargetDeviceFunList.cs    |    2 
 HDL_ON/UI/UI2/3-Intelligence/Automation/AddInputType.cs           |   15 ++--
 HDL_ON/UI/UI2/3-Intelligence/Automation/FunTpye.cs                |    7 +-
 HDL-ON_iOS/Resources/Language.ini                                 |    4 +
 HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs            |   17 +++++
 HDL_ON/UI/UI2/FuntionControlView/Music/A31PlayMusicPage.cs        |    2 
 HDL_ON/UI/UI2/3-Intelligence/Automation/LogicView/SwitchView.cs   |   23 +++++--
 HDL_ON/UI/UI2/3-Intelligence/Automation/Send.cs                   |    2 
 HDL_ON/Common/R.cs                                                |    9 +++
 HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs               |    1 
 HDL_ON/UI/UI2/FuntionControlView/Music/MusicMain.cs               |    6 +-
 18 files changed, 129 insertions(+), 29 deletions(-)

diff --git a/HDL-ON_Android/Assets/Language.ini b/HDL-ON_Android/Assets/Language.ini
index a8a1281..3c45ca3 100644
--- a/HDL-ON_Android/Assets/Language.ini
+++ b/HDL-ON_Android/Assets/Language.ini
@@ -1043,6 +1043,9 @@
 7154=Arrive
 7155=Distress/Normal
 7156=Distress
+7157=whether to unlock
+7158=is
+
 
 
 
@@ -2181,6 +2184,8 @@
 7154=鍒拌揪
 7155=姹傛晳/姝e父
 7156=姹傛晳
+7157=鏄惁寮�閿佹椂
+7158=鏄�
 
 
  
diff --git a/HDL-ON_iOS/Resources/Language.ini b/HDL-ON_iOS/Resources/Language.ini
index a8a1281..78daf8e 100644
--- a/HDL-ON_iOS/Resources/Language.ini
+++ b/HDL-ON_iOS/Resources/Language.ini
@@ -1043,6 +1043,8 @@
 7154=Arrive
 7155=Distress/Normal
 7156=Distress
+7157=whether to unlock
+7158=is
 
 
 
@@ -2181,6 +2183,8 @@
 7154=鍒拌揪
 7155=姹傛晳/姝e父
 7156=姹傛晳
+7157=鏄惁寮�閿佹椂
+7158=鏄�
 
 
  
diff --git a/HDL_ON/Common/ApiUtlis.cs b/HDL_ON/Common/ApiUtlis.cs
index f7b62c8..6ee9f91 100644
--- a/HDL_ON/Common/ApiUtlis.cs
+++ b/HDL_ON/Common/ApiUtlis.cs
@@ -159,7 +159,8 @@
                         endTime = DateTime.Now.AddSeconds(5);
 
                         MainPage.Log($"璇诲彇璁惧淇℃伅鎴愬姛");
-                        var deviceList = JsonConvert.DeserializeObject<DevcieApiPack>(deviceResult.Data.ToString());
+                        MainPage.Log($"sid鍒楄〃鑾峰彇===="+ deviceResult.Data.ToString());
+                        var deviceList = Newtonsoft.Json.JsonConvert.DeserializeObject<DevcieApiPack>(deviceResult.Data.ToString());
                         if (deviceList == null)
                         {
                             deviceList = new DevcieApiPack();
diff --git a/HDL_ON/Common/R.cs b/HDL_ON/Common/R.cs
index 6de49a2..d537d1f 100644
--- a/HDL_ON/Common/R.cs
+++ b/HDL_ON/Common/R.cs
@@ -2757,6 +2757,15 @@
         /// 姹傛晳
         /// </summary>
         public const int qiujiu = 7156;
+        /// <summary>
+        /// 鏄惁寮�閿佹椂
+        /// </summary>
+        public const int shifoukaisuoshi = 7157;
+        /// <summary>
+        /// 鏄�
+        /// </summary>
+        public const int shi = 7158;
+
 
 
         #region LE鏂板
diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/AddInputType.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/AddInputType.cs
index 49990a0..eadc10b 100644
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/AddInputType.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/AddInputType.cs
@@ -62,15 +62,16 @@
             likiadaodaView.frameLayout.Y = shiwaiView.frameLayout.Bottom;
             likiadaodaView.btnText.TextID = StringId.likiadaoda;
             likiadaodaView.btnIcon.UnSelectedImagePath = "LogicIcon/location.png";
-            int count = 0;//杈撳叆绫诲瀷涓暟
-            if (MainView.IsGatewayType)
-            {
-                count = 4;
-                viewLayout.AddChidren(likiadaodaView.FLayoutView());
-            }
+            int count = 3;//杈撳叆绫诲瀷涓暟
+            //2022骞�05鏈�24鏃�15:08:22 闅愯棌鎺夊湴鐞嗗洿鏍�
+            //if (MainView.IsGatewayType)
+            //{
+            //    count = 4;
+            //    viewLayout.AddChidren(likiadaodaView.FLayoutView());
+            //}
             ////鍔熻兘
             ///浜у搧缁忕悊鍚涚剷瑕佹眰锛岃澶囧姛鑳界Щ鍒拌繖閲屻��<2022-3-7>
-            new FunTpye(LogicMethod.condition_if).FunTypeView(viewLayout, likiadaodaView.frameLayout.Bottom, count);
+            new FunTpye(LogicMethod.condition_if).FunTypeView(viewLayout, shiwaiView.frameLayout.Bottom, count);
 
             #endregion
 
diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs
index 1dbfd7c..2b606ad 100644
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs
@@ -405,6 +405,23 @@
                         };
                     }
                     break;
+                //闂ㄩ攣
+                case SPK.DoorLock:
+                    {
+
+                        LogicView.FunTypeView view = new LogicView.FunTypeView();
+                        view.btnText.TextID = StringId.shifoukaisuoshi;
+                        fLayout.AddChidren(view.FLayoutView());
+                        view.btnClick.MouseUpEventHandler += (sender, e) =>
+                        {
+                            DeviceView(device, view.btnState, StringId.shi, StringId.offLogic,1);
+                        };
+                        if (edit)
+                        {
+                            GetEditState(device, index, view.btnState, null, null, null);
+                        }
+                    }
+                    break;
             }
             #region  淇濆瓨
             ///淇濆瓨View
@@ -482,12 +499,13 @@
         /// <param name="button">閫変腑鐘舵�佹樉绀烘枃鏈珺tn鎺т欢</param>
         /// <param name="btnText1">灞炴�х姸鎬佸�兼枃鏈�1</param>
         /// <param name="btnText2">灞炴�х姸鎬佸�兼枃鏈�2</param>
-        private void DeviceView(Entity.Function device, Button button, int btnText1, int btnText2)
+        /// <param name="viewCount">view鏁伴噺</param>
+        private void DeviceView(Entity.Function device, Button button, int btnText1, int btnText2,int viewCount=2)
         {
             FrameLayout frame = new FrameLayout { BackgroundColor = CSS.CSS_Color.viewTrans60lucence };
             this.AddChidren(frame);
             LogicView.SwitchView switchView = new LogicView.SwitchView();
-            switchView.FLayoutView(frame, btnText1, btnText2, button.Text, (intValue) =>
+            switchView.FLayoutView(frame, btnText1, btnText2, button.Text, viewCount,(intValue) =>
             {
                 //璁惧灞炴�у�硷紝浜戦泙涓婂畾涔夊ソ鐨�;
                 string keyVlaue = "on_off";
@@ -540,6 +558,11 @@
                             }
                         }
                         break;
+                    case SPK.DoorLock:
+                        {
+                            keyVlaue = "door_status";
+                        }
+                        break;
 
                 }
                 switch (intValue)
@@ -583,6 +606,7 @@
                             }
                         }
                         break;
+                    case StringId.shi:
                     case StringId.kaiqi:
                         {
                             value = "open";
@@ -607,6 +631,8 @@
                         {
                             value = "fall";
                         }; break;
+                   
+
                 }
                 //鏄剧ず鏂囨湰
                 button.TextID = intValue;
diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/FunTpye.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/FunTpye.cs
index dbe2972..13e261d 100644
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/FunTpye.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/FunTpye.cs
@@ -219,10 +219,11 @@
                     areaView.btnClick.MouseUpEventHandler += (sender, e2) =>
                     {
                         fLayout.RemoveFromParent();
-                        funAllAreaView.btnText2.Text = areaView.btnClick.Tag.ToString();
-                        UserInfo.Current.logicselectedFunction = areaView.btnClick.Tag.ToString();
+                        string clickText = areaView.btnClick.Tag.ToString(); 
+                        funAllAreaView.btnText2.Text = clickText;
+                        UserInfo.Current.logicselectedFunction = clickText;
                         ///鑾峰彇璁惧鍗曚釜澶х被spk鍒楄〃锛堜緥濡�:鐏厜绫�,绌鸿皟绫�...锛�
-                        var typeFunctionList2 = LogicMethod.CurrLogicMethod.GetDeviceTypeFunctionList(UserInfo.Current.logicselectedFunction);
+                        var typeFunctionList2 = LogicMethod.CurrLogicMethod.GetDeviceTypeFunctionList(clickText);
                         ///鑾峰彇璁惧鍗曚釜灏忕被鍒楄〃锛堜緥濡傦細鐏厜1,鐏厜2...锛�
                         var lists2 = LogicMethod.CurrLogicMethod.GetShowDeviceList(typeFunctionList2, functionList);
                        this.LoadingDeviceListView(vv, lists2);
diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/InpOrOutLogicMethod.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/InpOrOutLogicMethod.cs
index 646c43e..ecbb380 100644
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/InpOrOutLogicMethod.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/InpOrOutLogicMethod.cs
@@ -447,6 +447,19 @@
 
                                     }
                                     break;
+                                case SPK.DoorLock:
+                                    {
+                                        foreach (var dic in dicList)
+                                        {
+                                            string value = dic["value"];
+                                            if (value == "open")
+                                            {
+                                                inputView.btnState.Text = Language.StringByID(StringId.kaiqi);
+                                            }
+
+                                        }
+                                    }
+                                    break;
                             }
                         }
                         break;
@@ -1984,6 +1997,19 @@
                         }
                     }
                     break;
+                case SPK.DoorLock:
+                    {
+                        foreach (var dic in dicList)
+                        {
+                            string value = dic["value"];
+                            if (value == "open")
+                            {
+                                button1.Text = Language.StringByID(StringId.shi);
+                            }
+                           
+                        }
+                    }
+                    break;
             }
         }
         /// <summary>
diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs
index 8bfe344..d863ed5 100644
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs
@@ -397,6 +397,11 @@
                         strPath = "LogicIcon/sensor.png";
                     }
                     break;
+                case SPK.DoorLock:
+                    {
+                        strPath = "FunctionIcon/DoorLock/DoorLock.png";
+                    }
+                    break;
 
             }
             return strPath;
@@ -488,6 +493,12 @@
             {
                 deviceStrTypeList.Add(Language.StringByID(StringId.Electric));
             }
+            ///闂ㄩ攣绫�
+            var doorlock = deviceList.Find((device) => device.spk == SPK.DoorLock);
+            if (doorlock != null)
+            {
+                deviceStrTypeList.Add(Language.StringByID(StringId.DoorLock));
+            }
             return deviceStrTypeList;
 
         }
@@ -568,6 +579,11 @@
                 functionTypeList.Add(SPK.AirSwitch);
                 functionTypeList.Add(SPK.PanelSocket);
                 functionTypeList.Add(SPK.ElectricSocket);
+            }
+            ///闂ㄩ攣绫�
+            else if (deviceType == Language.StringByID(StringId.DoorLock))
+            {
+                functionTypeList.Add(SPK.DoorLock); 
             }
             else
             {
@@ -668,6 +684,7 @@
                         deviceTypeList.Add(SPK.ElectricSocket);
                         deviceTypeList.Add(SPK.HvacCac);
                         deviceTypeList.Add(SPK.SensorHelp);
+                        deviceTypeList.Add(SPK.DoorLock);
 
                     }
                     break;
diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicView/SwitchView.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicView/SwitchView.cs
index 0b9a0d1..290a07f 100644
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicView/SwitchView.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/LogicView/SwitchView.cs
@@ -97,7 +97,7 @@
         /// View鐨勬柟娉�
         /// </summary>
         ///  <param name="frame">鐖舵帶浠�</param>
-        /// <param name="i">鏄剧ず閫夋嫨View鏁伴噺</param>
+        /// <param name="i">琛ㄧずView鏁伴噺</param>
         ///<param name="stateVuale">涔嬪墠鐨勭姸鎬佸��</param>
         /// <param name="action">杩斿洖鍥炶皟</param>
         /// <returns></returns>
@@ -166,23 +166,30 @@
         /// View鐨勬柟娉�
         /// </summary>
         ///  <param name="frame">鐖舵帶浠�</param>
-        /// <param name="text1">鐖舵帶浠�</param>
-        /// <param name="text2">鏄剧ず閫夋嫨View鏁伴噺</param>
+        /// <param name="text1">绗竴涓娉�</param>
+        /// <param name="text2">绗簩涓娉�</param>
         ///<param name="stateVuale">涔嬪墠鐨勭姸鎬佸��</param>
+        /// <param name="i">琛ㄧずView鏁伴噺</param>
         /// <param name="action">杩斿洖鍥炶皟</param>
         /// <returns></returns>
-        public void FLayoutView(FrameLayout frame, int text1, int text2, string stateVuale, Action<int> action,bool tag=true)
+        public void FLayoutView(FrameLayout frame, int text1, int text2, string stateVuale, int i, Action<int> action,bool tag=true)
         {
-            int i = 2;
             frameLayout.Y = Application.GetRealHeight(603 - (44 * i));
             frameLayout.Height = Application.GetRealHeight(44 * i);
             frame.AddChidren(frameLayout);
             frame.AddChidren(btnCancel);
             btnOn.TextID = text1;
             btnOff.TextID = text2;
-            frameLayout.AddChidren(btnOn);
-            frameLayout.AddChidren(btnLine);
-            frameLayout.AddChidren(btnOff);
+            if (i == 1)
+            {
+                frameLayout.AddChidren(btnOn);
+            }
+            else if (i == 2)
+            {
+                frameLayout.AddChidren(btnOn);
+                frameLayout.AddChidren(btnLine);
+                frameLayout.AddChidren(btnOff);
+            }
             //鍙栨秷鐐瑰嚮浜嬩欢
             btnCancel.MouseUpEventHandler += (sender1, e1) =>
             {
diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/Send.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/Send.cs
index 7258f5f..f429ada 100644
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/Send.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/Send.cs
@@ -173,7 +173,7 @@
         logicIfon.Add("noticeConfig", noticeConfigJObject);
         logicIfon.Add("pushConfigs", pushConfigsArray);
         logicjArray.Add(logicIfon);
-        //string str = logicIfon.ToString();
+       //string str = logicIfon.ToString();
         var jObject = new JObject { { "homeId", LogicMethod.CurrLogicMethod.HomeId }, { "logics", logicjArray } };
         responsePackNew = RequestServerhomeId(jObject, NewAPI.API_POST_Logic_Add, 5);
         //濡傛灉鏄痶oken杩囨湡鍒欏埛鏂皌oken
diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/TargetDeviceFunList.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/TargetDeviceFunList.cs
index e5894e8..4b7c2fa 100644
--- a/HDL_ON/UI/UI2/3-Intelligence/Automation/TargetDeviceFunList.cs
+++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/TargetDeviceFunList.cs
@@ -171,7 +171,7 @@
                         ///寮�鍏崇偣鍑讳簨浠�
                         curtainSwitchView.btnClick.MouseUpEventHandler += (sender, e) =>
                         {
-                            SwitchViewMethod(device, curtainSwitchView.btnState, 3);
+                            SwitchViewMethod(device, curtainSwitchView.btnState, 2);
                         };
                         ///鐧惧垎姣旂偣鍑讳簨浠�
                         crtainPercentumView.btnClick.MouseUpEventHandler += (sender, e) =>
diff --git a/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirMethod.cs b/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirMethod.cs
index 4d7538c..4e1a37e 100644
--- a/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirMethod.cs
+++ b/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirMethod.cs
@@ -574,6 +574,8 @@
                                 str = Language.StringByID(StringId.shebeibucunzai);
                             }
                             break;
+                            
+                        case "124006":
                         case "14006":
                             {
                                 str = Language.StringByID(StringId.shebeibuzaixian);
diff --git a/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs b/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs
index 6f4b31f..4575ac6 100644
--- a/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs
+++ b/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs
@@ -291,6 +291,7 @@
         /// <returns></returns>
         public static ResponsePackNew RequestServerhomeId(object o, string api_Url, int mTimeout = 20)
         {
+            MainPage.Log("璇锋眰鏁版嵁=="+o.ToString());
             var requestJson = HttpUtil.GetSignRequestJson(o);
             return HttpUtil.RequestHttpsPostFroHome(api_Url, requestJson, mTimeout);
 
diff --git a/HDL_ON/UI/UI2/FuntionControlView/DoorLock/DoorLockPage.cs b/HDL_ON/UI/UI2/FuntionControlView/DoorLock/DoorLockPage.cs
index 7d9146c..6b7887f 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/DoorLock/DoorLockPage.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/DoorLock/DoorLockPage.cs
@@ -170,7 +170,7 @@
             this.picLockControl = new PicViewControl(256, 260);
             picLockControl.Y = Application.GetRealHeight(129);
             picLockControl.Gravity = Gravity.CenterHorizontal;
-            picLockControl.UnSelectedImagePath = "FunctionIcon/DoorLock/LockPictrue1.png";
+            picLockControl.UnSelectedImagePath = "FunctionIcon/DoorLock/LockPictrue1.png"; 
             FrameWhiteCentet1.AddChidren(picLockControl);
             picLockControl.ButtonClickEvent += (sender, e) =>
             {
diff --git a/HDL_ON/UI/UI2/FuntionControlView/Music/A31MusicModel.cs b/HDL_ON/UI/UI2/FuntionControlView/Music/A31MusicModel.cs
index 0f8eabb..698abcd 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/Music/A31MusicModel.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/Music/A31MusicModel.cs
@@ -53,7 +53,7 @@
      
         /// <summary>
         /// 涓婁竴娆℃洿鏂扮殑鏃堕棿
-        /// 璁板綍鏁版嵁鍙嶉鐨勬椂闂�(鍥犱负鏈夋椂闂寸綉缁滃樊鏁版嵁涓嶅洖澶嶏紝瀵艰嚧鍒锋柊褰撳墠鎾斁闊充箰鏃堕棿涓嶆纭�)
+        /// 璁板綍鏁版嵁鍙嶉鐨勬椂闂�(鍥犱负鏈夋椂鍊欑綉缁滃樊鏁版嵁涓嶅洖澶嶏紝瀵艰嚧鍒锋柊褰撳墠鎾斁闊充箰鏃堕棿涓嶆纭�)
         /// ((褰撳墠鏃堕棿)DateTime.Now - (璁板綍鏃堕棿)LastDateTimeLastDateTime).TotalSeconds=璇樊鏃堕棿(绉�)
         /// </summary>
         public DateTime LastDateTime;
diff --git a/HDL_ON/UI/UI2/FuntionControlView/Music/A31PlayMusicPage.cs b/HDL_ON/UI/UI2/FuntionControlView/Music/A31PlayMusicPage.cs
index d0d4d23..dec677f 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/Music/A31PlayMusicPage.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/Music/A31PlayMusicPage.cs
@@ -453,7 +453,7 @@
                                 //鍋滄鎾斁
                                 playView.startTimeBtn.Text =playTime;
                                 //playView.startTimeBtn.Text ="00:00";
-                                ///姝屾洸璁板綍鏆傚仠鏃堕棿锛�<LastDateTime 璁$畻鏃堕棿鎾斁鏃堕棿鏈夌敤鍒�>
+                                ///璁板綍姝屾洸鏆傚仠鏃堕棿锛�<LastDateTime 璁$畻鎾斁鏃堕棿鏈夌敤鍒�>
                                 A31MusicModel.Current.LastDateTime = DateTime.Now;
                             }
                             playView.songNameTextView.Text = A31MusicModel.Current.functionMusic.GetAttrState(KeyProperty.song_name) == null ? "Unkown" : A31MusicModel.Current.functionMusic.GetAttrState(KeyProperty.song_name);
diff --git a/HDL_ON/UI/UI2/FuntionControlView/Music/MusicMain.cs b/HDL_ON/UI/UI2/FuntionControlView/Music/MusicMain.cs
index cef6e69..cd2c148 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/Music/MusicMain.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/Music/MusicMain.cs
@@ -122,10 +122,10 @@
                 var musicListFunction = FunctionList.List.GetMusicList();
                 for (int i = 0; i < musicListFunction.Count; i++)
                 {
-                    var function = musicListFunction[i];
+                    var function = musicListFunction[i]; 
                     var music = A31MusicModel.A31MusicModelList.Find((obj) =>
-                   (obj.functionMusic.deviceId == function.deviceId && function.spk == "music.standard") || (
-                     obj.functionMusic.deviceId == function.deviceId && function.spk == "av.music")
+                   (obj.functionMusic.deviceId == function.deviceId && function.spk == SPK.MusicStandard) || (
+                     obj.functionMusic.deviceId == function.deviceId && function.spk == SPK.AvMusic)
                     );
                     if (music == null)
                     {

--
Gitblit v1.8.0