From 203c3a3ffde6259413d9743f6a723b95b1e7989c Mon Sep 17 00:00:00 2001
From: wxr <464027401@qq.com>
Date: 星期四, 06 七月 2023 22:43:05 +0800
Subject: [PATCH] 门锁功能

---
 HDL_ON/DAL/ThirdPartySdk/ESOnVideo.cs |   68 ++++++++++++++++++++--------------
 1 files changed, 40 insertions(+), 28 deletions(-)

diff --git a/HDL_ON/DAL/ThirdPartySdk/ESOnVideo.cs b/HDL_ON/DAL/ThirdPartySdk/ESOnVideo.cs
index 0965c39..e583183 100644
--- a/HDL_ON/DAL/ThirdPartySdk/ESOnVideo.cs
+++ b/HDL_ON/DAL/ThirdPartySdk/ESOnVideo.cs
@@ -82,7 +82,7 @@
             if (interphoneType == InterphoneType.IMOUVISIAL.ToString())
             {
                 //涔愭鍙瀵硅
-                //1.鍒濆鍖朙COpenSDK_Api
+                //1.鍒濆鍖朙COpenSDK_Api(Shared.IOS.LCVideoOnSDK)
                 LCApiKit.SharedInstance().IsChinaMainland = GetIsChinaMainland();
                 LCApiKit.SharedInstance().InitSDKOpenApi(mESVideoInfo.Lc_AccessToken);
                 LCApiKit.SharedInstance().CurrentDevicePlayToken = mESVideoInfo.Lc_PlayToken;
@@ -98,18 +98,22 @@
             }
             else if(interphoneType == InterphoneType.FLVI.ToString())
             {
-
+                //Shared.IOS.ESVideoOnSDK
                 ESOnMonitorViewController vc = new ESOnMonitorViewController();
                 vc.MESVideoID = mESVideoInfo.ESVideoUUID;
                 vc.MESRoomID = roomID;
                 vc.DeviceName = mESVideoInfo.DeviceName;
-                //vc.RoomName = mESVideoInfo.RoomName;
-                //vc.MESCallDelegate = new OnESCallDelegate(this);
                 Shared.Application.currentVC.NavigationController.PushViewController(vc, true);
-            }else if (interphoneType == InterphoneType.HDL.ToString())
+            }
+            else if (interphoneType == InterphoneType.HDL.ToString())
             {
                 //HDLLinphone 鐙勮�愬厠
-                HDLLinphone.Current.ShowESVideoMonitor(mESVideoInfo);
+                HDLLinphone.Current.ShowESVideoMonitor(mESVideoInfo, interphoneType);
+            } else if (interphoneType == InterphoneType.FREEVIEW.ToString())
+            {
+                //鍏ㄨ閫氱洃瑙�
+                //NSDictionary deviceInfo = new NSDictionary("deviceCode",mESVideoInfo.deviceCode, "deviceName", mESVideoInfo.DeviceName);
+                //Shared.IOS.HDLFVSDK.Video.Monitor(deviceInfo);
             }
             else
             {
@@ -120,7 +124,7 @@
             if (interphoneType == InterphoneType.IMOUVISIAL.ToString())
             {
                 intent = new Intent(Shared.Application.Activity, typeof(HDL_ON_Android.LeChengVideoActivity));
-         
+
                 //=========涔愭==========
                 intent.PutExtra("Type", 0);
                 intent.PutExtra("callId", mESVideoInfo.callId);
@@ -147,22 +151,25 @@
                 intent.PutExtra("callId", mESVideoInfo.callId);
                 intent.PutExtra("Type", 0);
 
-               
+
 
                 Shared.Application.Activity.StartActivity(intent);
             }
             else if (interphoneType == InterphoneType.HDL.ToString())
             {
                 //HDLLinphone 鐙勮�愬厠
-                HDLLinphone.Current.ShowESVideoMonitor(mESVideoInfo);
+                HDLLinphone.Current.ShowESVideoMonitor(mESVideoInfo, InterphoneType.HDL.ToString());
+            }
+            else if (interphoneType == InterphoneType.FREEVIEW.ToString())
+            {
+                string sip_account = "sip:D" + mESVideoInfo.deviceCode + "@139.159.157.75:46000";
+                mESVideoInfo.deviceSipAccount = sip_account;
+                HDLLinphone.Current.ShowESVideoMonitor(mESVideoInfo, InterphoneType.FREEVIEW.ToString());
             }
             else
             {
                 HDLUtils.WriteLine("鏈鎺ワ紝涓嶆敮鎸佺洃瑙�");
             }
-
-          
-
 #endif
         }
 
