From d6b4e510f1430d19bc48da6894cf707bbe3c226d Mon Sep 17 00:00:00 2001
From: gxc <guoxuecheng@guoxuechengdeMacBook-Pro.local>
Date: 星期二, 29 十月 2019 14:25:15 +0800
Subject: [PATCH] 2019.10.29-2

---
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlShardLogic.cs |   50 +++++++++++++++-----------------------------------
 1 files changed, 15 insertions(+), 35 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlShardLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlShardLogic.cs
index 0970bc3..07ebc6e 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlShardLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlShardLogic.cs
@@ -57,19 +57,12 @@
             //鏂囦欢澶�
             string strDir = System.IO.Path.Combine(DirNameResourse.LocalMemoryDirectory, DirNameResourse.DownLoadShardDirectory);
 
-            //涓嶅厑璁告寜绯荤粺鐨勮繑鍥為敭
-            Shared.Common.CommonPage.BackKeyCanClick = false;
-            UserCenterResourse.Option.AppCanSignout = false;
-
             foreach (string keys in listDistributedMark)
             {
                 var dataPra = new { DistributedMark = keys, HouseDistributedMark = Common.Config.Instance.Home.Id, IsOtherAccountControl = Common.Config.Instance.isAdministrator };
                 var result = await UserCenterLogic.GetResponseDataByRequestHttps("ZigbeeDataShare/GetOneShareData", false, dataPra);
                 if (result == null)
                 {
-                    //鍏佽鎸夌郴缁熺殑杩斿洖閿�
-                    Shared.Common.CommonPage.BackKeyCanClick = true;
-                    UserCenterResourse.Option.AppCanSignout = true;
                     return null;
                 }
                 var dataResult = Newtonsoft.Json.JsonConvert.DeserializeObject<GetShardInfoResult>(result);
@@ -80,10 +73,6 @@
                 //璁剧疆杩涘害鍊�
                 ProgressBar.SetValue(1);
             }
-
-            //鍏佽鎸夌郴缁熺殑杩斿洖閿�
-            Shared.Common.CommonPage.BackKeyCanClick = true;
-            UserCenterResourse.Option.AppCanSignout = true;
 
             return listFile;
         }
@@ -108,28 +97,27 @@
         /// <summary>
         /// 鑾峰彇鏈湴鍏ㄩ儴鐨勫叡浜枃浠�
         /// </summary>
+        /// <param name="room">鎸囧畾鍙幏鍙栨寚瀹氭埧闂寸殑</param>
         /// <returns></returns>
-        public List<string> GetLocalAllShardFile()
+        public List<string> GetLocalAllShardFile(Common.Room room = null)
         {
             string path = UserCenterLogic.CombinePath(DirNameResourse.LocalMemoryDirectory, DirNameResourse.DownLoadShardDirectory);
             var listFile = HdlAutoBackupLogic.GetFileFromDirectory(path);
-
-            return listFile;
-        }
-
-        /// <summary>
-        /// 鏂囦欢鏄惁瀛樺湪
-        /// </summary>
-        /// <param name="fileName"></param>
-        /// <returns></returns>
-        public bool IsFileExists(string fileName)
-        {
-            string fullName = UserCenterLogic.CombinePath(DirNameResourse.LocalMemoryDirectory, DirNameResourse.DownLoadShardDirectory, fileName);
-            if (System.IO.File.Exists(fullName) == false)
+            if (room == null)
             {
-                return false;
+                return listFile;
             }
-            return true;
+            //鎴块棿
+            var listRoomFile = new List<string>() { room.FileName };
+            //鍦烘櫙鏂囦欢
+            listRoomFile.AddRange(room.SceneUIFilePathList);
+            //璁惧鏂囦欢
+            foreach (var uiName in room.DeviceUIFilePathList)
+            {
+                string deviceName = uiName.Replace("DeviceUI_", string.Empty);
+                listRoomFile.Add(deviceName);
+            }
+            return null;
         }
 
         #endregion
@@ -480,10 +468,6 @@
             //鑾峰彇涓婁紶鐨勬枃浠�,鐒跺悗灏嗘枃浠跺鍒跺埌鎸囧畾鏂囦欢澶�
             var listFile = this.GetUploadListFile(ref roomTemp, listDevice, listScene, listChirdDevice, listChirdScene);
 
-            //涓嶅厑璁告寜绯荤粺鐨勮繑鍥為敭
-            Shared.Common.CommonPage.BackKeyCanClick = false;
-            UserCenterResourse.Option.AppCanSignout = false;
-
             //鎵撳紑杩涘害鏉�
             ProgressBar.Show();
             //璁剧疆鏈�澶у��
@@ -492,10 +476,6 @@
             var result = await this.DoUploadShardContent(memberShardInfo, nowRoom, listFile);
             //鍏抽棴杩涘害鏉�
             ProgressBar.Close();
-
-            //鍏佽鎸夌郴缁熺殑杩斿洖閿�
-            Shared.Common.CommonPage.BackKeyCanClick = true;
-            UserCenterResourse.Option.AppCanSignout = true;
 
             if (result == false)
             {

--
Gitblit v1.8.0