Merge remote-tracking branch 'origin/wjc' into Dev-Branch
1个文件已删除
27个文件已修改
4 文件已重命名
| | |
| | | public Application(IntPtr handle, Android.Runtime.JniHandleOwnership ownerShip) : base(handle, ownerShip) { } |
| | | public override void OnCreate() |
| | | { |
| | | |
| | | |
| | | |
| | | |
| | | if (Shared.Application.Activity != null) |
| | | { |
| | | //reStartApp(this); |
| | |
| | | 8508=History |
| | | 8509=Fluorite video door lock |
| | | 8510=Call from the doorbell |
| | | 8511=User Education |
| | | 8511=Door opener |
| | | 8512=Serial number |
| | | 8513=Model |
| | | |
| | |
| | | 8508=历史记录 |
| | | 8509=萤石视频门锁 |
| | | 8510=来自“门铃”呼叫 |
| | | 8511=用户人员 |
| | | 8511=开门人员 |
| | | 8512=序列号 |
| | | 8513=型号 |
| | | |
| | |
| | | 8508=History |
| | | 8509=Fluorite video door lock |
| | | 8510=Call from the doorbell |
| | | 8511=User Education |
| | | 8511=Door opener |
| | | 8512=Serial number |
| | | 8513=Model |
| | | |
| | |
| | | 8508=History |
| | | 8509=Fluorite video door lock |
| | | 8510=Call from the doorbell |
| | | 8511=User Education |
| | | 8511=Door opener |
| | | 8512=Serial number |
| | | 8513=Model |
| | | |
| | |
| | | 8508=History |
| | | 8509=Fluorite video door lock |
| | | 8510=Call from the doorbell |
| | | 8511=User Education |
| | | 8511=Door opener |
| | | 8512=Serial number |
| | | 8513=Model |
| | | |
| | |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\RTV.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\UnLocked.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\UnLocking.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\VideoDoorlockClose.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\VideoDoorLockOpen.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\History.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\Cell.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\FunctionBg\VideoDoorLockFunctionBg.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\Icon\securitydoorezviz.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\VideoDoorlockClose1.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\VideoDoorLockOpen1.png" /> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | | <AndroidResource Include="Resources\values\colors.xml" /> |
| | |
| | | /// <param name="notificationMessage"></param> |
| | | public override void OnNotifyMessageOpened(Context context, NotificationMessage notificationMessage) |
| | | { |
| | | |
| | | |
| | | //2020-12-23 解决点击通知栏打开不了APP问题 |
| | | //base.OnNotifyMessageOpened(context, notificationMessage); |
| | | OpenNotification(context, notificationMessage); |
| | |
| | | Utlis.WriteLine("PushMes extras : " + pushMes.Extras); |
| | | Utlis.WriteLine("PushMes HomeId : " + pushMes.HomeId);
|
| | |
|
| | | Intent i = new Intent(context, typeof(BaseActivity));//Intent intent=new Intent( 起始组件对象 , 目标 Service.class);
|
| | | i.SetFlags(ActivityFlags.NewTask);
|
| | | context.StartActivity(i); |
| | | if (Shared.Application.Activity==null) |
| | | {
|
| | | Intent i = new Intent(context, typeof(SplashActivity));//Intent intent=new Intent( 起始组件对象 , 目标 Service.class); |
| | | i.SetFlags(ActivityFlags.NewTask); |
| | | context.StartActivity(i);
|
| | | }
|
| | | else |
| | | { |
| | | Intent i = new Intent(context, typeof(BaseActivity));//Intent intent=new Intent( 起始组件对象 , 目标 Service.class); |
| | | i.SetFlags(ActivityFlags.NewTask); |
| | | context.StartActivity(i); |
| | | } |
| | | //解析msg
|
| | | AdjustPushMessage(pushMes);
|
| | | } |
| | |
| | | |
| | | public static void AdjustPushMessage(JPushMessageInfo pushMes)
|
| | | {
|
| | |
|
| | | new System.Threading.Thread(new System.Threading.ThreadStart(() =>
|
| | | {
|
| | | while (MainPage.BasePageView == null)
|
| | |
| | | { |
| | | |
| | | |
| | | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Xamarin.Android.Build.Tasks", "12.2.8.165")] |
| | | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Xamarin.Android.Build.Tasks", "1.0.0.0")] |
| | | public partial class Resource |
| | | { |
| | | |
| | |
| | | |
| | | namespace HDL_ON_Android |
| | | { |
| | | [Activity(Theme = "@style/SplashTheme", MainLauncher = true, Name = "com.hdl.onpro.SplashActivity",ScreenOrientation = ScreenOrientation.Portrait) ] |
| | | [Activity(Theme = "@style/SplashTheme", MainLauncher = true, LaunchMode = LaunchMode.SingleTask, Name = "com.hdl.onpro.SplashActivity", ScreenOrientation = ScreenOrientation.Portrait)] |
| | | [IntentFilter(new string[] { "com.hdl.onpro.SplashActivity", Intent.ActionView })] |
| | | public class SplashActivity : Activity |
| | | { |
| | |
| | | { |
| | | base.OnCreate(savedInstanceState); |
| | | |
| | | |
| | | |
| | | //Intent i = new Intent(this, typeof(BaseActivity));//Intent intent=new Intent( 起始组件对象 , 目标 Service.class); |
| | | //StartActivityForResult(i, 1); |
| | | //OverridePendingTransition(0, 0); |
| | | //initAll(); |
| | | |
| | | |
| | | |
| | | if (HDL_ON.OnAppConfig.Instance.FirstRunApp || !HDL_ON.OnAppConfig.Instance.isAgreePrivacyPolicy) |
| | | { |
| | | Language.CurrentLanguage = "Chinese"; |
| | | Locale locale1 = Locale.Default; |
| | | var localeList = Resources.Configuration.Locale; |
| | | Console.WriteLine("当前语言缩写:"+localeList.Language); |
| | | Console.WriteLine("当前语言缩写:" + localeList.Language); |
| | | if (localeList.Language == "zh") |
| | | { |
| | | Language.CurrentLanguage = "Chinese"; |
| | |
| | | } |
| | | |
| | | Intent intent = new Intent(this, typeof(AgreementActivity)); |
| | | StartActivityForResult(intent,99); |
| | | StartActivityForResult(intent, 99); |
| | | } |
| | | else |
| | | { |
| | |
| | | initOhterSdk(); |
| | | Finish();//关闭自己 |
| | | } |
| | | |
| | | } |
| | | |
| | | void initOhterSdk() |
| | |
| | | Language.CurrentLanguage = "Chinese"; |
| | | Locale locale1 = Locale.Default; |
| | | var localeList = Resources.Configuration.Locale; |
| | | Console.WriteLine("当前语言编号"+ localeList.Language); |
| | | Console.WriteLine("当前语言编号" + localeList.Language); |
| | | if (localeList.Language == "zh") |
| | | { |
| | | Language.CurrentLanguage = "Chinese"; |
| | | } |
| | | else if(localeList.Language == "es") |
| | | else if (localeList.Language == "es") |
| | | { |
| | | Language.CurrentLanguage = "Spanish"; |
| | | } |
| | |
| | | //} |
| | | //else |
| | | //{ |
| | | //Console.WriteLine("HHH 网络变化但处于后台"+internetStatus); |
| | | //Console.WriteLine("HHH 网络变化但处于后台"+internetStatus); |
| | | //} |
| | | |
| | | //网络变化处理 |
| | |
| | | } |
| | | |
| | | public static bool IsShowTip = true; |
| | | |
| | | |
| | | void checkSomeInfo() |
| | | { |
| | | try |
| | |
| | | return false; |
| | | } |
| | | |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | { |
| | | Language.CurrentLanguage = "russian"; |
| | | } |
| | | else if (NSLocale.PreferredLanguages[0].Contains( "bul")) |
| | | else if (NSLocale.PreferredLanguages[0].Contains("bul")) |
| | | { |
| | | Language.CurrentLanguage = "български"; |
| | | } |
| | |
| | | return true; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 处理通知消息 |
| | | /// </summary> |
| | | void HandleNotificationMessageUserInfo(NSDictionary userInfo, bool bFinishedLaunching) |
| | | |
| | | /// <summary> |
| | | /// 处理通知消息 |
| | | /// </summary> |
| | | void HandleNotificationMessageUserInfo(NSDictionary userInfo, bool bFinishedLaunching) |
| | | { |
| | | try |
| | | { |
| | |
| | | UserInfo.Current.pushMessageInfo = pushMes; |
| | | UserInfo.Current.inCall = DateTime.Now; |
| | | } |
| | | |
| | | |
| | | if (bFinishedLaunching) |
| | | { |
| | | if (pushMes.Extras != null) |
| | |
| | | } |
| | | else |
| | | { |
| | | HDLCommon.Current.AdjustPushMessage(pushMes); |
| | | //HDLCommon.Current.AdjustPushMessage(pushMes); |
| | | this.CommonAdjustPushMessage(pushMes);//2023年04月13日15:55:54 修改 |
| | | } |
| | | } |
| | | } |
| | | else |
| | | { |
| | | HDLCommon.Current.AdjustPushMessage(pushMes); |
| | | //HDLCommon.Current.AdjustPushMessage(pushMes); |
| | | this.CommonAdjustPushMessage(pushMes); |
| | | } |
| | | |
| | | } |
| | |
| | | } |
| | | |
| | | |
| | | public void CommonAdjustPushMessage(JPushMessageInfo pushMes) |
| | | { |
| | | new System.Threading.Thread(new System.Threading.ThreadStart(() => |
| | | { |
| | | while (MainPage.BasePageView == null) |
| | | { |
| | | System.Threading.Thread.Sleep(300); |
| | | } |
| | | Shared.Application.RunOnMainThread(() => |
| | | { |
| | | HDLCommon.Current.AdjustPushMessage(pushMes); |
| | | }); |
| | | })).Start(); |
| | | |
| | | } |
| | | |
| | | |
| | | } |
| | | |
| | | } |
| | |
| | | <PackageReference Include="Xamarin.Essentials"> |
| | | <Version>1.7.0</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="Xamarin.iOS.SwiftRuntimeSupport"> |
| | | <Version>0.2.1</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="Xamarin.iOS.MJRefresh"> |
| | | <Version>3.2.2</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="Xamarin.iOS.SwiftRuntimeSupport"> |
| | | <Version>0.2.1</Version> |
| | | </PackageReference> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\DoorLock\UnLockPictrue2.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\DoorLock\UnLockPictrue3.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\Icon\securitydoorezviz.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\DoorLock\VideoDoorLockOpen.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\DoorLock\VideoDoorlockClose.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\DoorLock\VideoDoorlockClose1.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\DoorLock\VideoDoorLockOpen1.png" /> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | | <ITunesArtwork Include="iTunesArtwork" /> |
| | |
| | | <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> |
| | | <plist version="1.0"> |
| | | <dict> |
| | | <key>CFBundleAllowMixedLocalizations</key> |
| | | <true/> |
| | | <key>CFBundleDisplayName</key> |
| | | <string>On Pro</string> |
| | | <key>CFBundleIdentifier</key> |
| | | <string>com.hdl.onpro</string> |
| | | <key>CFBundleName</key> |
| | | <string>On Pro</string> |
| | | <key>CFBundleShortVersionString</key> |
| | | <string>1.6.602303301</string> |
| | | <key>CFBundleURLTypes</key> |
| | | <array> |
| | | <dict> |
| | |
| | | <string>AispeechMobile</string> |
| | | </dict> |
| | | <dict> |
| | | <key>CFBundleTypeRole</key> |
| | | <string>Editor</string> |
| | | <key>CFBundleURLSchemes</key> |
| | | <array> |
| | | <string>hdlonpro</string> |
| | | </array> |
| | | <key>CFBundleTypeRole</key> |
| | | <string>Editor</string> |
| | | </dict> |
| | | <dict> |
| | | <key>CFBundleURLName</key> |
| | | <string>qqmusic</string> |
| | | </dict> |
| | | </array> |
| | | <key>CFBundleVersion</key> |
| | | <string>1.6.603301</string> |
| | | <key>LSApplicationQueriesSchemes</key> |
| | | <array> |
| | | <string>weixinULAPI</string> |
| | | <string>weixin</string> |
| | | <string>xiaoduapp</string> |
| | | <string>AispeechMobile</string> |
| | | <string>qqmusic</string> |
| | | </array> |
| | | <key>LSRequiresIPhoneOS</key> |
| | | <true/> |
| | | <key>MinimumOSVersion</key> |
| | | <string>12.2</string> |
| | | <key>NSAppTransportSecurity</key> |
| | | <dict> |
| | | <key>NSAllowsArbitraryLoads</key> |
| | | <true/> |
| | | <key>NSExceptionDomains</key> |
| | | <dict> |
| | | <key>NSExceptionDomains</key> |
| | |
| | | <key>NSExceptionMinimumTLSVersion</key> |
| | | <string>TLSv1.0</string> |
| | | </dict> |
| | | <key>NSAllowsArbitraryLoads</key> |
| | | <true/> |
| | | </dict> |
| | | <key>CFBundleIdentifier</key> |
| | | <string>com.hdl.onpro</string> |
| | | <key>LSRequiresIPhoneOS</key> |
| | | <true/> |
| | | <key>MinimumOSVersion</key> |
| | | <string>13.0</string> |
| | | <key>NSAppleMusicUsageDescription</key> |
| | | <string>App needs to access your music library to connect to an external player to play music.</string> |
| | | <key>NSBluetoothAlwaysUsageDescription</key> |
| | | <string>This application uses Bluetooth to communicate with the device, this application does not collect, store or record any data that communicates via Bluetooth.</string> |
| | | <key>NSBluetoothPeripheralUsageDescription</key> |
| | | <string>This application uses Bluetooth to communicate with the device, this application does not collect, store or record any data that communicates via Bluetooth.</string> |
| | | <key>NSCameraUsageDescription</key> |
| | | <string>App wants to access your camera to set the background picture of the room</string> |
| | | <key>NSContactsUsageDescription</key> |
| | | <string>LC Video will be use</string> |
| | | <key>NSFaceIDUsageDescription</key> |
| | | <string>Need to use Face ID for unlock verification</string> |
| | | <key>NSLocalNetworkUsageDescription</key> |
| | | <string>APP wants to use local network access permissions for WiFi distribution.</string> |
| | | <key>NSLocationAlwaysAndWhenInUseUsageDescription</key> |
| | | <string>LC Video will be use</string> |
| | | <key>NSLocationAlwaysUsageDescription</key> |
| | | <string>Use geographic location to provide services such as weather</string> |
| | | <key>NSLocationWhenInUseUsageDescription</key> |
| | | <string>EZ video will be use</string> |
| | | <key>NSMicrophoneUsageDescription</key> |
| | | <string>APP wants to use the phone's microphone for voice intercom</string> |
| | | <key>NSPhotoLibraryAddUsageDescription</key> |
| | | <string>App wants to access your photo library to set the background image of the room</string> |
| | | <key>NSPhotoLibraryUsageDescription</key> |
| | | <string>App wants to access your photo library to set the background image of the room</string> |
| | | <key>NSSiriUsageDescription</key> |
| | | <string>On Pro data will be send to Siri.</string> |
| | | <key>NSUserActivityTypes</key> |
| | | <array> |
| | | <string>HDLRunSceneIntent</string> |
| | | </array> |
| | | <key>NSVoIPUsageDescription</key> |
| | | <string>Make audio/video calls</string> |
| | | <key>UIAppFonts</key> |
| | | <array> |
| | | <string>titilliumtext25l005.otf</string> |
| | | </array> |
| | | <key>UIBackgroundModes</key> |
| | | <array> |
| | | <string>audio</string> |
| | | <string>location</string> |
| | | <string>voip</string> |
| | | <string>remote-notification</string> |
| | | </array> |
| | | <key>UIDeviceFamily</key> |
| | | <array> |
| | | <integer>1</integer> |
| | |
| | | </array> |
| | | <key>UIRequiresFullScreen</key> |
| | | <true/> |
| | | <key>NSCameraUsageDescription</key> |
| | | <string>App wants to access your camera to set the background picture of the room</string> |
| | | <key>NSPhotoLibraryUsageDescription</key> |
| | | <string>App wants to access your photo library to set the background image of the room</string> |
| | | <key>NSPhotoLibraryAddUsageDescription</key> |
| | | <string>App wants to access your photo library to set the background image of the room</string> |
| | | <key>NSMicrophoneUsageDescription</key> |
| | | <string>APP wants to use the phone's microphone for voice intercom</string> |
| | | <key>NSLocalNetworkUsageDescription</key> |
| | | <string>APP wants to use local network access permissions for WiFi distribution.</string> |
| | | <key>UISupportedInterfaceOrientations</key> |
| | | <array> |
| | | <string>UIInterfaceOrientationPortrait</string> |
| | | <string>UIInterfaceOrientationLandscapeRight</string> |
| | | <string>UIInterfaceOrientationLandscapeLeft</string> |
| | | </array> |
| | | <key>UIAppFonts</key> |
| | | <array> |
| | | <string>titilliumtext25l005.otf</string> |
| | | </array> |
| | | <key>UISupportedInterfaceOrientations~ipad</key> |
| | | <array> |
| | | <string>UIInterfaceOrientationPortrait</string> |
| | | </array> |
| | | <key>UIStatusBarStyle</key> |
| | | <string>UIStatusBarStyleLightContent</string> |
| | | <key>UIStatusBarTintParameters</key> |
| | | <dict> |
| | | <key>UINavigationBar</key> |
| | |
| | | <false/> |
| | | </dict> |
| | | </dict> |
| | | <key>UISupportedInterfaceOrientations</key> |
| | | <array> |
| | | <string>UIInterfaceOrientationPortrait</string> |
| | | <string>UIInterfaceOrientationLandscapeRight</string> |
| | | <string>UIInterfaceOrientationLandscapeLeft</string> |
| | | </array> |
| | | <key>UISupportedInterfaceOrientations~ipad</key> |
| | | <array> |
| | | <string>UIInterfaceOrientationPortrait</string> |
| | | </array> |
| | | <key>UIViewControllerBasedStatusBarAppearance</key> |
| | | <false/> |
| | | <key>CFBundleName</key> |
| | | <string>On Pro</string> |
| | | <key>XSAppIconAssets</key> |
| | | <string>Assets.xcassets/AppIcon.appiconset</string> |
| | | <key>CFBundleDisplayName</key> |
| | | <string>On Pro</string> |
| | | <key>UIStatusBarStyle</key> |
| | | <string>UIStatusBarStyleLightContent</string> |
| | | <key>CFBundleShortVersionString</key> |
| | | <string>1.7.1</string> |
| | | <key>CFBundleVersion</key> |
| | | <string>1.7.1</string> |
| | | <key>NSAppleMusicUsageDescription</key> |
| | | <string>App needs to access your music library to connect to an external player to play music.</string> |
| | | <key>NSLocationAlwaysUsageDescription</key> |
| | | <string>Use geographic location to provide services such as weather</string> |
| | | <key>LSApplicationQueriesSchemes</key> |
| | | <array> |
| | | <string>weixinULAPI</string> |
| | | <string>weixin</string> |
| | | <string>xiaoduapp</string> |
| | | <string>AispeechMobile</string> |
| | | <string>qqmusic</string> |
| | | </array> |
| | | <key>UIBackgroundModes</key> |
| | | <array> |
| | | <string>audio</string> |
| | | <string>location</string> |
| | | <string>voip</string> |
| | | <string>remote-notification</string> |
| | | </array> |
| | | <key>NSFaceIDUsageDescription</key> |
| | | <string>Need to use Face ID for unlock verification</string> |
| | | <key>CFBundleAllowMixedLocalizations</key> |
| | | <true/> |
| | | <key>NSBluetoothPeripheralUsageDescription</key> |
| | | <string>This application uses Bluetooth to communicate with the device, this application does not collect, store or record any data that communicates via Bluetooth.</string> |
| | | <key>NSBluetoothAlwaysUsageDescription</key> |
| | | <string>This application uses Bluetooth to communicate with the device, this application does not collect, store or record any data that communicates via Bluetooth.</string> |
| | | <key>NSVoIPUsageDescription</key> |
| | | <string>Make audio/video calls</string> |
| | | <key>NSSiriUsageDescription</key> |
| | | <string>On Pro data will be send to Siri.</string> |
| | | <key>NSUserActivityTypes</key> |
| | | <array> |
| | | <string>HDLRunSceneIntent</string> |
| | | </array> |
| | | <key>NSContactsUsageDescription</key> |
| | | <string>LC Video will be use</string> |
| | | <key>NSLocationAlwaysAndWhenInUseUsageDescription</key> |
| | | <string>LC Video will be use</string> |
| | | <key>NSLocationWhenInUseUsageDescription</key> |
| | | <string>EZ video will be use</string> |
| | | <key>XSLaunchImageAssets</key> |
| | | <string>Assets.xcassets/LaunchImage.launchimage</string> |
| | | <key>UILaunchStoryboardName</key> |
| | | <string>LaunchScreen</string> |
| | | </dict> |
| | | </plist> |
| | |
| | | <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/> |
| | | </imageView> |
| | | </subviews> |
| | | <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> |
| | | <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/> |
| | | </view> |
| | | </viewController> |
| | | <placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/> |
| | |
| | | 8508=History |
| | | 8509=Fluorite video door lock |
| | | 8510=Call from the doorbell |
| | | 8511=User Education |
| | | 8511=Door opener |
| | | 8512=Serial number |
| | | 8513=Model |
| | | |
| | |
| | | 8508=历史记录 |
| | | 8509=萤石视频门锁 |
| | | 8510=来自“门铃”呼叫 |
| | | 8511=用户人员 |
| | | 8511=开门人员 |
| | | 8512=序列号 |
| | | 8513=型号 |
| | | |
| | |
| | | 8508=History |
| | | 8509=Fluorite video door lock |
| | | 8510=Call from the doorbell |
| | | 8511=User Education |
| | | 8511=Door opener |
| | | 8512=Serial number |
| | | 8513=Model |
| | | |
| | |
| | | 8508=History |
| | | 8509=Fluorite video door lock |
| | | 8510=Call from the doorbell |
| | | 8511=User Education |
| | | 8511=Door opener |
| | | 8512=Serial number |
| | | 8513=Model |
| | | |
| | |
| | | 8508=History |
| | | 8509=Fluorite video door lock |
| | | 8510=Call from the doorbell |
| | | 8511=User Education |
| | | 8511=Door opener |
| | | 8512=Serial number |
| | | 8513=Model |
| | | |
| | |
| | | { |
| | | try |
| | | { |
| | | |
| | | |
| | | //Extras为空不处理 |
| | | if (string.IsNullOrEmpty(jpushMessageInfo.Extras)) return; |
| | | |
| | |
| | | HDL_ON.UI.UI2.FuntionControlView.VideoDoorLock.CommonMethod.Current.DoorLockPush(jpushMessageInfo); |
| | | } |
| | | |
| | | |
| | | } |
| | | } |
| | | catch (Exception EX) |
| | |
| | | /// </summary> |
| | | public const int laizimenlinghujiao = 8510; |
| | | /// <summary> |
| | | /// 用户人员 |
| | | /// 开门人员 |
| | | /// </summary> |
| | | public const int yonghurenyuan = 8511; |
| | | public const int kaimenrenyuan = 8511; |
| | | /// <summary> |
| | | /// 序列号 |
| | | /// </summary> |
| | |
| | | return list; |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// 猫眼 |
| | | /// </summary> |
| | |
| | | /// </summary> |
| | | public const string VideoDoorLock="security.door.ezviz"; |
| | | /// <summary> |
| | | /// 萤石摄像头 |
| | | /// </summary> |
| | | public const string Ev_Ipcam = "security.ipcam.ez"; |
| | | /// <summary> |
| | | /// 萤石视频门锁spk列表 |
| | | /// </summary> |
| | | /// <returns></returns> |
| | |
| | | return list; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 萤石摄像头spk列表 |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | public static List<string> GetEvIpcamSPKList() |
| | | { |
| | | var list = new List<string>(); |
| | | list.Add(Ev_Ipcam); |
| | | return list; |
| | | } |
| | | |
| | | #region 灯光 |
| | | /// <summary> |
| | | /// (开关灯) |
| | |
| | | using Shared; |
| | | using System.Collections.Generic; |
| | | using HDL_ON.Entity; |
| | | |
| | | using HDL_ON.UI.UI2.FuntionControlView.VideoDoorLock; |
| | | |
| | | namespace HDL_ON.UI.UI2.Intelligence.Automation |
| | | { |
| | |
| | | case SPK.VideoDoorLock: |
| | | { |
| | | LogicView.FunTypeView view1 = new LogicView.FunTypeView(); |
| | | view1.btnText.TextID=StringId.yonghurenyuan; |
| | | view1.btnText.TextID=StringId.kaimenrenyuan; |
| | | view1.btnText.Name = Language.StringByID(StringId.shipinmensuo); |
| | | fLayout.AddChidren(view1.FLayoutView()); |
| | | view1.btnClick.MouseUpEventHandler += (sender, e) => |
| | |
| | | /// <param name="frame">当前界面</param> |
| | | /// <param name="device">当前设备</param> |
| | | /// <param name="btnState">旧状态</param> |
| | | public void FaceAction(FrameLayout frame, Entity.Function device,Button btnState) { |
| | | public void FaceAction(FrameLayout frame, Entity.Function device, Button btnState) |
| | | { |
| | | selectedState = device.spk + "_"; |
| | | Loading loading = new Loading(); |
| | | frame.AddChidren(loading); |
| | | loading.Start(); |
| | | System.Threading.Tasks.Task.Run(() => |
| | | |
| | | CommonMethod.Current.SunThread(() => |
| | | { |
| | | try |
| | | { |
| | | var faceIDList = Send.Current.GetListHomeFace(device.deviceId, true); |
| | | List<string> faceNameList = new List<string>(); |
| | | for (int i = 0; i < faceIDList.Count; i++) |
| | | { |
| | | var face = faceIDList[i]; |
| | | faceNameList.Add(face.userName); |
| | | } |
| | | Application.RunOnMainThread(() => |
| | | var faceIdList = Send.Current.GetListHomeFace(device.deviceId, true); |
| | | |
| | | CommonMethod.Current.MainThread(() => |
| | | { |
| | | loading.Hide(); |
| | | string stateValue=btnState.Tag==null?"":btnState.Tag.ToString(); |
| | | PublicInterface publicInterface = new PublicInterface(); |
| | | publicInterface.FrameOrVv(this, faceNameList, new List<string> { btnState.Text }, device.name, (index) => |
| | | { |
| | | var face = faceIDList[index]; |
| | | //界面显示选中值 |
| | | btnState.Text = face.userName; |
| | | //数据封装 |
| | | AddDictionary("open_type", "1", "integer"); |
| | | AddDictionary("user_id", face.userId, "string"); |
| | | publicInterface.MultiSelectShow(this, faceIdList, device.name, stateValue, (indexeList) => |
| | | { |
| | | if (indexeList.Count > 0) |
| | | { |
| | | dicSateteList.Clear(); |
| | | string s = string.Empty; |
| | | string tag = string.Empty; |
| | | //数据封装 |
| | | AddDictionary("open_type", "1", "integer"); |
| | | for (int indexe = 0; indexe < indexeList.Count; indexe++) |
| | | { |
| | | if (indexe > faceIdList.Count) |
| | | { |
| | | continue; |
| | | } |
| | | var face = faceIdList[indexe]; |
| | | AddDictionary("user_id", face.userId, "string"); |
| | | s += face.userName; |
| | | s += ","; |
| | | tag += face.userId; |
| | | tag += "_"; |
| | | } |
| | | //界面显示选中值 |
| | | btnState.Text = s; |
| | | btnState.Tag = tag; |
| | | } |
| | | |
| | | }, false); |
| | | |
| | | }); |
| | | }); |
| | | } |
| | | catch { } |
| | |
| | | Loading loading = new Loading(); |
| | | frame.AddChidren(loading); |
| | | loading.Start(); |
| | | System.Threading.Tasks.Task.Run(() => |
| | | CommonMethod.Current.SunThread(() => |
| | | { |
| | | try |
| | | { |
| | | var userList =FuntionControlView.VideoDoorLock.VideDoorLockSend.Current.GetVideoDoorLockUserListInfo(device); |
| | | List<string> userNameList = new List<string>(); |
| | | for (int i = 0; i < userList.Count; i++) |
| | | var faceIdList = Send.Current.GetVideoDoorLockUserListInfo(device); |
| | | CommonMethod.Current.MainThread(() => |
| | | { |
| | | var user = userList[i]; |
| | | userNameList.Add(user.extUserName); |
| | | } |
| | | Application.RunOnMainThread(() => |
| | | { |
| | | loading.Hide(); |
| | | PublicInterface publicInterface = new PublicInterface();//用户界面 |
| | | publicInterface.FrameOrVv(this, userNameList, new List<string> { btnState.Text }, device.name, (index) => |
| | | { |
| | | var userId = userNameList[index]; |
| | | //界面显示选中值 |
| | | btnState.Text = userId; |
| | | //数据封装 |
| | | AddDictionary("open_user", userId, "string"); |
| | | |
| | | }, false); |
| | | loading.Hide(); |
| | | string stateValue = btnState.Text == null ? "" : btnState.Text.ToString(); |
| | | PublicInterface publicInterface = new PublicInterface(); |
| | | publicInterface.MultiSelectShow(this, faceIdList, device.name, stateValue, (indexeList) => |
| | | { |
| | | if (indexeList.Count > 0) |
| | | { |
| | | dicSateteList.Clear(); |
| | | string s = string.Empty; |
| | | string tag = string.Empty; |
| | | for (int indexe = 0; indexe < indexeList.Count; indexe++) |
| | | { |
| | | if (indexe > faceIdList.Count) |
| | | { |
| | | continue; |
| | | } |
| | | var face = faceIdList[indexe]; |
| | | |
| | | //数据封装<高胜说萤石那边是推送用户名> |
| | | AddDictionary("open_user", face.userName, "string"); |
| | | s += face.userName; |
| | | s += ","; |
| | | tag += face.userId; |
| | | tag += "_"; |
| | | } |
| | | //界面显示选中值 |
| | | btnState.Text = s; |
| | | btnState.Tag = tag; |
| | | } |
| | | |
| | | }); |
| | | |
| | | }); |
| | | } |
| | |
| | | var dic = dictionaryB[i]; |
| | | string key = dic["key"]; |
| | | string comparatorValue = dic["comparator"]; |
| | | string value = dic["value"]; |
| | | if (dictionaryA["key"] == key && dictionaryA["comparator"] == comparatorValue) |
| | | { |
| | | //判断是否存在 |
| | | valueInt = i; |
| | | break; |
| | | if (this.checkSpk()) |
| | | { |
| | | //有些设备需要增加这个判断 |
| | | if (dictionaryA["value"] == value) |
| | | { |
| | | //判断是否存在 |
| | | valueInt = i; |
| | | break; |
| | | } |
| | | } |
| | | else |
| | | { |
| | | //判断是否存在 |
| | | valueInt = i; |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | return valueInt; |
| | | } |
| | | /// <summary> |
| | | /// 检查是否支持 |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | private bool checkSpk() |
| | | { |
| | | if (this.function.spk == SPK.VideoDoorLock || |
| | | this.function.spk == SPK.doorgate |
| | | ) |
| | | { |
| | | return true; |
| | | } |
| | | return false; |
| | | |
| | | } |
| | | /// <summary> |
| | | /// 判断dictionaryB是否完整包含另一个dictionaryA |
| | | /// </summary> |
| | | /// <param name="dictionaryA"></param> |
| | |
| | | break; |
| | | case SPK.VideoDoorLock: |
| | | { |
| | | string value = this.GetValue(dicList); |
| | | inputView.btnState.Text = value; |
| | | string s = string.Empty; |
| | | string tag = string.Empty; |
| | | for (int b = 0; b < dicList.Count; b++) |
| | | { |
| | | var dic = dicList[b]; |
| | | //var userId = dic["value"].ToString(); |
| | | //var FaceItem = this.GetVideoDoorLockUserItem(userId, device); |
| | | //s += FaceItem.userName; |
| | | //s += ","; |
| | | //tag += FaceItem.userId; |
| | | //tag += "_"; |
| | | var userName = dic["value"].ToString(); |
| | | s += userName; |
| | | s += ","; |
| | | } |
| | | inputView.btnState.Text = s; |
| | | } |
| | | break; |
| | | case SPK.doorgate: |
| | | { |
| | | string s = string.Empty; |
| | | if (inputCondition.identifier == "door_call_cloud_event") |
| | | { |
| | | inputView.btnState.Text = Language.StringByID(StringId.shipintonghuahujiao); |
| | | s = Language.StringByID(StringId.shipintonghuahujiao); |
| | | } |
| | | else |
| | | { |
| | | string userId = this.GetKeyValue("user_id",dicList); |
| | | var FaceItem = this.GetFaceItem(userId, device.deviceId); |
| | | inputView.btnState.Text = FaceItem.userName; |
| | | for (int b = 0; b < dicList.Count; b++) |
| | | { |
| | | var dic = dicList[b]; |
| | | var key = dic["key"].ToString(); |
| | | if (key != "user_id") |
| | | { |
| | | continue; |
| | | } |
| | | var userId = dic["value"].ToString(); |
| | | var FaceItem = this.GetFaceItem(userId, device.deviceId); |
| | | s += FaceItem.userName; |
| | | s += ","; |
| | | |
| | | |
| | | } |
| | | |
| | | } |
| | | inputView.btnState.Text = s; |
| | | } |
| | | break; |
| | | case SPK.IpCam_Imou: |
| | |
| | | //开关灯光 |
| | | case SPK.AirSwitch: |
| | | case SPK.LightSwitch: |
| | | //机械手 |
| | | //机械手 |
| | | case SPK.MechanicalArm: |
| | | { |
| | | foreach (var dic in dicList) |
| | |
| | | break; |
| | | case SPK.VideoDoorLock: |
| | | { |
| | | foreach (var dic in dicList) |
| | | string s = string.Empty; |
| | | string tag = string.Empty; |
| | | for (int b = 0; b < dicList.Count; b++) |
| | | { |
| | | string value = dic["value"]; |
| | | button1.Text = value; |
| | | var dic = dicList[b]; |
| | | //var userId = dic["value"].ToString(); |
| | | //var FaceItem = this.GetVideoDoorLockUserItem(userId, device); |
| | | //s += FaceItem.userName; |
| | | //s += ","; |
| | | //tag += FaceItem.userId; |
| | | //tag += "_"; |
| | | var userName = dic["value"].ToString(); |
| | | s += userName; |
| | | s += ","; |
| | | } |
| | | button1.Text = s; |
| | | button1.Tag = tag; |
| | | } |
| | | break; |
| | | case SPK.MusicStandard: |
| | |
| | | break; |
| | | case SPK.doorgate: |
| | | { |
| | | string value = this.GetKeyValue("user_id", dicList); |
| | | button2.Text = this.GetFaceItem(value, device.deviceId).userName; |
| | | string s = string.Empty; |
| | | string tag = string.Empty; |
| | | for (int b = 0; b < dicList.Count; b++) |
| | | { |
| | | var dic = dicList[b]; |
| | | var key = dic["key"].ToString(); |
| | | if (key != "user_id") |
| | | { |
| | | continue; |
| | | } |
| | | var userId = dic["value"].ToString(); |
| | | var FaceItem = this.GetFaceItem(userId, device.deviceId); |
| | | s += FaceItem.userName; |
| | | s += ","; |
| | | tag += FaceItem.userId; |
| | | tag += "_"; |
| | | } |
| | | button2.Text = s; |
| | | button2.Tag = tag; |
| | | } |
| | | break; |
| | | |
| | | |
| | | } |
| | | } |
| | | /// <summary> |
| | |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// 查找指定userId |
| | | /// 查找指定可视对讲userId |
| | | /// </summary> |
| | | /// <param name="userId"></param> |
| | | /// <returns></returns> |
| | |
| | | } |
| | | return face; |
| | | } |
| | | /// <summary> |
| | | /// 查找指定萤石视频门锁userId |
| | | /// </summary> |
| | | /// <param name="userId"></param> |
| | | /// <returns></returns> |
| | | public Face GetVideoDoorLockUserItem(string userId, Function device) |
| | | { |
| | | if (Send.Current.VideoDoorLockUserListInfo.Count == 0) |
| | | { |
| | | Send.Current.GetVideoDoorLockUserListInfo(device); |
| | | } |
| | | var face = Send.Current.VideoDoorLockUserListInfo.Find((o) => { return o.userId == userId; }); |
| | | if (face == null) |
| | | { |
| | | face = new Face(); |
| | | } |
| | | return face; |
| | | } |
| | | |
| | | } |
| | | } |
| | |
| | | //new Entity.Function { sid = "1234567890", name = "超声波传感器", spk = Entity.SPK.SensorUtrasonic }, |
| | | // new Entity.Function { sid = "1234567891", name = "温度传感器", spk = Entity.SPK.SensorTemperature }, |
| | | // new Entity.Function { sid = "1234567892", name = "湿度传感器", spk = Entity.SPK.SensorHumidity }, |
| | | new Entity.Function { sid = "12345678933456", name = "门锁", spk = Entity.SPK.DoorLock }, |
| | | new Entity.Function { sid = "1234567895444", name = "视频门锁", spk = Entity.SPK.VideoDoorLock }, |
| | | //new Entity.Function { sid = "12345678968888", name = "pm10", spk = Entity.SPK.SensorPm10 }, |
| | | //new Entity.Function { sid = "12345678933456", name = "门锁", spk = Entity.SPK.DoorLock }, |
| | | // new Entity.Function { sid = "1234567895444", name = "视频门锁", spk = Entity.SPK.VideoDoorLock }, |
| | | new Entity.Function { sid = "12345678968888", name = "pm10", spk = Entity.SPK.LightDimming }, |
| | | // new Entity.Function { sid = "1234567897", name = "毫米波传感器1", spk = Entity.SPK.SenesorMegahealth2 }, |
| | | // new Entity.Function { sid = "1234567899", name = "门磁传感器", spk = Entity.SPK.SensorDoorWindow }, |
| | | // new Entity.Function { sid = "12345678991234", name = "HDL机械手", spk = Entity.SPK.MechanicalArm }, |
| | |
| | | Gravity = Gravity.CenterVertical, |
| | | TextAlignment = TextAlignment.CenterLeft, |
| | | }; |
| | | |
| | | |
| | | /// <summary> |
| | | /// (条件或者目标)设备状态文本描述 |
| | | /// </summary> |
| | |
| | | Y = Application.GetRealHeight(17), |
| | | X = Application.GetRealWidth(375 - 48 - 130), |
| | | TextAlignment = TextAlignment.CenterRight, |
| | | Text="", |
| | | Text = "", |
| | | }; |
| | | /// <summary> |
| | | /// 图标 |
| | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 多选择 |
| | | /// </summary> |
| | | /// <param name="frameLayout">父控件</param> |
| | | /// <param name="list">显示数据源</param> |
| | | /// <param name="titleText"></param> |
| | | /// <param name="stateTextList">之前状态文本</param> |
| | | /// <param name="action">返回索引值列表</param> |
| | | /// <param name="textSize">显示文本字体大小</param> |
| | | public void MultiSelectShow(FrameLayout frameLayout, List<Face> list, string titleText, string stateTexts, Action<List<int>> action, int textSize = LogicView.TextSize.text14) |
| | | { |
| | | LogicView.DateView view = new LogicView.DateView(); |
| | | view.btnTitle.Text = titleText; |
| | | view.FLayoutView(frameLayout, list.Count); |
| | | view.btnCancel.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | //移除fLayout界面 |
| | | view.frameLayout.RemoveFromParent(); |
| | | }; |
| | | List<int> intList = new List<int>(); |
| | | for (int i = 0; i < list.Count; i++) |
| | | { |
| | | var face= list[i]; |
| | | LogicView.CheckView checkView = new LogicView.CheckView(); |
| | | checkView.frameLayout.Y = Application.GetRealHeight(56 + 50 * i); |
| | | checkView.btnText.TextSize = textSize; |
| | | view.frameLayout.AddChidren(checkView.FLayoutView()); |
| | | checkView.btnText.Text = face.userName; |
| | | checkView.btnClick.Tag = i;//标记 |
| | | |
| | | if (stateTexts.Contains(face.userId)) |
| | | { |
| | | //显示之前的选中状态 |
| | | checkView.btnCheckIcon.IsSelected = true; |
| | | intList.Add(i); |
| | | } |
| | | //点击事件 |
| | | checkView.btnClick.MouseUpEventHandler += (sender1, e1) => |
| | | { |
| | | |
| | | int clickIndex =int.Parse(checkView.btnClick.Tag.ToString()); |
| | | checkView.btnClick.IsSelected = !checkView.btnClick.IsSelected; |
| | | if (checkView.btnClick.IsSelected) |
| | | { |
| | | checkView.btnCheckIcon.IsSelected = true; |
| | | if (!intList.Contains(clickIndex)) |
| | | { |
| | | //添加选中数据 |
| | | intList.Add(clickIndex); |
| | | } |
| | | } |
| | | else |
| | | { |
| | | checkView.btnCheckIcon.IsSelected = false; |
| | | if (intList.Contains(clickIndex)) |
| | | { |
| | | //移除选中数据 |
| | | intList.Remove(clickIndex); |
| | | } |
| | | } |
| | | |
| | | }; |
| | | |
| | | } |
| | | view.btnConfirm.MouseUpEventHandler += (sender1, e1) => |
| | | { |
| | | if (intList.Count == 0) |
| | | { |
| | | return; |
| | | } |
| | | action(intList); |
| | | //移除fLayout界面 |
| | | view.frameLayout.RemoveFromParent(); |
| | | }; |
| | | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 月-多选择 |
| | | /// </summary> |
| | | /// <param name="frameLayout">父控件</param> |
| | |
| | | } |
| | | } |
| | | public List<Face> faceList = new List<Face>(); |
| | | public List<Face> VideoDoorLockUserListInfo = new List<Face>(); |
| | | /// <summary> |
| | | /// 调用获取住宅子账号列表 |
| | | /// </summary> |
| | |
| | | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 获取门锁用户列表(萤石视频门锁) |
| | | /// </summary> |
| | | /// <param name="deviceId">设备</param> |
| | | /// <returns></returns> |
| | | public List<Face> GetVideoDoorLockUserListInfo(Function device) |
| | | { |
| | | var userList = FuntionControlView.VideoDoorLock.VideDoorLockSend.Current.GetVideoDoorLockUserListInfo(device); |
| | | List<Face> faceIdList = new List<Face>(); |
| | | for (int i = 0; i < userList.Count; i++) |
| | | { |
| | | Face face = new Face(); |
| | | var user = userList[i]; |
| | | face.userId = user.extUserId; |
| | | face.userName = user.extUserName; |
| | | faceIdList.Add(face); |
| | | } |
| | | VideoDoorLockUserListInfo.Clear(); |
| | | VideoDoorLockUserListInfo.AddRange(faceIdList); |
| | | return faceIdList; |
| | | } |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | ///请求服务器(与住宅有关:例如;homeId) |
| | | /// </summary> |
| | |
| | | ///开关 |
| | | LogicView.FunTypeView curtainSwitchView = new LogicView.FunTypeView(); |
| | | curtainSwitchView.btnText.TextID = StringId.switchLogic; |
| | | fLayout.AddChidren(curtainSwitchView.FLayoutView()); |
| | | //fLayout.AddChidren(curtainSwitchView.FLayoutView());//2023年04月17日16:27:10 产品要求的去掉 |
| | | ///百分比 |
| | | LogicView.FunTypeView crtainPercentumView = new LogicView.FunTypeView(); |
| | | crtainPercentumView.frameLayout.Y = curtainSwitchView.frameLayout.Bottom; |
| | | //crtainPercentumView.frameLayout.Y = curtainSwitchView.frameLayout.Bottom; |
| | | crtainPercentumView.btnText.TextID = StringId.percentum; |
| | | fLayout.AddChidren(crtainPercentumView.FLayoutView()); |
| | | crtainPercentumView.btnState.Text = "5%";//产品经理晓辉要求改的 2021-11-06 |
| | |
| | | break; |
| | | case SPK.Peephole: |
| | | case SPK.VideoDoorLock: |
| | | case SPK.Ev_Ipcam: |
| | | { |
| | | //跳转到android,ios那边去 |
| | | HDL_ON.UI.UI2.FuntionControlView.VideoDoorLock.CommonMethod.Current.SkipAddDeviceActivity(device.spk); |
| | |
| | | /// </summary> |
| | | public class CommonMethod |
| | | { |
| | | |
| | | private Loading loading; |
| | | /// <summary> |
| | | /// 记录当前界面索引值 |
| | |
| | | this.SunThread(() => |
| | | { |
| | | var list = this.GetVideoDoorLockLockModelsList("notAllowedConfigNetworkModels"); |
| | | |
| | | this.MainThread(() => |
| | | { |
| | | #if __IOS__ |
| | |
| | | /// <param name="isDialog">是否需要弹框</param> |
| | | public void SkipRTVActivity(string deviceSerial, string deviceId, string spk, bool isDialog) |
| | | { |
| | | |
| | | this.Loading.Start(); |
| | | this.InitializationAndroidData((isEzChildAccessToken) => |
| | | { |
| | | this.MainThread(() => |
| | | { |
| | | this.Loading.Hide(); |
| | | if (isDialog) |
| | | { |
| | | Video.View.ShowDialog.Currnet.ClickBox(Language.StringByID(StringId.laizimenlinghujiao), (dialog) => |
| | |
| | | public void InitializationAndroidData(Action<bool> action) |
| | | { |
| | | bool isBool = true; |
| | | this.Loading.Start(); |
| | | //this.Loading.Start(); |
| | | this.SunThread(() => |
| | | { |
| | | try |
| | |
| | | { |
| | | //Token |
| | | isBool = false; |
| | | this.ShowTip("获取萤石云子账号token失败。"); |
| | | //this.ShowTip("获取萤石云子账号token失败。"); |
| | | return; |
| | | } |
| | | |
| | | string appKey = "1aa98a90489b4838b966b57018b4b04b";//正式服务器 |
| | | //if (OnAppConfig.Instance.RequestHttpsHost == "https://test-gz.hdlcontrol.com") |
| | | //{ |
| | | // appKey = "941b1b72b6294998acfd36c14931b675";//用在测试服务器推送的 |
| | | //} |
| | | |
| | | |
| | | #if __IOS__ |
| | | //iOS |
| | | //初始化萤石云SDK,中文国内key、英文海外key 开发者账号使用应用包名申请的APPKEY,不同包名应用需配置不同的APPKEY |
| | | EZSDK.IOS.EZSDK.SharedInstance().InitLibWithAppKey("1aa98a90489b4838b966b57018b4b04b", "1aa98a90489b4838b966b57018b4b04b"); |
| | | EZSDK.IOS.EZSDK.SharedInstance().InitLibWithAppKey(appKey, appKey); |
| | | //1.设置所需河东的AccessToken和RefreshToken、域名地址 |
| | | EZSDK.IOS.EZSDK.SharedInstance().SetHDlAccessToken(UserInfo.Current.LoginTokenString, UserInfo.Current.RefreshToken); |
| | | EZSDK.IOS.EZSDK.SharedInstance().SetRequestHttpsHostAndPlatform(OnAppConfig.Instance.RequestHttpsHost, 1, DB_ResidenceData.Instance.CurrentRegion.id); |
| | |
| | | //info.de |
| | | //EZSDK.IOS.EZSDK.Play(info); |
| | | #else |
| | | HDLEzvizSdk.Instance.Init(Application.Activity.Application, ezChildAccessToken, UserInfo.Current.LoginTokenString, UserInfo.Current.RefreshToken, OnAppConfig.Instance.RequestHttpsHost, "1aa98a90489b4838b966b57018b4b04b", 1, DB_ResidenceData.Instance.CurrentRegion.id); |
| | | |
| | | HDLEzvizSdk.Instance.Init(Application.Activity.Application, ezChildAccessToken, UserInfo.Current.LoginTokenString, UserInfo.Current.RefreshToken, OnAppConfig.Instance.RequestHttpsHost, appKey, 1, DB_ResidenceData.Instance.CurrentRegion.id); |
| | | |
| | | #endif |
| | | |
| | |
| | | { |
| | | this.MainThread(() => |
| | | { |
| | | this.Loading.Hide(); |
| | | //this.Loading.Hide(); |
| | | action?.Invoke(isBool); |
| | | }); |
| | | } |
| | |
| | | /// <returns>返回结果不会为null</returns> |
| | | public List<string> GetVideoDoorLockLockModelsList(string mode = "lockModels") |
| | | { |
| | | return VideDoorLockSend.Current.GetVideoDoorLockLockModelsList(mode); |
| | | var lockModels = VideDoorLockSend.Current.GetVideoDoorLockLockModelsList(); |
| | | if (mode == "lockModels") |
| | | { |
| | | return lockModels.lockModels; |
| | | } |
| | | else |
| | | { |
| | | return lockModels.notAllowedConfigNetworkModels; |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// 门锁推送 |
| | |
| | | |
| | | if (comerom == Comerom.collect) |
| | | { |
| | | return "FunctionIcon/DoorLock/VideoDoorLockOpen.png"; |
| | | return "FunctionIcon/DoorLock/VideoDoorLockOpen1.png"; |
| | | } |
| | | else |
| | | { |
| | | return "FunctionIcon/DoorLock/VideoDoorlockClose.png"; |
| | | return "FunctionIcon/DoorLock/VideoDoorlockClose1.png"; |
| | | } |
| | | |
| | | } |
| | |
| | | /// </summary> |
| | | /// <param name="tipType">是否需要提示,默认提示</param> |
| | | /// <returns>返回结果不会为null</returns> |
| | | public List<string> GetVideoDoorLockLockModelsList(string mode,TipType tipType = TipType.flicker) |
| | | public LockModels GetVideoDoorLockLockModelsList(TipType tipType = TipType.flicker) |
| | | { |
| | | var responsePackNew = UI.Music.SendMethod.Current.RequestServerhomeId(new object { }, NewAPI.Api_Post_Lock_Models, "获取萤石门锁型号列表"); |
| | | if (!this.DataChecking(responsePackNew, tipType)) |
| | | { |
| | | return new List<string>(); |
| | | return new LockModels(); |
| | | } |
| | | var lockModels = Newtonsoft.Json.JsonConvert.DeserializeObject<LockModels>(responsePackNew.Data.ToString()); |
| | | if (lockModels == null) |
| | | { |
| | | return new LockModels().lockModels; |
| | | return new LockModels(); |
| | | } |
| | | if ( mode =="lockModels") { |
| | | return lockModels.lockModels; |
| | | } |
| | | else { |
| | | return lockModels.notAllowedConfigNetworkModels; |
| | | } |
| | | return lockModels; |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | btnCollectIcon.IsSelected = this.device.collect = !btnCollectIcon.IsSelected; |
| | | this.device.CollectFunction(); |
| | | }; |
| | | |
| | | int delayTimeMaxValue = 0;// |
| | | var startTime = DateTime.Now; |
| | | //实时视频 |
| | | this.rtvFL.SetClickListener((fl, btnStateImage, btnStateText) => |
| | | { |
| | | bool isDeyayClick = false; |
| | | var clickTime = DateTime.Now; |
| | | if ((clickTime - startTime).TotalMilliseconds > delayTimeMaxValue) |
| | | { |
| | | delayTimeMaxValue = 2*1000; |
| | | startTime = clickTime; |
| | | isDeyayClick = true; |
| | | } |
| | | if (!isDeyayClick) |
| | | { |
| | | return; |
| | | } |
| | | CommonMethod.Current.SkipRTVActivity(this.device.sid, this.device.deviceId, this.device.spk, false); |
| | | |
| | | }); |
| | | //临时密码 |
| | | this.pswFL.SetClickListener((fl, btnStateImage, btnStateText) => |