From a1f2f085e9a2790daecdb5a12d1075b64b2a3d92 Mon Sep 17 00:00:00 2001
From: wxr <464027401@qq.com>
Date: 星期一, 24 一月 2022 11:45:43 +0800
Subject: [PATCH] 备份

---
 HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs |   20 ++++++++++++++------
 1 files changed, 14 insertions(+), 6 deletions(-)

diff --git a/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs b/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs
index 21ac7a8..f5198f6 100644
--- a/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs
+++ b/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs
@@ -244,11 +244,11 @@
                 function.collect = false;
                 if (SPK.MusicSpkList().Contains(function.spk))//澶勭悊闊充箰涓讳粠鍏崇郴
                 {
-                    if ((function as Music.A31MusicModel).ServerClientType == 1)
-                    {
-                        (function as Music.A31MusicModel).MainPlayCollection = false;
-                        Music.A31MusicModel.Save();
-                    }
+                    //if ((function as Music.A31MusicModel).ServerClientType == 1)
+                    //{
+                    //    (function as Music.A31MusicModel).MainPlayCollection = false;
+                    //    Music.A31MusicModel.Save();
+                    //}
                 }
                 string msg = function.name + Language.StringByID(StringId.CollectionCancelled);
                 LoadDeviceFunctionControlZone();
@@ -374,7 +374,7 @@
                                         {
                                             if (SPK.MusicSpkList().Contains(function.spk))
                                             {
-                                                btn.Text = (function as Music.A31MusicModel).A31PlayStatus.Title;
+                                                btn.Text =function.GetAttrState("song_name");
                                             }
                                             else
                                             {
@@ -493,6 +493,14 @@
                         d.Add(FunctionAttributeKey.FadeTime, function.GetAttrState(FunctionAttributeKey.FadeTime));
                         Control.Ins.SendWriteCommand(function, d);
                     }
+                    else if (function.spk == SPK.PanelSocket)
+                    {
+                        if (function.attributes.Find((obj) => obj.key == "on_off_usb") != null)
+                        {
+                            d.Add("on_off_usb", function.trait_on_off.curValue.ToString());
+                        }
+                        Control.Ins.SendWriteCommand(function, d);
+                    }
                     else
                     {
                         d.Add("on_off", function.trait_on_off.curValue.ToString());

--
Gitblit v1.8.0