From cda2410f9c29f2fadc16e9de38ccae95b75a89dd Mon Sep 17 00:00:00 2001
From: wei <kaede@kaededeMacBook-Air.local>
Date: 星期三, 09 六月 2021 10:51:13 +0800
Subject: [PATCH] 1

---
 HDL_ON/UI/UI2/2-Classification/ClassificationPage.cs |   29 +++++++++++++++++++++++------
 1 files changed, 23 insertions(+), 6 deletions(-)

diff --git a/HDL_ON/UI/UI2/2-Classification/ClassificationPage.cs b/HDL_ON/UI/UI2/2-Classification/ClassificationPage.cs
index fdf56a2..2f3552a 100644
--- a/HDL_ON/UI/UI2/2-Classification/ClassificationPage.cs
+++ b/HDL_ON/UI/UI2/2-Classification/ClassificationPage.cs
@@ -475,10 +475,9 @@
                         break;
                     case ShowFunction.EnergyMonitoring:
                         #region 鑳芥簮
-                        functionCount = FunctionList.List.GetElectricals().Count;
-                        functionOnCount = FunctionList.List.GetElectricals().FindAll((obj) => obj.trait_on_off.curValue.ToString() == "on").Count;
+                        functionCount = FunctionList.List.GetEnergyList().Count;
+                        functionOnCount = FunctionList.List.GetEnergyList().FindAll((obj) => obj.trait_on_off.curValue.ToString() == "on").Count;
                         #endregion
-                        //functionCount = 1;
                         break;
                     case ShowFunction.Environmental:
                         #region 鐜鏁版嵁
@@ -491,6 +490,10 @@
                     case ShowFunction.Music:
                         functionCount = Music.A31MusicModel.A31MusicModelList.Count;
                         functionOnCount = Music.A31MusicModel.A31MusicModelList.FindAll((obj) => obj.trait_on_off.curValue.ToString() == "on").Count;
+                        if(functionCount == 0)
+                        {
+                            functionCount = FunctionList.List.GetMusicList().Count;
+                        }
                         break;
                     case ShowFunction.Panel:
                         break;
@@ -508,6 +511,9 @@
                         break;
                     case ShowFunction.SecurityCenter:
                         functionCount = FunctionList.List.securities.Count;
+#if DEBUG
+                        functionCount = 1;
+#endif
                         break;
 
                 }
@@ -556,11 +562,12 @@
                 {
                     X = Application.GetRealWidth(16),
                     Y = Application.GetRealHeight(14),
-                    Width = Application.GetRealWidth(120),
+                    Width = Application.GetRealWidth(140),
                     Height = Application.GetRealHeight(24),
                     TextColor = CSS_Color.FirstLevelTitleColor,
                     TextSize = CSS_FontSize.TextFontSize,
                     TextAlignment = TextAlignment.CenterLeft,
+                    IsMoreLines = true,
                 };
                 functionView.AddChidren(btnName);
 
@@ -814,6 +821,16 @@
                             videoMethod.MianView(this,FunctionList.List.videoIntercom);
                         };
                         break;
+                    case ShowFunction.SecurityCenter:
+                        btnName.TextID = StringId.SecurityCenter;
+                        btnFunctionViewBg.MouseUpEventHandler = (sender, e) =>
+                        {
+                            var page = new ArmCenterPage();
+                            MainPage.BasePageView.AddChidren(page);
+                            page.LoadPage();
+                            MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
+                        };
+                        break;
 
                 }
                 //鐣岄潰璺宠浆--闊充箰璺宠浆鑷繁鐨勭晫闈�--鐜璺宠浆鑷繁鐨勭晫闈�
@@ -840,7 +857,7 @@
 #endregion
         }
 
-#region 鍒囨崲妤煎眰
+        #region 鍒囨崲妤煎眰
         /// <summary>
         /// 妤煎眰鏄剧ず鍒囨崲
         /// </summary>
@@ -997,6 +1014,6 @@
         {
 
         }
-#endregion
+        #endregion
     }
 }
\ No newline at end of file

--
Gitblit v1.8.0