@@ -179,7 +186,7 @@
             if (interphoneType == InterphoneType.IMOUVISIAL.ToString())
             {
                 //涔愭鍙瀵硅
-                //1.鍒濆鍖朙COpenSDK_Api
+                //1.鍒濆鍖朙COpenSDK_Api(Shared.IOS.LCVideoOnSDK)
                 LCApiKit.SharedInstance().IsChinaMainland = GetIsChinaMainland();
                 LCApiKit.SharedInstance().InitSDKOpenApi(mESVideoInfo.Lc_AccessToken);
                 //2021-05-18 鐩墠鎺ㄩ�佺殑PlayToken;鏈夐棶棰樹細瀵艰嚧SDK宕╂簝锛屾殏鏃朵笉浼�
@@ -217,7 +224,7 @@
             }
             else if (interphoneType == InterphoneType.FLVI.ToString())
             {
-
+                //Shared.IOS.ESVideoOnSDK
                 ESOnIntercomViewController vc = new ESOnIntercomViewController();
                 vc.MESVideoID = mESVideoInfo.ESVideoUUID;
                 vc.MESRoomID = roomID;
@@ -227,7 +234,8 @@
                 mOnESCallDelegate = new OnESCallDelegate(this);
                 vc.MESCallDelegate = mOnESCallDelegate;
                 Shared.Application.currentVC.NavigationController.PushViewController(vc, true);
-            }else{
+            }
+            else{
                 HDLUtils.WriteLine("鏈敮鎸佺殑鍙瀵硅绫诲瀷");
 
             }
@@ -296,21 +304,12 @@
                 intent.PutExtra("callId", mESVideoInfo.callId);
                 intent.PutExtra("Type", 1);
 
-               
-
-
                 Shared.Application.Activity.StartActivity(intent);
             }
             else
             {
                 HDLUtils.WriteLine("鏈敮鎸佺殑鍙瀵硅绫诲瀷");
-
             }
-
-         
-
-         
-
             #endregion
 #endif
         }
@@ -568,7 +567,7 @@
 #if __IOS__
         #region OnESCallDelegate
         /////// <summary>
-        /////// OnESCallDelegate 缁ф壙鍝嶅簲浜嬩欢
+        /////// OnESCallDelegate 缁ф壙鍝嶅簲浜嬩欢(Shared.IOS.ESVideoOnSDK)
         /////// </summary>
         OnESCallDelegate mOnESCallDelegate;
 
@@ -644,7 +643,7 @@
 
         #region OnLCCallDelegate
         /////// <summary>
-        /////// OnLCCallDelegate 缁ф壙鍝嶅簲浜嬩欢
+        /////// OnLCCallDelegate 缁ф壙鍝嶅簲浜嬩欢(Shared.IOS.LCVideoOnSDK)
         /////// </summary>
         OnLCCallDelegate mOnLCCallDelegate;
 
@@ -712,7 +711,7 @@
 
         #endregion
 
-       
+
 #endif
 
         ///// <summary>
@@ -822,6 +821,16 @@
         /// 璁惧sip璐﹀彿 interphoneType鏄疕DL鏃舵墠浼氭湁鍊�
         /// </summary>
         public string deviceSipAccount;
+        /// <summary>
+        /// spk
+        /// </summary>
+        public string spk="";
+
+        //========================鍏ㄨ閫�==========================
+        /// <summary>
+        /// 璁惧缂栧彿锛岀浉褰撲簬鍏ㄨ閫氱殑LocalDirectory瀛楁
+        /// </summary>
+        public string deviceCode;
     }
 
 
@@ -865,7 +874,10 @@
         /// 鐙勮�愬厠 HDL Linphone
         /// </summary>
         HDL,
-
+        /// <summary>
+        /// 鍏ㄨ閫氬璁�
+        /// </summary>
+        FREEVIEW,
 
     }
 }

--
Gitblit v1.8.0