| | |
| | | <Properties StartupConfiguration="{09712674-2A38-407B-B1E2-560B2C352F9A}|Default"> |
| | | <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneDeviceTarget.00008020-000404163432002E" /> |
| | | <MonoDevelop.Ide.Workbench> |
| | | <MonoDevelop.Ide.Workbench ActiveDocument="HDL-ON_iOS/Resources/Language.ini"> |
| | | <Files> |
| | | <File FileName="HDL_ON/DAL/Server/HttpUtil.cs" Line="1" Column="1" /> |
| | | <File FileName="HDL-ON_Android/Assets/Language.ini" Line="1599" Column="10" /> |
| | | <File FileName="HDL-ON_iOS/Resources/Language.ini" Line="2138" Column="1" /> |
| | | </Files> |
| | | <Pads> |
| | | <Pad Id="ProjectPad"> |
| | | <State name="__root__"> |
| | | <Node name="HDL_APP_Project" expanded="True"> |
| | | <Node name="HDL-ON_Android" selected="True" /> |
| | | <Node name="HDL-ON_Android" expanded="True"> |
| | | <Node name="Assets" expanded="True" /> |
| | | </Node> |
| | | <Node name="HDL-ON_iOS" expanded="True"> |
| | | <Node name="Resources" expanded="True"> |
| | | <Node name="Language.ini" selected="True" /> |
| | | </Node> |
| | | </Node> |
| | | </Node> |
| | | </State> |
| | | </Pad> |
| | |
| | | <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL_ON/UI/UI2/FuntionControlView/Electrical/IrFanPage.cs" relfile="HDL_ON/UI/UI2/FuntionControlView/Electrical/IrFanPage.cs" line="42" column="1" /> |
| | | <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL_ON/Common/ApiUtlis.cs" relfile="HDL_ON/Common/ApiUtlis.cs" line="390" column="1" /> |
| | | <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL_ON/DAL/Mqtt/MqttClient.cs" relfile="HDL_ON/DAL/Mqtt/MqttClient.cs" line="422" column="1" /> |
| | | <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs" relfile="HDL_ON/UI/UI2/FuntionControlView/EnvironmentalScience/EnvironmentalSensorPage.cs" line="747" column="1" /> |
| | | </BreakpointStore> |
| | | </MonoDevelop.Ide.DebuggingService.Breakpoints> |
| | | <MultiItemStartupConfigurations /> |
old mode 100644
new mode 100755
Binary files differ
old mode 100644
new mode 100755
Binary files differ
| | |
| | | 324=Scene delay |
| | | 325=Delay setting |
| | | 326=Delay |
| | | 327=Catch Scene |
| | | 327=Capture the scene |
| | | 328=Film scene |
| | | 329=General |
| | | 330=Automatic mode |
| | |
| | | 453=Alarm mute |
| | | 454=Deployment information |
| | | 455=The name can not be blank. |
| | | |
| | | 456=Canvas |
| | | 457=Energy consumption |
| | | 458=Date |
| | |
| | | 477=Swing |
| | | 478=Pattern |
| | | 479=Speed |
| | | 480=Environmental sensor |
| | | 481=Can start using environmental sensor |
| | | |
| | | |
| | | |
| | |
| | | 1050=Add Device |
| | | 1051=Mini Intelligent Remote Control |
| | | 1052=Add Infrared Remote Control |
| | | 1053=Press the infrared remote control button{0}for 10 seconds and the indicator light{0}flashes blue quickly |
| | | 1053=Press the infrared remote control button{0}for 3 seconds and the indicator light{0}flashes blue quickly |
| | | 1054=Please make sure your Bluetooth{0}is on and searchable |
| | | 1055=Next Step |
| | | 1056=Device searching... |
| | |
| | | 324=场景延时 |
| | | 325=延时设置 |
| | | 326=延时 |
| | | 327=捕获场景 |
| | | 327=捕捉场景 |
| | | 328=电影场景 |
| | | 329=普通 |
| | | 330=自动模式 |
| | |
| | | 477=摆动 |
| | | 478=模式 |
| | | 479=风速 |
| | | 480=环境传感器 |
| | | 481=可以开始使用环境传感器了 |
| | | |
| | | |
| | | 1000=室内湿度 |
| | |
| | | 1050=添加设备 |
| | | 1051=mini智能遥控器 |
| | | 1052=添加红外遥控 |
| | | 1053=长按红外遥控器按钮10秒,指示灯蓝色快闪 |
| | | 1053=长按红外遥控器按钮3秒,指示灯蓝色快闪 |
| | | 1054=请确保您的蓝牙已开启并处于可以被搜索状态 |
| | | 1055=下一步 |
| | | 1056=设备搜索中... |
| | |
| | | 6016=离线 |
| | | 6017=版本号 |
| | | 6018=请输入遥控器名称 |
| | | 6019=提示:遥控器创建后可在功能-电器分类{\r\n}查找使用 |
| | | 6019=提示:遥控器创建后可在功能-电器分类,查找使用 |
| | | 6020=推荐按键 |
| | | 6021=请输入按键名称 |
| | | 6022=下一步 |
| | |
| | | 6093=设备不在线 |
| | | 6094=网关设备不存在 |
| | | 6095=添加按钮超出30个 |
| | | |
| | | |
| | | |
| | | 7000=新建自动化 |
| | |
| | | 7142=严重 |
| | | 7143=偏高 |
| | | 7144=优秀 |
| | | |
| | | |
| | | 9000=请使用新的手机账号登录APP |
| | | 9001=请使用新的邮箱账号登录APP |
| | |
| | | <Reference Include="videophone"> |
| | | <HintPath>..\DLL\FL\Android\videophone.dll</HintPath> |
| | | </Reference> |
| | | <Reference Include="LC_SDK"> |
| | | <HintPath>..\DLL\LC\Android\LC_SDK.dll</HintPath> |
| | | </Reference> |
| | | <Reference Include="Square.OkHttp3"> |
| | | <HintPath>..\DLL\EZvizMonitor\Square.OkHttp3.dll</HintPath> |
| | | </Reference> |
| | |
| | | </Reference> |
| | | <Reference Include="ys"> |
| | | <HintPath>..\DLL\EZvizMonitor\ys.dll</HintPath> |
| | | </Reference> |
| | | <Reference Include="LC_SDK"> |
| | | <HintPath>..\DLL\LC\Android\LC_SDK.dll</HintPath> |
| | | </Reference> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\Icon\HomeIcon\irfan_blue.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\Icon\HomeIcon\irfan_white.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\Icon\irfan.png" /> |
| | | <AndroidAsset Include="Assets\Phone\PersonalCenter\AddDevice\EnvironmentalSensorbg.png" /> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\Icon\sensorenvironment.png" /> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | | <AndroidAsset Include="Assets\Phone\FunctionIcon\DoorLock\BindScene.png" /> |
| | |
| | | <?xml version="1.0" encoding="utf-8"?> |
| | | <manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="202107151" android:versionName="1.2.202107151" package="com.hdl.onpro"> |
| | | <manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="202107211" android:versionName="1.2.202107211" package="com.hdl.onpro"> |
| | | <uses-sdk android:minSdkVersion="23" android:targetSdkVersion="29" /> |
| | | <!-- 乐橙可视对讲需要的权限 --> |
| | | <!--<uses-permission android:name="android.permission.INTERNET" />--> |
| | |
| | | <MtouchExtraArgs>-gcc_flags="-dead_strip -ObjC"</MtouchExtraArgs> |
| | | <MtouchEnableSGenConc>false</MtouchEnableSGenConc> |
| | | <CodesignProvision>On+Dev-20210616-1</CodesignProvision> |
| | | <CodesignEntitlements>Entitlements.plist</CodesignEntitlements> |
| | | </PropertyGroup> |
| | | <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhone' "> |
| | | <DebugType>none</DebugType> |
| | |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | | <PackageReference Include="Newtonsoft.Json"> |
| | | <Version>12.0.3</Version> |
| | | <Version>13.0.1</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="MQTTnet"> |
| | | <Version>3.0.13</Version> |
| | | <Version>3.0.16</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="Microsoft.AppCenter.Analytics"> |
| | | <Version>4.1.0</Version> |
| | | <Version>4.3.0</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="Microsoft.AppCenter.Crashes"> |
| | | <Version>4.1.0</Version> |
| | | <Version>4.3.0</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="ZXing.Net.Mobile"> |
| | | <Version>2.4.1</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="RestSharp"> |
| | | <Version>106.11.7</Version> |
| | | <Version>106.12.0</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="Xamarin.iOS.Bugly"> |
| | | <Version>1.0.4</Version> |
| | | </PackageReference> |
| | | <PackageReference Include="Xamarin.Essentials"> |
| | | <Version>1.6.0</Version> |
| | | <Version>1.7.0</Version> |
| | | </PackageReference> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\Icon\irfan.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\Icon\HomeIcon\irfan_blue.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\Icon\HomeIcon\irfan_white.png" /> |
| | | <BundleResource Include="Resources\Phone\FunctionIcon\Icon\sensorenvironment.png" /> |
| | | <BundleResource Include="Resources\Phone\PersonalCenter\AddDevice\EnvironmentalSensorbg.png" /> |
| | | </ItemGroup> |
| | | <ItemGroup> |
| | | <ITunesArtwork Include="iTunesArtwork" /> |
| | |
| | | <key>UIStatusBarStyle</key> |
| | | <string>UIStatusBarStyleLightContent</string> |
| | | <key>CFBundleShortVersionString</key> |
| | | <string>1.2.202107151</string> |
| | | <string>1.2.202107211</string> |
| | | <key>CFBundleVersion</key> |
| | | <string>1.2.07151</string> |
| | | <string>1.2.07211</string> |
| | | <key>NSLocationWhenInUseUsageDescription</key> |
| | | <string>Use geographic location to provide services such as weather</string> |
| | | <key>NSAppleMusicUsageDescription</key> |
| | |
| | | <document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="17506" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" colorMatched="YES" initialViewController="1Qq-y9-5Vr"> |
| | | <device id="retina4_7" orientation="portrait" appearance="light"/> |
| | | <dependencies> |
| | | <deployment identifier="iOS"/> |
| | | <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17505"/> |
| | | <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/> |
| | | </dependencies> |
| | |
| | | <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" usesAttributedText="YES" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Q0X-wy-A5B"> |
| | | <rect key="frame" x="47.5" y="362" width="311.5" height="40"/> |
| | | <attributedString key="attributedText"> |
| | | <fragment content="返回demo,等待与设备连接,成功后自动进入下一步操作。"> |
| | | <fragment content="返回"> |
| | | <attributes> |
| | | <font key="NSFont" size="14" name=".PingFangSC-Regular"/> |
| | | <paragraphStyle key="NSParagraphStyle" alignment="left" lineBreakMode="wordWrapping" baseWritingDirection="natural" minimumLineHeight="20" tighteningFactorForTruncation="0.0"/> |
| | | </attributes> |
| | | </fragment> |
| | | <fragment content="APP"> |
| | | <attributes> |
| | | <font key="NSFont" metaFont="system" size="14"/> |
| | | <paragraphStyle key="NSParagraphStyle" alignment="left" lineBreakMode="wordWrapping" baseWritingDirection="natural" minimumLineHeight="20" tighteningFactorForTruncation="0.0"/> |
| | | </attributes> |
| | | </fragment> |
| | | <fragment content=",等待与设备连接,成功后自动进入下一步操作。"> |
| | | <attributes> |
| | | <font key="NSFont" size="14" name=".PingFangSC-Regular"/> |
| | | <paragraphStyle key="NSParagraphStyle" alignment="left" lineBreakMode="wordWrapping" baseWritingDirection="natural" minimumLineHeight="20" tighteningFactorForTruncation="0.0"/> |
| | | </attributes> |
| | | </fragment> |
| | |
| | | </scenes> |
| | | <inferredMetricsTieBreakers> |
| | | <segue reference="9TP-S2-hhI"/> |
| | | <segue reference="MFl-yy-ZsP"/> |
| | | <segue reference="9Lc-Kx-oZS"/> |
| | | <segue reference="ikM-Zn-H8f"/> |
| | | </inferredMetricsTieBreakers> |
| | | <resources> |
| | |
| | | 477=Swing |
| | | 478=Pattern |
| | | 479=Speed |
| | | 480=Environmental sensor |
| | | 481=Can start using environmental sensor |
| | | |
| | | |
| | | |
| | |
| | | 1050=Add Device |
| | | 1051=Mini Intelligent Remote Control |
| | | 1052=Add Infrared Remote Control |
| | | 1053=Press the infrared remote control button{0}for 10 seconds and the indicator light{0}flashes blue quickly |
| | | 1053=Press the infrared remote control button{0}for 3 seconds and the indicator light{0}flashes blue quickly |
| | | 1054=Please make sure your Bluetooth{0}is on and searchable |
| | | 1055=Next Step |
| | | 1056=Device searching... |
| | |
| | | 477=摆动 |
| | | 478=模式 |
| | | 479=风速 |
| | | 480=环境传感器 |
| | | 481=可以开始使用环境传感器了 |
| | | |
| | | |
| | | 1000=室内湿度 |
| | |
| | | 1050=添加设备 |
| | | 1051=mini智能遥控器 |
| | | 1052=添加红外遥控 |
| | | 1053=长按红外遥控器按钮10秒,指示灯蓝色快闪 |
| | | 1053=长按红外遥控器按钮3秒,指示灯蓝色快闪 |
| | | 1054=请确保您的蓝牙已开启并处于可以被搜索状态 |
| | | 1055=下一步 |
| | | 1056=设备搜索中... |
| | |
| | | |
| | | foreach (var video in FunctionList.List.videoIntercom) |
| | | { |
| | | if (video.interphoneType == "IMOUVISIAL") |
| | | if (video.interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | UI.UI2.PersonalCenter.PirDevice.PirSend.LcSubAccessToken = video.subAccountToken; |
| | | } |
| | |
| | | if (jpushMessageInfo.messageType.Contains(PushMessageType.Alarm.ToString())) |
| | | { |
| | | //报警推送弹窗提示 |
| | | ShowAlarmPushMessage(jpushMessageInfo,true); |
| | | ShowAlarmPushMessage(jpushMessageInfo, true); |
| | | } |
| | | else if (jpushMessageInfo.messageType.Contains(PushMessageType.FLCall.ToString())) |
| | | { |
| | |
| | | eSVideoInfo.ESVideoUUID = eSVideoInfo.uuid; |
| | | } |
| | | |
| | | ESOnVideo.Current.ShowESvideoVideoIntercom(eSVideoInfo, "FLVI"); |
| | | ESOnVideo.Current.ShowESvideoVideoIntercom(eSVideoInfo, InterphoneType.FLVI.ToString()); |
| | | |
| | | } |
| | | else if (jpushMessageInfo.messageType.Contains(PushMessageType.HDL_INTERPHONE.ToString())) |
| | |
| | | if (string.IsNullOrEmpty(jpushMessageInfo.expantContent)) return; |
| | | |
| | | //字段兼容问题,只能直接取值了 |
| | | var json= Newtonsoft.Json.Linq.JObject.Parse(jpushMessageInfo.expantContent); |
| | | var json = Newtonsoft.Json.Linq.JObject.Parse(jpushMessageInfo.expantContent); |
| | | //1.视对讲厂家类型 |
| | | string interphoneTypeEnum = json["interphoneTypeEnum"].ToString(); |
| | | if (string.IsNullOrEmpty(interphoneTypeEnum)) return; |
| | | // |
| | | ESVideoInfo eSVideoInfo = new ESVideoInfo();// GetESOnVideoJson(jpushMessageInfo.expantContent); |
| | | eSVideoInfo.callId = json["callId"].ToString(); |
| | | //eSVideoInfo.Lc_AccessToken = UI.UI2.PersonalCenter.PirDevice.PirSend.LcSubAccessToken;//json["subAccountToken"].ToString();// |
| | | eSVideoInfo.Lc_AccessToken = json["subAccountToken"].ToString();//2021-05-13 目前云端还没拿到Lc_AccessToken,目前没办法正常使用 |
| | | eSVideoInfo.Lc_DeviceId = json["deviceId"].ToString(); |
| | | eSVideoInfo.Lc_Location = OnAppConfig.Instance.RequestHttpsHost.Contains("China") ? 0 : 1; |
| | | eSVideoInfo.Lc_PlayToken = json["token"].ToString(); |
| | | eSVideoInfo.Lc_Psk = json["cname"].ToString(); |
| | | //2.根据可视对讲厂家类型,处理不同的数据 |
| | | if (interphoneTypeEnum == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | //大华乐橙 |
| | | eSVideoInfo.callId = json["callId"].ToString(); |
| | | //eSVideoInfo.Lc_AccessToken = UI.UI2.PersonalCenter.PirDevice.PirSend.LcSubAccessToken;//json["subAccountToken"].ToString();// |
| | | eSVideoInfo.Lc_AccessToken = json["subAccountToken"].ToString();//2021-05-13 目前云端还没拿到Lc_AccessToken,目前没办法正常使用 |
| | | eSVideoInfo.Lc_DeviceId = json["deviceId"].ToString(); |
| | | eSVideoInfo.Lc_Location = OnAppConfig.Instance.RequestHttpsHost.Contains("China") ? 0 : 1; |
| | | eSVideoInfo.Lc_PlayToken = json["token"].ToString(); |
| | | eSVideoInfo.Lc_Psk = json["cname"].ToString(); |
| | | } |
| | | else if (interphoneTypeEnum == InterphoneType.EZVIZ.ToString()) |
| | | { |
| | | //萤石猫眼 |
| | | eSVideoInfo.Lc_AccessToken = json["subToken"].ToString();//"子账号token |
| | | eSVideoInfo.DeviceSerial = json["devSerial"].ToString();//设备序列号 |
| | | eSVideoInfo.HomeId = jpushMessageInfo.HomeId; |
| | | } |
| | | |
| | | //3.打开呼叫页面 |
| | | if (eSVideoInfo == null) return; |
| | | |
| | | ESOnVideo.Current.ShowESvideoVideoIntercom(eSVideoInfo, "IMOUVISIAL"); |
| | | ESOnVideo.Current.ShowESvideoVideoIntercom(eSVideoInfo, interphoneTypeEnum); |
| | | |
| | | } |
| | | else if(jpushMessageInfo.messageType.Contains(PushMessageType.Prompt.ToString())) |
| | | else if (jpushMessageInfo.messageType.Contains(PushMessageType.Prompt.ToString())) |
| | | { |
| | | ShowAlarmPushMessage(jpushMessageInfo, false); |
| | | } |
| | | } |
| | | } |
| | | catch(Exception EX) |
| | | catch (Exception EX) |
| | | { |
| | | Utlis.WriteLine("catch: " + EX.ToString()); |
| | | } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 解析丰林可视对讲推送数据 |
| | | /// </summary> |
| | | /// <param name="jsonStr"></param> |
| | | /// <returns></returns> |
| | | ESVideoInfo GetESOnVideoJson(string jsonStr) |
| | | //{"code":0,"data":{"list":[{"createTime":"1625798305115","modifyTime":"1625798305115","region":"100000000000000001","id":"1413326644794294273","alarmId":"20210709103818-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709103818-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T10:38:17","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{"createTime":"1625798057197","modifyTime":"1625798057197","region":"100000000000000001","id":"1413325604946640898","alarmId":"20210709103413-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709103413-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T10:34:12","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{ "createTime":"1625797973320","modifyTime":"1625797973320","region":"100000000000000001","id":"1413325253141004289","alarmId":"20210709103236-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709103236-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T10:32:31","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{ "createTime":"1625797782136","modifyTime":"1625797782136","region":"100000000000000001","id":"1413324451261382658","alarmId":"20210709102937-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709102937-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T10:29:37","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{ "createTime":"1625797668771","modifyTime":"1625797668771","region":"100000000000000001","id":"1413323975769915394","alarmId":"20210709102743-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709102743-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T10:27:42","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{ "createTime":"1625797539846","modifyTime":"1625797539846","region":"100000000000000001","id":"1413323435023466498","alarmId":"20210709102534-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709102534-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T10:25:34","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{ "createTime":"1625797530627","modifyTime":"1625797530627","region":"100000000000000001","id":"1413323396351983618","alarmId":"20210709102525-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709102525-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T10:25:25","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{ "createTime":"1625796028089","modifyTime":"1625796028089","region":"100000000000000001","id":"1413317094255034369","alarmId":"20210709100024-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709100024-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T10:00:23","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{ "createTime":"1625795974558","modifyTime":"1625795974558","region":"100000000000000001","id":"1413316869729746946","alarmId":"20210709095931-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709095931-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T09:59:31","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"},{ "createTime":"1625795966933","modifyTime":"1625795966933","region":"100000000000000001","id":"1413316837748178946","alarmId":"20210709095923-F41014762-1-10000","channelNo":1,"deviceSerial":"F41014762","alarmName":"人体感应事件","alarmPicUrl":"https://i.ys7.com/streamer/alarm/url/get?fileId=20210709095923-F41014762-1-10000-2-1&deviceSerialNo=F41014762&cn=1&isEncrypted=0&isCloudStored=0&ct=1&lc=7&bn=1_hikalarm&isDevVideo=0","alarmTime":"2021-07-09T09:59:22","homeId":"1396717478877241345","alarmType":"pir","isChecked":0,"isEncrypt":0,"deleted":0,"tenantId":"20"}],"totalCount":"13","totalPage":"2","pageNo":"1","pageSize":"10"},"timestamp":"1625807415164","isSuccess":true} |
| | | //{"platform":"1","timestamp":"1625805660249","appKey":"HDL-HOME-APP-TEST","sign":"02e433c40485b30451ebdc5ca3cd959c","deviceSerial":"F41014762","homeId":"1396717478877241345"} |
| | | /// <summary> |
| | | /// 解析丰林可视对讲推送数据 |
| | | /// </summary> |
| | | /// <param name="jsonStr"></param> |
| | | /// <returns></returns> |
| | | ESVideoInfo GetESOnVideoJson(string jsonStr) |
| | | { |
| | | try |
| | | { |
| | |
| | | /// </summary> |
| | | /// <param name="jpushMessageInfo"></param> |
| | | /// <param name="isAlarm">是否是报警信息,(加载的弹窗颜色不一样)</param> |
| | | public void ShowAlarmPushMessage(JPushMessageInfo jpushMessageInfo,bool isAlarm) |
| | | public void ShowAlarmPushMessage(JPushMessageInfo jpushMessageInfo, bool isAlarm) |
| | | { |
| | | //没登录不处理 |
| | | if (UserInfo.Current == null || !UserInfo.Current.IsLogin || MainPage.BasePageView == null) |
| | |
| | | var result = new HttpServerRequest().EZGetChildToken(); |
| | | if (result.Code == StateCode.SUCCESS) |
| | | { |
| | | var ezChildAccessToken = Newtonsoft.Json.JsonConvert.DeserializeObject<EZChildAccessToken>(result.Data.ToString()); |
| | | var ezChildAccessToken = result.Data.ToString(); |
| | | |
| | | //var ezChildAccessToken = Newtonsoft.Json.JsonConvert.DeserializeObject<EZChildAccessToken>(result.Data.ToString()); |
| | | Application.RunOnMainThread(() => |
| | | { |
| | | if (!string.IsNullOrEmpty(ezChildAccessToken.accessToken)) |
| | | if (!string.IsNullOrEmpty(ezChildAccessToken)) |
| | | { |
| | | #if __IOS__ |
| | | //iOS |
| | | //初始化萤石云SDK,中文国内key、英文海外key 开发者账号使用应用包名申请的APPKEY,不同包名应用需配置不同的APPKEY |
| | | EZSDK.IOS.EZSDK.InitLibWithAppKey("1aa98a90489b4838b966b57018b4b04b", "1aa98a90489b4838b966b57018b4b04b"); |
| | | EZSDK.IOS.EZSDK.SharedInstance().InitLibWithAppKey("1aa98a90489b4838b966b57018b4b04b", "1aa98a90489b4838b966b57018b4b04b"); |
| | | //1.设置所需河东的AccessToken和RefreshToken、域名地址 |
| | | EZSDK.IOS.EZSDK.SetHDlAccessToken(UserInfo.Current.LoginTokenString, UserInfo.Current.RefreshToken); |
| | | EZSDK.IOS.EZSDK.SetRequestHttpsHost(OnAppConfig.Instance.RequestHttpsHost); |
| | | 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); |
| | | //2.设置萤石子账号的AccessToken到SDK |
| | | EZSDK.IOS.EZSDK.SetEZAccessToken(ezChildAccessToken.accessToken); |
| | | //3.打开摄像头设备列表页面 |
| | | EZSDK.IOS.EZSDK.Go2EZvizMonitor(); |
| | | EZSDK.IOS.EZSDK.SharedInstance().SetEZAccessToken(ezChildAccessToken); |
| | | ////3.打开摄像头设备列表页面 |
| | | EZSDK.IOS.EZSDK.SharedInstance().Go2EZvizMonitor(); |
| | | |
| | | //EZSDK.IOS.EZDeviceInfo info = new EZSDK.IOS.EZDeviceInfo(); |
| | | //info.de |
| | | //EZSDK.IOS.EZSDK.Play(info); |
| | | #else |
| | | //Android |
| | | //1.设置所需河东的token、域名地址 |
| | |
| | | { |
| | | if (b) |
| | | { |
| | | Android.Content.Intent intent = new Android.Content.Intent(); |
| | | var bundle = new Android.OS.Bundle(); |
| | | //传递name参数为tinyphp |
| | | bundle.PutString("Token", ezChildAccessToken.accessToken); |
| | | bundle.PutString("HdlToken", UserInfo.Current.LoginTokenString); |
| | | bundle.PutString("Url", OnAppConfig.Instance.RequestHttpsHost); |
| | | intent.PutExtras(bundle); |
| | | intent.SetComponent(new Android.Content.ComponentName(Shared.Application.Activity, "com.videogo.MainActivity")); |
| | | Shared.Application.Activity.StartActivity(intent); |
| | | ((BaseActivity)Shared.Application.Activity).SetPermission(result => |
| | | { |
| | | if(result) |
| | | { |
| | | Android.Content.Intent intent = new Android.Content.Intent(); |
| | | var bundle = new Android.OS.Bundle(); |
| | | //传递name参数为tinyphp |
| | | bundle.PutString("EzChildAccessToken", ezChildAccessToken); |
| | | bundle.PutString("HdlToken", UserInfo.Current.LoginTokenString); |
| | | bundle.PutString("Url", OnAppConfig.Instance.RequestHttpsHost); |
| | | bundle.PutString("EzvizAppKey", "1aa98a90489b4838b966b57018b4b04b"); |
| | | bundle.PutInt("Platform", 1); |
| | | bundle.PutString("HomeId", DB_ResidenceData.Instance.CurrentRegion.id); |
| | | intent.PutExtras(bundle); |
| | | intent.SetComponent(new Android.Content.ComponentName(Shared.Application.Activity, "com.videogo.MainActivity")); |
| | | Shared.Application.Activity.StartActivity(intent); |
| | | } |
| | | }, "android.permission.RECORD_AUDIO"); |
| | | |
| | | } |
| | | }); |
| | | #endif |
| | |
| | | public static class StringId |
| | | { |
| | | /// <summary> |
| | | /// 可以开始使用环境传感器了 |
| | | /// </summary> |
| | | public const int CanStartUsingEnvironmentalSensor = 481; |
| | | /// <summary> |
| | | /// 环境传感器 |
| | | /// </summary> |
| | | public const int SensorEnvironment = 480; |
| | | /// <summary> |
| | | /// 风量 |
| | | /// </summary> |
| | | public const int AirVolume = 479; |
| | |
| | | #region ■ 萤石云SDK相关接口_________________________ |
| | | /// <summary> |
| | | /// 河东获取萤石云子账号token的接口 |
| | | /// 2021-07-07 新方案接口调整对接 |
| | | /// </summary> |
| | | public ResponsePackNew EZGetChildToken() |
| | | { |
| | | Dictionary<string, object> d = new Dictionary<string, object>(); |
| | | d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id); |
| | | d.Add("platform", "1"); |
| | | var requestJson = HttpUtil.GetSignRequestJson(d); |
| | | return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_EZ_GetChildToken, requestJson); |
| | | } |
| | |
| | | /// 公共域名就近解析 |
| | | /// |
| | | /// </summary> |
| | | //public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com"; |
| | | public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";//mmmm |
| | | public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com"; |
| | | //public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";//mmmm |
| | | /// <summary> |
| | | /// RegionMark |
| | | /// </summary> |
| | |
| | | /// <summary> |
| | | /// 河东获取萤石云子账号token的接口 |
| | | /// </summary> |
| | | public const string API_POST_EZ_GetChildToken = "/home-wisdom/platform/childToken"; |
| | | public const string API_POST_EZ_GetChildToken = "/home-wisdom/platform/yingshi/child/token"; |
| | | |
| | | |
| | | #endregion |
| | |
| | | using System.Threading; |
| | | using System.Collections.Generic; |
| | | using HDL_ON.UI.UI2.PersonalCenter.PirDevice; |
| | | using HDL_ON.Entity; |
| | | |
| | | #if __IOS__ |
| | | using Shared.IOS.ESVideoOnSDK; |
| | |
| | | int.TryParse(mESVideoInfo.roomno, out roomID); |
| | | |
| | | #if __IOS__ |
| | | if (interphoneType == "IMOUVISIAL") |
| | | if (interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | //乐橙可视对讲 |
| | | //1.初始化LCOpenSDK_Api |
| | |
| | | } |
| | | #else |
| | | Intent intent = null; |
| | | if (interphoneType == "IMOUVISIAL") |
| | | if (interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | intent = new Intent(Shared.Application.Activity, typeof(HDL_ON_Android.LeChengVideoActivity)); |
| | | } |
| | |
| | | int roomID = 0; |
| | | int.TryParse(mESVideoInfo.roomno, out roomID); |
| | | #if __IOS__ |
| | | if (interphoneType == "IMOUVISIAL") |
| | | if (interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | //乐橙可视对讲 |
| | | //1.初始化LCOpenSDK_Api |
| | |
| | | vc.MLCCallDelegate = mOnLCCallDelegate; |
| | | //vc.MLCCallDelegate = new OnLCCallDelegate(this); |
| | | Shared.Application.currentVC.NavigationController.PushViewController(vc, true); |
| | | } |
| | | else if (interphoneType == InterphoneType.EZVIZ.ToString()) |
| | | { |
| | | //萤石猫眼呼叫 |
| | | //初始化萤石云SDK,中文国内key、英文海外key 开发者账号使用应用包名申请的APPKEY,不同包名应用需配置不同的APPKEY |
| | | EZSDK.IOS.EZSDK.SharedInstance().InitLibWithAppKey("1aa98a90489b4838b966b57018b4b04b", "1aa98a90489b4838b966b57018b4b04b"); |
| | | //1.设置所需河东的AccessToken和RefreshToken、域名地址 |
| | | EZSDK.IOS.EZSDK.SharedInstance().SetHDlAccessToken(UserInfo.Current.LoginTokenString, UserInfo.Current.RefreshToken); |
| | | |
| | | EZSDK.IOS.EZSDK.SharedInstance().SetRequestHttpsHostAndPlatform(OnAppConfig.Instance.RequestHttpsHost, 1, mESVideoInfo.HomeId); |
| | | //2.设置萤石子账号的AccessToken到SDK |
| | | EZSDK.IOS.EZSDK.SharedInstance().SetEZAccessToken(mESVideoInfo.Lc_AccessToken); |
| | | //3.打开视频播放页面 |
| | | EZSDK.IOS.EZSDK.SharedInstance().PlayWithDeviceSerial(mESVideoInfo.DeviceSerial); |
| | | |
| | | } |
| | | else |
| | | { |
| | |
| | | #region |
| | | |
| | | Intent intent = null; |
| | | if (interphoneType == "IMOUVISIAL") |
| | | if (interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | intent = new Intent(Shared.Application.Activity, typeof(HDL_ON_Android.LeChengVideoActivity)); |
| | | } |
| | | else if (interphoneType == InterphoneType.EZVIZ.ToString()) |
| | | { |
| | | ((BaseActivity)Shared.Application.Activity).SetCamera(b => |
| | | { |
| | | if (b) |
| | | { |
| | | intent = new Android.Content.Intent(); |
| | | var bundle = new Android.OS.Bundle(); |
| | | //传递name参数为tinyphp |
| | | bundle.PutString("EzChildAccessToken", mESVideoInfo.Lc_AccessToken); |
| | | bundle.PutString("HdlToken", UserInfo.Current.LoginTokenString); |
| | | bundle.PutString("Url", OnAppConfig.Instance.RequestHttpsHost); |
| | | bundle.PutString("EzvizAppKey", "1aa98a90489b4838b966b57018b4b04b"); |
| | | bundle.PutInt("Platform", 1); |
| | | bundle.PutString("HomeId", mESVideoInfo.HomeId); |
| | | bundle.PutString("DeviceSerial", mESVideoInfo.DeviceSerial); |
| | | intent.PutExtras(bundle); |
| | | intent.SetComponent(new Android.Content.ComponentName(Shared.Application.Activity, "com.videogo.MainActivity")); |
| | | Shared.Application.Activity.StartActivity(intent); |
| | | } |
| | | }); |
| | | return; |
| | | } |
| | | else |
| | | { |
| | |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | |
| | | #endif |
| | | |
| | | /// <summary> |
| | | /// 测试方法 |
| | | /// </summary> |
| | | /// <param name="isMonitor"></param> |
| | | public void Test(bool isMonitor = true) |
| | | { |
| | | ESVideoInfo eSVideoInfo = new ESVideoInfo() |
| | | { |
| | | DeviceName = "室外机88", |
| | | ESVideoUUID = "JJY000019VPLLF", |
| | | ///// <summary> |
| | | ///// 测试方法 |
| | | ///// </summary> |
| | | ///// <param name="isMonitor"></param> |
| | | //public void Test(bool isMonitor = true) |
| | | //{ |
| | | // ESVideoInfo eSVideoInfo = new ESVideoInfo() |
| | | // { |
| | | // DeviceName = "室外机88", |
| | | // ESVideoUUID = "JJY000019VPLLF", |
| | | |
| | | }; |
| | | if (isMonitor) |
| | | { |
| | | ShowESVideoMonitor(eSVideoInfo, ""); |
| | | } |
| | | else |
| | | { |
| | | eSVideoInfo.callId = "88888"; |
| | | ShowESvideoVideoIntercom(eSVideoInfo, ""); |
| | | } |
| | | // }; |
| | | // if (isMonitor) |
| | | // { |
| | | // ShowESVideoMonitor(eSVideoInfo, ""); |
| | | // } |
| | | // else |
| | | // { |
| | | // eSVideoInfo.callId = "88888"; |
| | | // ShowESvideoVideoIntercom(eSVideoInfo, ""); |
| | | // } |
| | | |
| | | } |
| | | //} |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | |
| | | |
| | | //========================大华========================== |
| | | |
| | | /// <summary> |
| | | /// 账号accessToken |
| | | /// 萤石子账号Token也共用这个字段 |
| | | /// </summary> |
| | | public string Lc_AccessToken = string.Empty; |
| | | |
| | |
| | | /// 账号标记:0国内,1国外;国内国外访问都地址不一样 |
| | | /// </summary> |
| | | public int Lc_Location = 0; |
| | | |
| | | //========================萤石云猫眼========================== |
| | | /// <summary> |
| | | /// 住宅Id |
| | | /// </summary> |
| | | public string HomeId = string.Empty; |
| | | /// <summary> |
| | | /// 设备序列号 |
| | | /// </summary> |
| | | public string DeviceSerial = string.Empty; |
| | | |
| | | |
| | | } |
| | | |
| | |
| | | /// 大华可视对讲平台 |
| | | /// </summary> |
| | | IMOUVISIAL, |
| | | /// <summary> |
| | | /// 萤石猫眼呼叫 |
| | | /// </summary> |
| | | EZVIZ, |
| | | |
| | | |
| | | } |
| | | } |
| | |
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\PirDevice\View\FrameLayout50.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\PirDevice\View\SaveView.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\PirDevice\View\Buttons.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\AddDevice\SenesorEnvironment\SensorEnvironmentManagerPage.cs" />
|
| | | <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\AddDevice\SenesorEnvironment\AddSensorEnvironmentPage.cs" />
|
| | | </ItemGroup>
|
| | | <ItemGroup>
|
| | | <Folder Include="$(MSBuildThisFileDirectory)Entity\Device\" />
|
| | |
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\SmartSpeaker\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\AddDevice\SenesorMegahealth\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\AddDevice\MiniRemoteControl\" />
|
| | | <Folder Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\AddDevice\SenesorEnvironment\" />
|
| | | </ItemGroup>
|
| | | </Project> |
| | |
| | | /// <summary> |
| | | /// 版本号 |
| | | /// </summary> |
| | | public static string VersionString = "1.2.0714"; |
| | | public static string VersionString = "1.2.0721"; |
| | | ///// <summary> |
| | | ///// 客户端类型 |
| | | ///// </summary> |
| | |
| | | public static List<string> RoomNotSupportFunctionList = new List<string> |
| | | { |
| | | SPK.EnergyStandard, |
| | | SPK.MusicStandard, |
| | | }; |
| | | |
| | | |
| | |
| | | //etAccount.Text = "13168123446"; |
| | | //etAccount.Text = "13676202754";//巴林服务器 |
| | | //etAccount.Text = "13602944661";//kx |
| | | //etAccount.Text = "551775569@qq.com";//wcf |
| | | etAccount.Text = "551775569@qq.com";//wcf |
| | | //etAccount.Text = "18666455392";//13375012446//13602944661//tzy 18778381374 |
| | | //etAccount.Text = "15971583093";//高胜 |
| | | etAccount.Text = "15217626103";//昆明金茂项目 |
| | | //etAccount.Text = "15217626103";//昆明金茂项目 |
| | | } |
| | | b = !b; |
| | | etPassword.Text = "123456"; |
| | |
| | | { |
| | | btnIndoorTempValues.Text = "/--°"; |
| | | double tempTotalValues = 0; |
| | | double tempTotalCount = 0; |
| | | foreach (var temp in tempSensorList) |
| | | { |
| | | double tempValue = 0; |
| | | double.TryParse(temp.GetAttrState(FunctionAttributeKey.Value), out tempValue); |
| | | tempTotalValues += tempValue; |
| | | if (tempValue > 0) |
| | | { |
| | | tempTotalValues += tempValue; |
| | | tempTotalCount++; |
| | | } |
| | | } |
| | | if (tempTotalValues > 0) |
| | | { |
| | | btnIndoorTempValues.Text = "/" + tempTotalValues + "°"; |
| | | btnIndoorTempValues.Text = "/" + (tempTotalValues/ tempTotalCount).ToString("0.0") + "°"; |
| | | } |
| | | } |
| | | btnIndoorTempValues.Width = btnIndoorTempValues.GetTextWidth(); |
| | |
| | | { |
| | | btnIndoorHumiValues.Text = "/--%"; |
| | | double humiTotalValues = 0; |
| | | double humiTotalCount = 0; |
| | | foreach (var humi in humiSensorList) |
| | | { |
| | | double humiValue = 0; |
| | | double.TryParse(humi.GetAttrState(FunctionAttributeKey.Value), out humiValue); |
| | | humiTotalValues += humiValue; |
| | | if (humiValue > 0) |
| | | { |
| | | humiTotalValues += humiValue; |
| | | humiTotalCount++; |
| | | } |
| | | } |
| | | if (humiTotalValues > 0) |
| | | { |
| | | btnIndoorHumiValues.Text = "/" + humiTotalValues + "%"; |
| | | btnIndoorHumiValues.Text = "/" + (humiTotalValues / humiTotalCount).ToString("0") + "%"; |
| | | } |
| | | } |
| | | btnIndoorHumiValues.Width = btnIndoorHumiValues.GetTextWidth(); |
| | |
| | | } |
| | | } |
| | | double humiTotalValues = 0; |
| | | int humiTotalCount = 0; |
| | | foreach (var temp in humiSensorList) |
| | | { |
| | | double humiValue = 0; |
| | | double.TryParse(temp.GetAttrState(FunctionAttributeKey.Value), out humiValue); |
| | | humiTotalValues += humiValue; |
| | | if(humiValue > 0) |
| | | { |
| | | humiTotalValues += humiValue; |
| | | humiTotalCount++; |
| | | } |
| | | } |
| | | if (humiTotalValues > 0) |
| | | { |
| | | bodyView.btnIndoorHumiValues.Text = "/" + humiTotalValues + "%"; |
| | | bodyView.btnIndoorHumiValues.Text = "/" + (humiTotalValues /humiTotalCount).ToString("0")+ "%"; |
| | | } |
| | | bodyView.btnIndoorHumiValues.Width = bodyView.btnIndoorHumiValues.GetTextWidth(); |
| | | } |
| | |
| | | } |
| | | } |
| | | double tempTotalValues = 0; |
| | | int tempTotalCount = 0; |
| | | foreach (var temp in tempSensorList) |
| | | { |
| | | double tempValue = 0; |
| | | double.TryParse(temp.GetAttrState(FunctionAttributeKey.Value), out tempValue); |
| | | tempTotalValues += tempValue; |
| | | if (tempValue > 0) |
| | | { |
| | | tempTotalValues += tempValue; |
| | | tempTotalCount++; |
| | | } |
| | | } |
| | | if (tempTotalValues > 0) |
| | | { |
| | | bodyView.btnIndoorTempValues.Text = "/" + tempTotalValues + "°"; |
| | | bodyView.btnIndoorTempValues.Text = "/" + (tempTotalValues /tempTotalCount).ToString("0.0")+ "°"; |
| | | } |
| | | bodyView.btnIndoorTempValues.Width = bodyView.btnIndoorTempValues.GetTextWidth(); |
| | | } |
| | |
| | | break; |
| | | case ShowFunction.Music: |
| | | functionCount = FunctionList.List.GetMusicList().Count; |
| | | #if DEBUG |
| | | functionCount = 1; |
| | | #endif |
| | | break; |
| | | case ShowFunction.Panel: |
| | | break; |
| | |
| | | bodyView.AddChidren(btnOnTitle); |
| | | |
| | | #if DEBUG |
| | | btnOnIcon.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | ESOnVideo.Current.Test(); |
| | | }; |
| | | //btnOnIcon.MouseUpEventHandler += (sender, e) => |
| | | //{ |
| | | // ESOnVideo.Current.Test(); |
| | | //}; |
| | | |
| | | btnOnTitle.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | ESOnVideo.Current.Test(false); |
| | | }; |
| | | //btnOnTitle.MouseUpEventHandler += (sender, e) => |
| | | //{ |
| | | // ESOnVideo.Current.Test(false); |
| | | //}; |
| | | |
| | | #endif |
| | | |
New file |
| | |
| | | using HDL_ON.DAL.Server; |
| | | using HDL_ON.Entity; |
| | | using HDL_ON.Stan; |
| | | using Shared; |
| | | using System; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | | /// <summary> |
| | | /// 添加毫米波步骤1界面 |
| | | /// </summary> |
| | | public class AddSensorEnvironmentPage : EditorCommonForm |
| | | { |
| | | #region ■ 变量声明___________________________ |
| | | |
| | | /// <summary> |
| | | /// 添加设备完成之后的回调事件 |
| | | /// </summary> |
| | | public Action<Function> AddDeviceEvent = null; |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 初始化_____________________________ |
| | | /// <summary> |
| | | /// 画面显示(底层会固定调用此方法,借以完成画面创建) |
| | | /// </summary> |
| | | public void ShowForm(IntegratedBrandDevice device) |
| | | { |
| | | if (Language.CurrentLanguage == "Chinese") |
| | | { |
| | | //设置头部信息 |
| | | base.SetTitleText(Language.StringByID(StringId.Add) + device.productName); |
| | | } |
| | | else |
| | | { |
| | | base.SetTitleText(Language.StringByID(StringId.Add) + " " + device.productName); |
| | | } |
| | | //这个界面的背景需要白色 |
| | | bodyFrameLayout.BackgroundColor = UI.CSS.CSS_Color.MainBackgroundColor; |
| | | |
| | | //初始化中部信息 |
| | | this.InitMiddleFrame(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 初始化中部信息 |
| | | /// </summary> |
| | | private void InitMiddleFrame() |
| | | { |
| | | //图片 |
| | | var btnPic = new PicViewControl(132, 132); |
| | | btnPic.Y = Application.GetRealHeight(69); |
| | | btnPic.Gravity = Gravity.CenterHorizontal; |
| | | btnPic.UnSelectedImagePath = "PersonalCenter/AddDevice/EnvironmentalSensorbg.png"; |
| | | bodyFrameLayout.AddChidren(btnPic); |
| | | |
| | | //请输入设备机上的sn码 |
| | | var textView = new FrameLayout() |
| | | { |
| | | Y = Application.GetRealHeight(309 - 64), |
| | | Gravity = Gravity.CenterHorizontal, |
| | | Width = Application.GetRealWidth(319), |
| | | Height = Application.GetRealHeight(44), |
| | | }; |
| | | bodyFrameLayout.AddChidren(textView); |
| | | textView.AddChidren(new Button() { Y = Application.GetRealHeight(43), Height = 1, BackgroundColor = CSS.CSS_Color.DividingLineColor }); |
| | | |
| | | EditText editText = new EditText() |
| | | { |
| | | TextAlignment = TextAlignment.Center, |
| | | TextColor = CSS.CSS_Color.FirstLevelTitleColor, |
| | | PlaceholderText = Language.StringByID(StringId.PlsEntrySNCode), |
| | | PlaceholderTextColor = CSS.CSS_Color.PromptingColor1, |
| | | TextSize = CSS.CSS_FontSize.TextFontSize, |
| | | }; |
| | | textView.AddChidren(editText); |
| | | |
| | | Button btnScan = new Button() |
| | | { |
| | | Width = Application.GetRealWidth(32), |
| | | Height = Application.GetRealWidth(32), |
| | | Gravity = Gravity.CenterVertical, |
| | | X = Application.GetRealWidth(275), |
| | | UnSelectedImagePath = "Public/Scan.png" |
| | | }; |
| | | textView.AddChidren(btnScan); |
| | | btnScan.MouseUpEventHandler = (sender, e) => |
| | | { |
| | | Scan.OpenScan((scanString) => |
| | | { |
| | | editText.Text = scanString; |
| | | }); |
| | | }; |
| | | |
| | | |
| | | |
| | | |
| | | //下一步 |
| | | var btnNext = this.AddBottomClickButton(Language.StringByID(StringId.Next)); |
| | | btnNext.ButtonClickEvent += (sender, e) => |
| | | { |
| | | var snCode = editText.Text.Trim(); |
| | | if (string.IsNullOrEmpty(snCode)) |
| | | { |
| | | editText.PlaceholderTextColor = CSS.CSS_Color.WarningColor; |
| | | } |
| | | else |
| | | { |
| | | |
| | | var waitPage = new Loading(); |
| | | waitPage.Start(); |
| | | new System.Threading.Thread(() => { |
| | | try |
| | | { |
| | | var pm = new HttpServerRequest(); |
| | | var pack = pm.IndependentRegister3TyDevcie(SPK.SensorEnvironment, snCode, Language.StringByID(StringId.SensorEnvironment)); |
| | | if (pack.Code == StateCode.SUCCESS) |
| | | { |
| | | //var revData = Newtonsoft.Json.JsonConvert.DeserializeObject<List<IntegratedBrandDevice>>(pack.Data.ToString()); |
| | | Application.RunOnMainThread(() => |
| | | { |
| | | waitPage.Hide(); |
| | | var tipDialog = new OperationResultDisPalyPage(); |
| | | tipDialog.LoadPage(true, Language.StringByID(StringId.AddSuccess), "", Language.StringByID(StringId.CanStartUsingEnvironmentalSensor), Language.StringByID(StringId.Next)); |
| | | tipDialog.Show(); |
| | | AddDeviceEvent?.Invoke(new Function()); |
| | | this.CloseForm(); |
| | | }); |
| | | } |
| | | else if (pack.Code == "10801" || pack.Code == "9") |
| | | { |
| | | var mes = ""; |
| | | if (Language.CurrentLanguage == "Chinese") |
| | | { |
| | | mes = "该设备已经被添加。"; |
| | | } |
| | | else |
| | | { |
| | | mes = "This device has been added."; |
| | | } |
| | | Application.RunOnMainThread(() => |
| | | { |
| | | var tip = new Tip() |
| | | { |
| | | Text = mes, |
| | | CloseTime = 2, |
| | | Direction = AMPopTipDirection.None |
| | | }; |
| | | tip.Show(MainPage.BaseView); |
| | | }); |
| | | } |
| | | else |
| | | { |
| | | IMessageCommon.Current.ShowErrorInfoAlter(pack.Code); |
| | | } |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | MainPage.Log("2--::" + ex.Message); |
| | | } |
| | | finally |
| | | { |
| | | Application.RunOnMainThread(() => { waitPage.Hide(); }); |
| | | } |
| | | }) |
| | | { IsBackground = true }.Start(); |
| | | } |
| | | }; |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 关闭界面___________________________ |
| | | |
| | | /// <summary> |
| | | /// 关闭界面 |
| | | /// </summary> |
| | | public override void CloseFormBefore() |
| | | { |
| | | this.AddDeviceEvent = null; |
| | | base.CloseFormBefore(); |
| | | } |
| | | |
| | | #endregion |
| | | } |
| | | } |
New file |
| | |
| | | using HDL_ON.DAL.Server; |
| | | using HDL_ON.Entity; |
| | | using HDL_ON.Stan; |
| | | using HDL_ON.UI.UI2.PersonalCenter.PirDevice; |
| | | using Shared; |
| | | using System; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | | /// <summary> |
| | | /// 添加毫米波步骤1界面 |
| | | /// </summary> |
| | | public class SensorEnvironmentManagerPage : EditorCommonForm |
| | | { |
| | | #region ■ 变量声明___________________________ |
| | | |
| | | /// <summary> |
| | | /// 添加设备完成之后的回调事件 |
| | | /// </summary> |
| | | public Action DelDeviceEvent = null; |
| | | |
| | | Function function = null; |
| | | #endregion |
| | | |
| | | #region ■ 初始化_____________________________ |
| | | /// <summary> |
| | | /// 画面显示(底层会固定调用此方法,借以完成画面创建) |
| | | /// </summary> |
| | | public void ShowForm(Function device) |
| | | { |
| | | function = device; |
| | | //设置头部信息 |
| | | base.SetTitleText(Language.StringByID(StringId.Add) + device.name); |
| | | //这个界面的背景需要白色 |
| | | bodyFrameLayout.BackgroundColor = CSS.CSS_Color.BackgroundColor; |
| | | |
| | | //初始化中部信息 |
| | | this.InitMiddleFrame(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 初始化中部信息 |
| | | /// </summary> |
| | | private void InitMiddleFrame() |
| | | { |
| | | //图片 |
| | | var btnPic = new PicViewControl(132, 132); |
| | | btnPic.Y = Application.GetRealHeight(69); |
| | | btnPic.Gravity = Gravity.CenterHorizontal; |
| | | btnPic.UnSelectedImagePath = "PersonalCenter/AddDevice/SenesorMegahealthBg.png"; |
| | | bodyFrameLayout.AddChidren(btnPic); |
| | | |
| | | var btnTip = new Button() |
| | | { |
| | | Y = Application.GetRealHeight(309 - 44), |
| | | Gravity = Gravity.CenterHorizontal, |
| | | Width = Application.GetRealWidth(319), |
| | | Height = Application.GetRealHeight(84), |
| | | IsMoreLines = true, |
| | | TextAlignment = TextAlignment.Center, |
| | | TextColor = CSS.CSS_Color.FirstLevelTitleColor, |
| | | TextSize = CSS.CSS_FontSize.SubheadingFontSize, |
| | | }; |
| | | bodyFrameLayout.AddChidren(btnTip); |
| | | |
| | | if (Language.CurrentLanguage == "Chinese") |
| | | { |
| | | btnTip.Text = "该设备已添加到安防传感器类别,可到对应功能板块查看"; |
| | | } |
| | | else |
| | | { |
| | | btnTip.Text = "The device has been added to the security sensor category, which can be viewed in the corresponding function block."; |
| | | } |
| | | |
| | | var btnDel = new Button() |
| | | { |
| | | Y = Application.GetRealHeight(617 - 64), |
| | | Height = Application.GetRealHeight(50), |
| | | TextAlignment = TextAlignment.Center, |
| | | TextColor = CSS.CSS_Color.WarningColor, |
| | | TextSize = CSS.CSS_FontSize.SubheadingFontSize, |
| | | TextID = StringId.DeleteDevice, |
| | | BackgroundColor = CSS.CSS_Color.MainBackgroundColor, |
| | | }; |
| | | bodyFrameLayout.AddChidren(btnDel); |
| | | |
| | | btnDel.MouseUpEventHandler = (sender, e) => { |
| | | var pack = PirSend.DeleteDevice(function.deviceId); |
| | | if (pack.Code == StateCode.SUCCESS) |
| | | { |
| | | DelDeviceEvent?.Invoke(); |
| | | this.CloseForm(); |
| | | var mes = ""; |
| | | if (Language.CurrentLanguage == "Chinese") |
| | | { |
| | | mes = "设备删除成功。"; |
| | | } |
| | | else |
| | | { |
| | | mes = "Device deleted successfully."; |
| | | } |
| | | var tip = new Tip() |
| | | { |
| | | Text = mes, |
| | | CloseTime = 2, |
| | | Direction = AMPopTipDirection.None |
| | | }; |
| | | tip.Show(MainPage.BaseView); |
| | | } |
| | | else |
| | | { |
| | | IMessageCommon.Current.ShowErrorInfoAlter(pack.Code); |
| | | } |
| | | }; |
| | | |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | #region ■ 关闭界面___________________________ |
| | | |
| | | /// <summary> |
| | | /// 关闭界面 |
| | | /// </summary> |
| | | public override void CloseFormBefore() |
| | | { |
| | | this.DelDeviceEvent = null; |
| | | base.CloseFormBefore(); |
| | | } |
| | | |
| | | #endregion |
| | | } |
| | | } |
| | |
| | | using HDL_ON.Stan; |
| | | using Shared; |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Text; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | |
| | | using HDL_ON.UI.UI2.PersonalCenter.PirDevice; |
| | | using Shared; |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Text; |
| | | |
| | | namespace HDL_ON.UI |
| | | { |
| | |
| | | this.RemoveFromParent(); |
| | | }; |
| | | break; |
| | | case SPK.SensorEnvironment: |
| | | var form2 = new AddSensorEnvironmentPage(); |
| | | form2.AddForm(device); |
| | | form2.AddDeviceEvent = (functionObj) => { |
| | | refreshView.BeginHeaderRefreshing(); |
| | | this.RemoveFromParent(); |
| | | }; |
| | | break; |
| | | } |
| | | }; |
| | | } |
| | |
| | | contentView.BeginHeaderRefreshing(); |
| | | }; |
| | | break; |
| | | case SPK.SensorEnvironment: |
| | | var smPage1 = new SensorEnvironmentManagerPage(); |
| | | smPage1.AddForm(device); |
| | | smPage1.DelDeviceEvent = () => |
| | | { |
| | | contentView.BeginHeaderRefreshing(); |
| | | }; |
| | | break; |
| | | } |
| | | }; |
| | | } |
| | |
| | | /// </summary> |
| | | FrameLayout sensorListView; |
| | | |
| | | VerticalScrolViewLayout sensorListContentView; |
| | | |
| | | /// <summary> |
| | | /// 天气名称文本 |
| | | /// </summary> |
| | |
| | | contentView.AddChidren(btnRoomClickRow); |
| | | |
| | | #endregion |
| | | |
| | | sensorListView = new FrameLayout() |
| | | sensorListContentView = new VerticalScrolViewLayout() |
| | | { |
| | | Gravity = Gravity.CenterHorizontal, |
| | | Y = Application.GetRealHeight(50), |
| | | Height = Application.GetRealHeight(456), |
| | | Height = Application.GetRealHeight(400), |
| | | Radius = (uint)Application.GetRealWidth(12), |
| | | BorderColor = 0x00000000, |
| | | BorderWidth = 0, |
| | | }; |
| | | contentView.AddChidren(sensorListView); |
| | | contentView.AddChidren(sensorListContentView); |
| | | sensorListView = new FrameLayout(); |
| | | sensorListContentView.AddChidren(sensorListView); |
| | | |
| | | LoadSenesorList(); |
| | | |
| | |
| | | name = sensor.name, |
| | | sid = sensor.sid, |
| | | deviceId = sensor.deviceId, |
| | | attributes = new List<FunctionAttributes> { new FunctionAttributes { key = "value", state = seTemp.state, curValue = seTemp.curValue } }, |
| | | roomIds = sensor.roomIds, |
| | | attributes = new List<FunctionAttributes> { new FunctionAttributes { key = "value", state = seTemp.state, curValue = seTemp.curValue } |
| | | ,new FunctionAttributes { key = "spk"} } |
| | | }; |
| | | switch (seTemp.key) |
| | | { |
| | | case "co2": |
| | | newTemp.spk = SPK.SensorCO2; |
| | | newTemp.SetAttrState("spk", "co2"); |
| | | break; |
| | | case "pm25": |
| | | newTemp.spk = SPK.SensorPm25; |
| | | newTemp.SetAttrState("spk", "pm25"); |
| | | break; |
| | | case "humidity": |
| | | newTemp.spk = SPK.SensorHumidity; |
| | | newTemp.SetAttrState("spk", "humidity"); |
| | | break; |
| | | case "temperature": |
| | | newTemp.spk = SPK.SensorTemperature; |
| | | newTemp.SetAttrState("spk", "temperature"); |
| | | break; |
| | | case "tvoc": |
| | | newTemp.spk = SPK.SensorTVOC; |
| | | newTemp.SetAttrState("spk", "tvoc"); |
| | | break; |
| | | } |
| | | LoadSensorDiv(newTemp, index); |
| | | index++; |
| | | |
| | | if (room.roomId == "" || sensor.roomIds.Contains(room.roomId)) |
| | | { |
| | | LoadSensorDiv(newTemp, index); |
| | | index++; |
| | | } |
| | | } |
| | | } |
| | | else |
| | | { |
| | | #if DEBUG |
| | | continue; |
| | | #endif |
| | | LoadSensorDiv(sensor, index); |
| | | index++; |
| | | if (room.roomId == "" || sensor.roomIds.Contains(room.roomId)) |
| | | { |
| | | LoadSensorDiv(sensor, index); |
| | | index++; |
| | | } |
| | | } |
| | | |
| | | new System.Threading.Thread(() => |
| | |
| | | }) |
| | | { IsBackground = true }.Start(); |
| | | } |
| | | sensorListView.Height = Application.GetRealWidth(124 * (index + 1) / 2); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 加载传感器列表 |
| | | /// </summary> |
| | | void LoadSensorDiv(Function sensor, int index) |
| | | void LoadSensorDiv(Function sensor,int index) |
| | | { |
| | | var levelColorList = sensorTemp.GetLevelColorList(sensor.spk); |
| | | var levelTextList = sensorTemp.GetLevelTextList(sensor.spk); |
| | | if (room.roomId == "" || sensor.roomIds.Contains(room.roomId)) |
| | | { |
| | | var sensorTag = sensor.spk + sensor.sid + sensor.deviceId; |
| | | FrameLayout sensorView = new FrameLayout() |
| | |
| | | }; |
| | | selfInfoView.AddChidren(btnSeltSensorValue); |
| | | |
| | | Button btnShowData; |
| | | btnShowData = new Button() |
| | | { |
| | | X = Application.GetRealWidth(291), |
| | | Y = Application.GetRealWidth(62), |
| | | Width = Application.GetMinRealAverage(32), |
| | | Height = Application.GetMinRealAverage(32), |
| | | UnSelectedImagePath = "FunctionIcon/EnvironmentalScience/DiagramIcon.png", |
| | | SelectedImagePath = "FunctionIcon/EnvironmentalScience/DiagramIconOn.png", |
| | | IsSelected = true, |
| | | }; |
| | | selfInfoView.AddChidren(btnShowData); |
| | | //Button btnShowData; |
| | | //btnShowData = new Button() |
| | | //{ |
| | | // X = Application.GetRealWidth(291), |
| | | // Y = Application.GetRealWidth(62), |
| | | // Width = Application.GetMinRealAverage(32), |
| | | // Height = Application.GetMinRealAverage(32), |
| | | // UnSelectedImagePath = "FunctionIcon/EnvironmentalScience/DiagramIcon.png", |
| | | // SelectedImagePath = "FunctionIcon/EnvironmentalScience/DiagramIconOn.png", |
| | | // IsSelected = true, |
| | | //}; |
| | | //selfInfoView.AddChidren(btnShowData); |
| | | //btnShowData.MouseUpEventHandler = (sender, e) => { |
| | | // btnShowData.IsSelected = !btnShowData.IsSelected; |
| | | // if(btnShowData.IsSelected) |
| | |
| | | |
| | | bool initTitleButton = true; |
| | | |
| | | foreach (var tempSensor in FunctionList.List.GetEnvirSensorsList()) |
| | | var tempList = FunctionList.List.GetEnvirSensorsList(); |
| | | |
| | | foreach (var tempSensor in tempList) |
| | | { |
| | | if (tempSensor.sid == function.sid) |
| | | { |
| | |
| | | #region 其它传感器信息栏 |
| | | FrameLayout otherInfoView = new FrameLayout() |
| | | { |
| | | Gravity = Gravity.CenterVertical, |
| | | Gravity = Gravity.CenterHorizontal, |
| | | Width = Application.GetRealWidth(343), |
| | | Height = Application.GetRealWidth(100), |
| | | BackgroundColor = CSS_Color.MainBackgroundColor, |
| | |
| | | { |
| | | Action backAction = () => |
| | | { |
| | | btnSeltSensorName.Text = tempSensor.name; |
| | | MainPage.Log("45678i"); |
| | | Application.RunOnMainThread(() => |
| | | { |
| | | btnSeltSensorName.Text = tempSensor.name; |
| | | }); |
| | | }; |
| | | var infoView = new FunctionBaseInfoSetPage(tempSensor, backAction); |
| | | MainPage.BasePageView.AddChidren(infoView); |
| | |
| | | btnShowData1.IsSelected = !btnShowData1.IsSelected; |
| | | if (btnShowData1.IsSelected) |
| | | { |
| | | if (!showFunctions.Contains(function)) |
| | | if (!showFunctions.Contains(tempSensor)) |
| | | { |
| | | showFunctions.Add(function); |
| | | showFunctions.Add(tempSensor); |
| | | } |
| | | } |
| | | else |
| | | { |
| | | if (showFunctions.Contains(function)) |
| | | if (showFunctions.Contains(tempSensor)) |
| | | { |
| | | showFunctions.Remove(function); |
| | | showFunctions.Remove(tempSensor); |
| | | } |
| | | } |
| | | LoadMothed_GetSensorHistoryData(); |
| | | }; |
| | | #endregion |
| | | |
| | | contentView.AddChidren(new Button() |
| | | { |
| | | Height = Application.GetRealHeight(12), |
| | | }); |
| | | |
| | | } |
| | | #endregion |
| | |
| | | |
| | | string yDataString = ""; |
| | | |
| | | foreach (var sr in FunctionList.List.GetEnvirSensorsList()) |
| | | foreach (var sr in showFunctions) |
| | | { |
| | | if (sr.spk != function.spk) |
| | | { |
| | |
| | | } |
| | | |
| | | var sensorType = sr.spk.Split(".")[1]; |
| | | var revertObj = new HttpServerRequest().GetSensorHistory(curQueryType, sr.deviceId,"value"); |
| | | var queryType = sr.GetAttrState("spk")==null? "value": sr.GetAttrState("spk"); |
| | | |
| | | var revertObj = new HttpServerRequest().GetSensorHistory(curQueryType, sr.deviceId, queryType); |
| | | if (revertObj != null) |
| | | { |
| | | if (revertObj.Code == StateCode.SUCCESS) |
| | |
| | | function.name = name; |
| | | btnFunctionName.Text = name; |
| | | function.UpdataFuncitonInfo(); |
| | | actionRefresh?.Invoke(); |
| | | } |
| | | }; |
| | | new PublicAssmebly().LoadDialog_EditParater(StringId.ChangeName, function.name, callBackAction,StringId.DeviceNameCannotBeEmpty,0,new System.Collections.Generic.List<string>()); |