From 60c59ea2ed4ee11a9989fdd4ce0ddace6efe452e Mon Sep 17 00:00:00 2001
From: wxr <464027401@qq.com>
Date: 星期二, 04 四月 2023 14:35:46 +0800
Subject: [PATCH] 群控备份

---
 HDL_ON/Common/ApiUtlis.cs |   32 +++++++++++++++++++++++++++++++-
 1 files changed, 31 insertions(+), 1 deletions(-)

diff --git a/HDL_ON/Common/ApiUtlis.cs b/HDL_ON/Common/ApiUtlis.cs
index 0692981..893a034 100644
--- a/HDL_ON/Common/ApiUtlis.cs
+++ b/HDL_ON/Common/ApiUtlis.cs
@@ -229,7 +229,7 @@
                                 foreach (var newFunction in deviceList.list)
                                 {
                                     newFunction.AssembleStatus();
-                                    newFunction.SaveFunctionFile();
+                                    newFunction.SaveFunctionFile(); 
                                     FunctionList.List.IniFunctionList(newFunction.savePath,true);
                                     MainPage.Log($"============璁惧============{iiii++}");
                                 }
@@ -314,6 +314,7 @@
                                 //======================鐧诲綍鍏ㄨ閫�====================
                                 if (isInterphoneType_FREEVIEW)
                                 {
+
 #if __IOS__
                                     List<VisitorTempPassword> dataList = new List<VisitorTempPassword>();
                                     Dictionary<string, object> dictionary = new Dictionary<string, object>();
@@ -344,6 +345,35 @@
                             complateDevice = true;
                             MainPage.Log($"============璁惧============瀹屾垚" + FunctionList.List.Functions.Count);
                         }
+
+
+#if DEBUG
+                        DB_ResidenceData.Instance.CurrentRegion.isSupportGroupControl = true;
+#endif
+                        if (DB_ResidenceData.Instance.CurrentRegion.isSupportGroupControl)
+                        {
+                            var pack = Ins.HttpRequest.GetGroupControlList();
+                            if (pack != null)
+                            {
+                                if (pack.Code == StateCode.SUCCESS)
+                                {
+                                    try
+                                    {
+                                        FunctionList.List.groupControls = JsonConvert.DeserializeObject<List<GroupControl>>(pack.Data.ToString());
+                                    }
+                                    catch (Exception ex)
+                                    {
+                                        MainPage.Log($"璇诲彇缁勬帶鍒楄〃澶辫触:{ex.Message}");
+                                    }
+                                }
+                                else
+                                {
+                                    IMessageCommon.Current.ShowErrorInfoAlter(pack.Code);
+                                }
+                            }
+                        }
+
+
                     //})
                     //{ IsBackground = true }.Start();
 

--
Gitblit v1.8.0