From 312f9ece8d4a46d8989187730fc7f5c7fc36cfb5 Mon Sep 17 00:00:00 2001
From: wxr <wxr@hdlchina.com.cn>
Date: 星期五, 12 七月 2024 15:20:52 +0800
Subject: [PATCH] Update SplashActivity.cs

---
 HDL_ON/Common/ApiUtlis.cs |   91 +--------------------------------------------
 1 files changed, 3 insertions(+), 88 deletions(-)

diff --git a/HDL_ON/Common/ApiUtlis.cs b/HDL_ON/Common/ApiUtlis.cs
index 2094e6c..8ae0cfb 100644
--- a/HDL_ON/Common/ApiUtlis.cs
+++ b/HDL_ON/Common/ApiUtlis.cs
@@ -72,6 +72,8 @@
         /// 涓嬭浇鏁版嵁瀹屾垚鏍囪
         /// </summary>
         public bool DownloadDataComplete = false;
+
+        public bool hadInternet = true;
         /// <summary>
         /// 涓嬭浇鏁版嵁
         /// </summary>
@@ -97,17 +99,15 @@
             string code = StateCode.SUCCESS;
 
             Inverter.Ins.H5Page = null;//閲嶇疆鍏変紡椤甸潰
-            bool hadInternet = true;
             var downloadDataThread = new System.Threading.Thread(() =>
             {
                 try
                 {
                     //澧炲姞3绉掍簯鏈嶅姟鍣ㄨ繛鎺ユ娴嬶紝杩炰笉涓婃湇鍔″櫒鐨勬椂鍊欎笉鍒锋柊鏁版嵁
+                    hadInternet = true;
                     var dataList = new List<GlobalRegionListRes>();
                     var requestJson = HttpUtil.GetSignRequestJson(new GetRegionListObj() { regionMark = HttpUtil.RegionMark });
-                    Console.WriteLine(DateTime.Now);
                     var revertObj = HttpUtil.RequestHttpsPost(NewAPI.API_POST_GlobalRegionList, requestJson, HttpUtil.GlobalRequestHttpsHost, "", 3);
-                    Console.WriteLine(DateTime.Now);
                     if (revertObj == null || revertObj.Code != StateCode.SUCCESS)
                     {
                         DownloadDataComplete = true;
@@ -373,7 +373,6 @@
                                 //}
 
                                 //======================鑾峰彇鍙瀵硅璁惧鍒楄〃====================
-                                bool isInterphoneType_HDL = false;//鏄惁涓篐DLLinphone鍙瀵硅
                                 bool isInterphoneType_FREEVIEW = false;//鏄惁涓哄叏瑙嗛�氬彲瑙嗗璁�
                                 var videoInfo = VideoSend.GetVideoInfoList();
                                 if (videoInfo.Code == StateCode.SUCCESS)
@@ -389,91 +388,7 @@
                                         {
                                             UI.UI2.PersonalCenter.PirDevice.PirSend.LcSubAccessToken = video.subAccountToken;
                                         }
-                                        else if (video.interphoneType == InterphoneType.HDL.ToString())
-                                        {
-                                            isInterphoneType_HDL = true;
-                                            DB_ResidenceData.Instance.SupportFacePass = true;
-                                            DB_ResidenceData.Instance.SaveResidenceData();
-                                            DB_ResidenceData.Instance.SupportFVDevice = true;
-                                        }
-                                        else if (video.interphoneType == InterphoneType.FREEVIEW.ToString())
-                                        {
-#if __IOS__
-                                            try
-                                            {
-                                                FunctionList.List.videoIntercom.Remove(video);
-                                                --i;
-                                            }catch(Exception ex)
-                                            {
-                                                MainPage.Log($"ios 鍏ㄨ閫氬紓甯� : {ex.Message}");
-                                            }
-
-#else
-                                            //涓哄叏瑙嗛�氬彲瑙嗗璁�
-                                            DB_ResidenceData.Instance.SupportFacePass = true;
-                                            Entity.DB_ResidenceData.Instance.SupportVisitorManage = true;
-                                            Entity.DB_ResidenceData.Instance.SupportFVDevice = true;
-                                            isInterphoneType_FREEVIEW = true;
-#endif
-                                        }
                                     }
-                                }
-
-
-                                //======================鑾峰彇Sip璐﹀彿骞朵笖鍒濆鍖朣DK鍙瀵硅璁惧鍒楄〃====================
-                                //濡傛灉妫�娴嬬嚎绋嬫病鍚姩锛屾墠缁х画涓嬮潰鎿嶄綔 鍥犱负App鏈夊彲鑳藉垰鍚姩椹笂鏀跺埌鎺ㄩ�佷簡锛岀劧鍚庢墠鎵ц鍒拌繖閲�
-                                if (HDLLinphone.Current.CheckIncomingCallThreadIsNull())
-                                {
-                                    
-                                    //褰撳墠浣忓畢鏄疕DL鍙瀵硅绫诲瀷鐨勮澶�
-                                    if (isInterphoneType_HDL)
-                                    {
-                                        //HDLLinphone鍙瀵硅,鑾峰彇Sip璐﹀彿骞跺垵濮嬪寲SDK
-                                        HDLCallVideoInfo callVideoInfo = new HDLCallVideoInfo();
-                                        callVideoInfo.HomeId = DB_ResidenceData.Instance.CurrentRegion.id;
-                                        callVideoInfo.InterphoneType = InterphoneType.HDL.ToString();
-                                        HDLLinphone.Current.GetHDLSipInfoAndInitSDK(callVideoInfo);
-                                    }
-                                    else if (isInterphoneType_FREEVIEW)
-                                    {
-                                        //HDLLinphone鍙瀵硅,鑾峰彇Sip璐﹀彿骞跺垵濮嬪寲SDK
-                                        HDLCallVideoInfo callVideoInfo = new HDLCallVideoInfo();
-                                        callVideoInfo.HomeId = DB_ResidenceData.Instance.CurrentRegion.id;
-                                        callVideoInfo.InterphoneType = InterphoneType.FREEVIEW.ToString();
-                                        HDLLinphone.Current.GetHDLSipInfoAndInitSDK(callVideoInfo);
-                                    }
-                                    else
-                                    {
-                                        Utlis.WriteLine("褰撳墠浣忓畢涓嶆敮鎸丠DL鍙瀵硅,閫�鍑虹櫥褰曟墍鏈夎处鍙�");
-                                        //褰撳墠浣忓畢涓嶆敮鎸丠DL鍙瀵硅
-                                        HDLLinphone.Current.LogoutAllAccount();
-                                    }
-                                }
-
-
-
-                                //======================鐧诲綍鍏ㄨ閫�====================
-                                if (isInterphoneType_FREEVIEW)
-                                {
-
-#if __IOS__
-                                    //string systemVersion = UIKit.UIDevice.CurrentDevice.SystemVersion;
-                                    //string errorVersion = "16.2.0";
-                                    //if (systemVersion.CompareTo(errorVersion) < 0)///鍏ㄨ閫氫笉鍏煎ios16浠ヤ笂鐨勭郴缁燂紝涓嶈鍔犺浇杩欎釜鍏�
-                                    //{
-                                    //    List<VisitorTempPassword> dataList = new List<VisitorTempPassword>();
-                                    //    Dictionary<string, object> dictionary = new Dictionary<string, object>();
-                                    //    dictionary.Add("homeId", Entity.DB_ResidenceData.Instance.CurrentRegion.id);
-                                    //    var requestJson = HttpUtil.GetSignRequestJson(dictionary);
-                                    //    ResponsePackNew pack = HttpUtil.RequestHttpsPost(NewAPI.Api_Post_GetExtMemberInfo, requestJson);
-                                    //    if (pack != null)
-                                    //    {
-                                    //        var data = JsonConvert.DeserializeObject<FreeviewMemberInfo>(pack.Data.ToString());
-                                    //        //鐧诲綍鍏ㄨ閫�
-                                    //        Shared.IOS.HDLFVSDK.Video.Init("", data.extUserId, DB_ResidenceData.Instance.CurrentRegion.id, "78FF1E4D-FC0A-4E71-9B79-0448E4460BD7", "T0001", "120.77.53.170:9700", "120.77.53.170:21664");
-                                    //    }
-                                    //}
-#endif
                                 }
 
                             }

--
Gitblit v1.8.0