wxr
2021-11-30 e75ccccb370b47305c6eadb321efb27c86cdd28b
合并
33个文件已添加
26个文件已修改
6640 ■■■■■ 已修改文件
.vs/HDL_APP_Project/xs/UserPrefs.xml 38 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
DLL/IOS/Shared.IOS.HDLSceneSiri.dll 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_Android/Assets/Language.ini 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/AppDelegate.cs 31 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Base.lproj/Intents.intentdefinition 181 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Entitlements.plist 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/HDL-ON_iOS.csproj 38 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Info.plist 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Other/SkipControl.cs 140 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Resources/Language.ini 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Resources/Phone/PersonalCenter/SiriIcon.png 补丁 | 查看 | 原始文档 | blame | 历史
HDL_APP_Project.sln 42 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Common/HDLCommon.cs 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Common/R.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/HttpServerRequest.cs 128 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/HttpUtil.cs 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Entity/Function/SecurityAlarm.cs 63 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/HDL_ON.projitems 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI1-Login/LoginPage.cs 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI1-Login/LoginPageBLL.cs 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/3-Intelligence/Automation/LogicView/LogicTypeTitleView.cs 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/3-Intelligence/IntelligencePage.cs 229 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/3-Intelligence/Scene/SceneEditPage.cs 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs 82 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPageBLL.cs 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/Transfer/TransferingResidencePage.cs 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddAlarmDeploymentPage.cs 342 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddInputPage.cs 127 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddOutputPage.cs 194 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/ArmCenterPage.cs 72 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/PushConfigPage.cs 196 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriBinding/ApiDefinition.cs 86 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriBinding/Properties/AssemblyInfo.cs 34 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriBinding/SiriBinding.csproj 56 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriBinding/Structs.cs 18 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/Entitlements.plist 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/HDLRunSceneIntentHandlder.cs 146 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/Info.plist 44 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/IntentHandler.cs 134 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/Server/HttpServerRequest.cs 101 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/Server/HttpUtil.cs 412 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/Server/IMessageCommon.cs 151 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/Server/NewAPI.cs 756 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/Server/NewApiRes.cs 1510 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/SiriIntents.csproj 124 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntents/packages.config 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntentsUI/Entitlements.plist 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntentsUI/Info.plist 46 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntentsUI/IntentViewController.cs 105 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntentsUI/IntentViewController.designer.cs 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntentsUI/MainInterface.storyboard 48 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriIntentsUI/SiriIntentsUI.csproj 120 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriKit/Base.lproj/Intents.intentdefinition 265 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriKit/Data/DataManager.cs 188 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriKit/Data/NSUserDefaultsHelper.cs 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriKit/Data/SceneDateManager.cs 104 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriKit/Properties/AssemblyInfo.cs 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
SiriKit/SiriKit.csproj 60 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ThirdPartyIntegration/siri/libOnProSiriIntents.a 补丁 | 查看 | 原始文档 | blame | 历史
.vs/HDL_APP_Project/xs/UserPrefs.xml
@@ -2,24 +2,29 @@
  <MonoDevelop.Ide.ItemProperties.SiriIntentUI>
    <MonoDevelop.MacDev.AppleDevelopmentTeam />
  </MonoDevelop.Ide.ItemProperties.SiriIntentUI>
  <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneDeviceTarget" />
  <MonoDevelop.Ide.Workbench ActiveDocument="HDL_ON/DAL/Server/HttpUtil.cs">
  <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneDeviceTarget.6242be7109c740c6cb8999a8904b6e0ea8d45192" />
  <MonoDevelop.Ide.Workbench ActiveDocument="SiriIntentsUI/IntentViewController.cs">
    <Files>
      <File FileName="HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPage.cs" Line="203" Column="17" IsPinned="True" />
      <File FileName="HDL_ON/DAL/Server/HttpUtil.cs" Line="21" Column="79" />
      <File FileName="HDL-ON_iOS/Other/SkipControl.cs" Line="68" Column="45" />
      <File FileName="HDL-ON_iOS/Info.plist" />
      <File FileName="SiriIntentsUI/IntentViewController.cs" Line="1" Column="1" />
    </Files>
    <Pads>
      <Pad Id="ProjectPad">
        <State name="__root__">
          <Node name="HDL_APP_Project" expanded="True">
            <Node name="HDL-ON_iOS" expanded="True" selected="True" />
            <Node name="HDL-ON_iOS" expanded="True">
              <Node name="Other" expanded="True" />
            </Node>
            <Node name="SiriIntents" expanded="True" />
            <Node name="SiriIntentsUI" expanded="True">
              <Node name="IntentViewController.cs" selected="True" />
            </Node>
            <Node name="SiriKit" expanded="True">
              <Node name="References" expanded="True" />
              <Node name="Base.lproj" expanded="True" />
            </Node>
          </Node>
        </State>
      </Pad>
      <Pad Id="MonoDevelop.Debugger.WatchPad">
        <State>
          <Value>tempFunction.deviceId</Value>
          <Value>updata2.ToString()</Value>
        </State>
      </Pad>
    </Pads>
@@ -31,14 +36,21 @@
    <String>Shared.IOS/Shared.IOS.csproj</String>
    <String>SiriIntent/SiriIntent.csproj</String>
    <String>SceneKit/SceneKit.csproj</String>
    <String>HdlOnProSiriIntents/HdlOnProSiriIntents.csproj</String>
    <String>HdlOnProSiriIntentsUI/HdlOnProSiriIntentsUI.csproj</String>
    <String>HdlOnProSiriKit/HdlOnProSiriKit.csproj</String>
    <String>HDLSiriIntents/HDLSiriIntents.csproj</String>
    <String>HDLSiriIntentsUI/HDLSiriIntentsUI.csproj</String>
    <String>HDLSiriKit/HDLSiriKit.csproj</String>
    <String>SiriBinding/SiriBinding.csproj</String>
  </DisabledProjects>
  <MonoDevelop.Ide.Workspace ActiveConfiguration="Release|iPhone" />
  <MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
  <MonoDevelop.Ide.ItemProperties.HDL-ON__Android PreferredExecutionTarget="Android.SelectDevice" />
  <MonoDevelop.Ide.DebuggingService.Breakpoints>
    <BreakpointStore>
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HdlSiriKit/SkipControl.cs" relfile="HdlSiriKit/SkipControl.cs" line="28" column="1" />
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL-ON_iOS/Other/SkipControl.cs" relfile="HDL-ON_iOS/Other/SkipControl.cs" line="25" column="1" />
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HdlSiriKit/SkipControl.cs" relfile="HdlSiriKit/SkipControl.cs" line="14" column="1" />
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddAlarmDeploymentPage.cs" relfile="HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddAlarmDeploymentPage.cs" line="366" column="1" />
    </BreakpointStore>
  </MonoDevelop.Ide.DebuggingService.Breakpoints>
  <MultiItemStartupConfigurations />
DLL/IOS/Shared.IOS.HDLSceneSiri.dll
Binary files differ
HDL-ON_Android/Assets/Language.ini
@@ -500,6 +500,7 @@
512=Message push is not enabled, please go to settings.
513=Please enter the pairing code
514=Gateway location information is not configured
515=Add Security
 
1000=Room Humidity
1001=V-chip
@@ -1623,7 +1624,7 @@
512=消息推送未开启,请前往设置。
513=请输入配对码
514=未配置网关位置信息
515=添加安防
 
1000=室内湿度
1001=童锁
HDL-ON_iOS/AppDelegate.cs
@@ -60,7 +60,7 @@
        //    // If not required for your application you can safely delete this method
        //    return true;
        //}
        internal static UINavigationController rootViewController;
        public static UINavigationController rootViewController;
        public static void CleanApplicationIconBadgeNumber()
        {
@@ -277,32 +277,8 @@
            //    //RemoteInfo.Current.ReadMsgList(true);
            //}
            #region Siri
            // Request access to Siri
            INPreferences.RequestSiriAuthorization((INSiriAuthorizationStatus status) => {
                // Respond to returned status
                switch (status)
                {
                    case INSiriAuthorizationStatus.Authorized:
                        break;
                    case INSiriAuthorizationStatus.Denied:
                        break;
                    case INSiriAuthorizationStatus.NotDetermined:
                        break;
                    case INSiriAuthorizationStatus.Restricted:
                        break;
                }
            });
            var language = INPreferences.SiriLanguageCode;
            // Take action based on language
            if (language == "en-US")
            {
                // Do something...
            }
            #endregion
            //高德key
            GDMapKit.setGDApiKey("f0635ea15c5d579c6e93d9f07a06da69");
            //高德key
            GDMapKit.setGDApiKey("f0635ea15c5d579c6e93d9f07a06da69");
@@ -475,6 +451,7 @@
            HDL_ON.DriverLayer.Control.Ins.SearchLoaclGateway();
        }
    }
}
HDL-ON_iOS/Base.lproj/Intents.intentdefinition
New file
@@ -0,0 +1,181 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>INEnums</key>
    <array/>
    <key>INIntentDefinitionModelVersion</key>
    <string>1.2</string>
    <key>INIntentDefinitionNamespace</key>
    <string>8yVV3C</string>
    <key>INIntentDefinitionSystemVersion</key>
    <string>20G165</string>
    <key>INIntentDefinitionToolsBuildVersion</key>
    <string>13A233</string>
    <key>INIntentDefinitionToolsVersion</key>
    <string>13.0</string>
    <key>INIntents</key>
    <array>
        <dict>
            <key>INIntentCategory</key>
            <string>generic</string>
            <key>INIntentDescription</key>
            <string>Run Scene</string>
            <key>INIntentDescriptionID</key>
            <string>Pe02nj</string>
            <key>INIntentLastParameterTag</key>
            <integer>2</integer>
            <key>INIntentName</key>
            <string>HDLRunScene</string>
            <key>INIntentParameterCombinations</key>
            <dict>
                <key>sceneName,sceneId</key>
                <dict>
                    <key>INIntentParameterCombinationIsPrimary</key>
                    <true/>
                    <key>INIntentParameterCombinationSupportsBackgroundExecution</key>
                    <true/>
                    <key>INIntentParameterCombinationTitle</key>
                    <string>执行场景“${sceneName}”</string>
                    <key>INIntentParameterCombinationTitleID</key>
                    <string>oCGdw4</string>
                </dict>
            </dict>
            <key>INIntentParameters</key>
            <array>
                <dict>
                    <key>INIntentParameterDisplayName</key>
                    <string>Scene Name</string>
                    <key>INIntentParameterDisplayNameID</key>
                    <string>wC0SgK</string>
                    <key>INIntentParameterDisplayPriority</key>
                    <integer>1</integer>
                    <key>INIntentParameterMetadata</key>
                    <dict>
                        <key>INIntentParameterMetadataCapitalization</key>
                        <string>Sentences</string>
                        <key>INIntentParameterMetadataDefaultValueID</key>
                        <string>xz2KkJ</string>
                    </dict>
                    <key>INIntentParameterName</key>
                    <string>sceneName</string>
                    <key>INIntentParameterTag</key>
                    <integer>1</integer>
                    <key>INIntentParameterType</key>
                    <string>String</string>
                </dict>
                <dict>
                    <key>INIntentParameterDisplayName</key>
                    <string>Scene Id</string>
                    <key>INIntentParameterDisplayNameID</key>
                    <string>MtgGtd</string>
                    <key>INIntentParameterDisplayPriority</key>
                    <integer>2</integer>
                    <key>INIntentParameterMetadata</key>
                    <dict>
                        <key>INIntentParameterMetadataCapitalization</key>
                        <string>Sentences</string>
                        <key>INIntentParameterMetadataDefaultValueID</key>
                        <string>hQHCm1</string>
                    </dict>
                    <key>INIntentParameterName</key>
                    <string>sceneId</string>
                    <key>INIntentParameterTag</key>
                    <integer>2</integer>
                    <key>INIntentParameterType</key>
                    <string>String</string>
                </dict>
            </array>
            <key>INIntentResponse</key>
            <dict>
                <key>INIntentResponseCodes</key>
                <array>
                    <dict>
                        <key>INIntentResponseCodeFormatString</key>
                        <string>${sceneName}</string>
                        <key>INIntentResponseCodeFormatStringID</key>
                        <string>Pq8YBC</string>
                        <key>INIntentResponseCodeName</key>
                        <string>success</string>
                        <key>INIntentResponseCodeSuccess</key>
                        <true/>
                    </dict>
                    <dict>
                        <key>INIntentResponseCodeFormatString</key>
                        <string>${errorMessage}</string>
                        <key>INIntentResponseCodeFormatStringID</key>
                        <string>CX5DVI</string>
                        <key>INIntentResponseCodeName</key>
                        <string>failure</string>
                    </dict>
                    <dict>
                        <key>INIntentResponseCodeName</key>
                        <string>error</string>
                        <key>INIntentResponseCodeSuccess</key>
                        <true/>
                    </dict>
                </array>
                <key>INIntentResponseLastParameterTag</key>
                <integer>3</integer>
                <key>INIntentResponseParameters</key>
                <array>
                    <dict>
                        <key>INIntentResponseParameterDisplayName</key>
                        <string>Error Message</string>
                        <key>INIntentResponseParameterDisplayNameID</key>
                        <string>HxQb2M</string>
                        <key>INIntentResponseParameterDisplayPriority</key>
                        <integer>1</integer>
                        <key>INIntentResponseParameterName</key>
                        <string>errorMessage</string>
                        <key>INIntentResponseParameterTag</key>
                        <integer>1</integer>
                        <key>INIntentResponseParameterType</key>
                        <string>String</string>
                    </dict>
                    <dict>
                        <key>INIntentResponseParameterDisplayName</key>
                        <string>Success Message</string>
                        <key>INIntentResponseParameterDisplayNameID</key>
                        <string>BaAbSP</string>
                        <key>INIntentResponseParameterDisplayPriority</key>
                        <integer>2</integer>
                        <key>INIntentResponseParameterName</key>
                        <string>successMessage</string>
                        <key>INIntentResponseParameterTag</key>
                        <integer>2</integer>
                        <key>INIntentResponseParameterType</key>
                        <string>String</string>
                    </dict>
                    <dict>
                        <key>INIntentResponseParameterDisplayName</key>
                        <string>Scene Name</string>
                        <key>INIntentResponseParameterDisplayNameID</key>
                        <string>pqg7cb</string>
                        <key>INIntentResponseParameterDisplayPriority</key>
                        <integer>3</integer>
                        <key>INIntentResponseParameterName</key>
                        <string>sceneName</string>
                        <key>INIntentResponseParameterTag</key>
                        <integer>3</integer>
                        <key>INIntentResponseParameterType</key>
                        <string>String</string>
                    </dict>
                </array>
            </dict>
            <key>INIntentRestrictions</key>
            <integer>1</integer>
            <key>INIntentTitle</key>
            <string>Run Scene</string>
            <key>INIntentTitleID</key>
            <string>j3jRXP</string>
            <key>INIntentType</key>
            <string>Custom</string>
            <key>INIntentVerb</key>
            <string>Do</string>
        </dict>
    </array>
    <key>INTypes</key>
    <array/>
</dict>
</plist>
HDL-ON_iOS/Entitlements.plist
@@ -10,5 +10,9 @@
    </array>
    <key>com.apple.developer.siri</key>
    <true/>
    <key>com.apple.security.application-groups</key>
    <array>
        <string>group.com.hdl.onpro</string>
    </array>
</dict>
</plist>
HDL-ON_iOS/HDL-ON_iOS.csproj
@@ -28,6 +28,7 @@
        <CodesignKey>iPhone Developer</CodesignKey>
        <MtouchExtraArgs>-gcc_flags="-dead_strip -ObjC";-w</MtouchExtraArgs>
        <CodesignProvision>On+Dev-20210616-1</CodesignProvision>
        <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
    </PropertyGroup>
    <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhoneSimulator' ">
        <DebugType>none</DebugType>
@@ -38,6 +39,7 @@
        <MtouchLink>SdkOnly</MtouchLink>
        <MtouchArch>x86_64</MtouchArch>
<CodesignKey>iPhone Developer</CodesignKey>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
    </PropertyGroup>
    <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhone' ">
        <DebugSymbols>true</DebugSymbols>
@@ -54,8 +56,9 @@
        <MtouchLink>SdkOnly</MtouchLink>
        <MtouchExtraArgs>-gcc_flags="-dead_strip -ObjC"</MtouchExtraArgs>
        <MtouchEnableSGenConc>false</MtouchEnableSGenConc>
<CodesignProvision>OnPro211116-1</CodesignProvision>
<CodesignProvision>OnPro211125-1-Dev</CodesignProvision>
<CodesignEntitlements>Entitlements.plist</CodesignEntitlements>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
    </PropertyGroup>
    <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhone' ">
        <DebugType>none</DebugType>
@@ -70,6 +73,7 @@
        <MtouchExtraArgs>-gcc_flags="-dead_strip -ObjC"</MtouchExtraArgs>
        <MtouchI18n>cjk</MtouchI18n>
        <CodesignProvision>OnPro-Hoc20211117-1</CodesignProvision>
        <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
    </PropertyGroup>
    <ItemGroup>
        <Reference Include="System" />
@@ -104,25 +108,28 @@
        <Reference Include="Shared.IOS.HDLLinphoneSDK">
          <HintPath>..\DLL\Linphone\iOS\Shared.IOS.HDLLinphoneSDK.dll</HintPath>
        </Reference>
        <Reference Include="Shared.IOS.HDLSceneSiri">
          <HintPath>..\..\HDLXamarinSceneSiri\Shared.IOS.HDLSceneSiri\Shared.IOS.HDLSceneSiri\bin\Release\Shared.IOS.HDLSceneSiri.dll</HintPath>
        </Reference>
    </ItemGroup>
    <ItemGroup>
      <PackageReference Include="Newtonsoft.Json">
        <Version>13.0.1</Version>
      </PackageReference>
      <PackageReference Include="MQTTnet">
        <Version>3.0.16</Version>
        <Version>3.1.0</Version>
      </PackageReference>
      <PackageReference Include="Microsoft.AppCenter.Analytics">
        <Version>4.3.0</Version>
        <Version>4.4.0</Version>
      </PackageReference>
      <PackageReference Include="Microsoft.AppCenter.Crashes">
        <Version>4.3.0</Version>
        <Version>4.4.0</Version>
      </PackageReference>
      <PackageReference Include="ZXing.Net.Mobile">
        <Version>2.4.1</Version>
      </PackageReference>
      <PackageReference Include="RestSharp">
        <Version>106.12.0</Version>
        <Version>106.13.0</Version>
      </PackageReference>
      <PackageReference Include="Xamarin.iOS.Bugly">
        <Version>1.0.4</Version>
@@ -463,6 +470,7 @@
        <Folder Include="Resources\Phone\FunctionIcon\Light\LightScene\" />
        <Folder Include="Resources\Phone\PersonalCenter\FacePassage\" />
        <Folder Include="Resources\Phone\FunctionIcon\Electrical\AirSwitch\" />
        <Folder Include="Base.lproj\" />
    </ItemGroup>
    <ItemGroup>
        <InterfaceDefinition Include="LaunchScreen.storyboard" />
@@ -490,6 +498,7 @@
        <Compile Include="ZXingOverlayView.cs" />
        <Compile Include="Other\JLCountrycode.cs" />
        <Compile Include="BlueWifi.cs" />
        <Compile Include="Other\SkipControl.cs" />
    </ItemGroup>
    <ItemGroup>
      <BundleResource Include="Resources\Phone\LoginIcon\ShowPasswordIcon.png" />
@@ -1357,6 +1366,7 @@
      <BundleResource Include="Resources\Phone\FunctionIcon\AirFresh\btnCloseIcon.png" />
      <BundleResource Include="Resources\Phone\FunctionIcon\AirFresh\btnInfoIcon.png" />
      <BundleResource Include="Resources\Phone\FunctionIcon\AirFresh\HumiOnIcon.png" />
      <BundleResource Include="Resources\Phone\PersonalCenter\SiriIcon.png" />
    </ItemGroup>
    <ItemGroup>
      <ITunesArtwork Include="iTunesArtwork" />
@@ -1401,11 +1411,23 @@
        <Project>{2DDF4C3C-6998-432E-9F43-6786D82F0630}</Project>
        <Name>Blufi</Name>
      </ProjectReference>
      <ProjectReference Include="..\SiriIntentUI\SiriIntentUI.csproj">
      <ProjectReference Include="..\SiriIntents\SiriIntents.csproj">
        <IsAppExtension>true</IsAppExtension>
        <Project>{B594D3F5-4B93-4988-B45E-150BBFDC8A43}</Project>
        <Name>SiriIntentUI</Name>
        <Project>{760980F5-1CD3-4F4F-9134-34D87BECD790}</Project>
        <Name>SiriIntents</Name>
      </ProjectReference>
      <ProjectReference Include="..\SiriIntentsUI\SiriIntentsUI.csproj">
        <IsAppExtension>true</IsAppExtension>
        <Project>{ACC48A7F-250B-4915-A250-9BC399DBD6B3}</Project>
        <Name>SiriIntentsUI</Name>
      </ProjectReference>
      <ProjectReference Include="..\SiriKit\SiriKit.csproj">
        <Project>{8B1652FA-5158-4D57-B90D-07BB91766625}</Project>
        <Name>SiriKit</Name>
      </ProjectReference>
    </ItemGroup>
    <ItemGroup>
      <Content Include="Base.lproj\Intents.intentdefinition" />
    </ItemGroup>
    <Import Project="..\HDL_ON\HDL_ON.projitems" Label="Shared" Condition="Exists('..\HDL_ON\HDL_ON.projitems')" />
    <Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.CSharp.targets" />
HDL-ON_iOS/Info.plist
@@ -42,7 +42,7 @@
    <key>LSRequiresIPhoneOS</key>
    <true/>
    <key>MinimumOSVersion</key>
    <string>11.0</string>
    <string>12.0</string>
    <key>UIDeviceFamily</key>
    <array>
        <integer>1</integer>
@@ -135,5 +135,9 @@
    <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>
</dict>
</plist>
HDL-ON_iOS/Other/SkipControl.cs
New file
@@ -0,0 +1,140 @@
using System;
using CoreGraphics;
using Foundation;
using HDL_ON.Entity;
using HDLSceneSiri;
using Intents;
using IntentsUI;
using Shared;
using UIKit;
namespace Other
{
    public class SkipControl
    {
        public SkipControl()
        {
        }
        public void SkipSiriView()
        {
            //var user = new SiriBaseView();
            //user.View.BackgroundColor = new UIColor(242, 243, 247, 1);
            //HDL_ON_iOS.AppDelegate.rootViewController.PushViewController(user, true);
            var sDM = new SiriKit.SceneDateManager();
            Console.WriteLine($"IsLogin:{sDM.IsLgoin};accessToken:{sDM.AccessToken};refreshToken:{sDM.RefreshToken};RegionUrl:{sDM.RegionUrl};HomeId:{sDM.HomeId}");
            //NSMutableArray list = new NSMutableArray();
            //foreach (var localScene in HDL_ON.Entity.FunctionList.List.scenes)
            //{
            //    list.Add(new HDLSceneSiri.HDLSiriControlModel()
            //    {
            //        UserSceneId = localScene.userSceneId,
            //        Name = localScene.name,
            //    });
            //}
            //var vc = new HDLSceneSiri.HDLSiriSceneListViewController();
            //vc.DataSource = list;
            ////vc.TitleName
            ////PresentViewController(vc, true, null);
            //HDL_ON_iOS.AppDelegate.rootViewController.PushViewController(vc, true);
            //1.初始化dataList
            NSMutableArray dataSourceList = new NSMutableArray();
            //2.初始化场景列表数据
            HDLSiriShortcutModel sceneModel = new HDLSiriShortcutModel();
            if (Language.CurrentLanguage == "Chinese")
            {
                sceneModel.Title = "场景";
                sceneModel.Content = "将场景添加到快捷指令,即可通过Siri执行";
            }
            else
            {
                sceneModel.Title = "Scenes";
                sceneModel.Content = "Add the scene to the shortcut, which can be executed through Siri";
            }
            NSMutableArray list = new NSMutableArray();
            foreach (var localScene in HDL_ON.Entity.FunctionList.List.scenes)
            {
                list.Add(new HDLSiriControlModel()
                {
                    ControlId = localScene.userSceneId,//不能为空
                    ControlName = localScene.name,//不能为空
                    ControlType = "1",//不能为空
                    ControlJSONStr = "1",//不能为空
                    ActionName = Language.CurrentLanguage == "Chinese"? "场景": "Scene"//不能为空
                });
            }
            sceneModel.List = NSArray.FromArray<HDLSiriControlModel>(list);
            dataSourceList.Add(sceneModel);
            //3.初始化安防列表数据
            HDLSiriShortcutModel securityModel = new HDLSiriShortcutModel();
            if (Language.CurrentLanguage == "Chinese")
            {
                securityModel.Title = "安防";
                securityModel.Content = "将安防添加到快捷指令,即可通过Siri执行";
            }else
            {
                securityModel.Title = "Security";
                securityModel.Content = "Add security to the shortcut, which can be executed through Siri";
            }
            NSMutableArray list2 = new NSMutableArray();
            foreach (var temp in HDL_ON.Entity.FunctionList.List.securities)
            {
                SecurityState securityState = new SecurityState()
                {
                    gatewayId = DB_ResidenceData.Instance.HomeGateway.gatewayId,
                    sid = temp.sid,
                    status = "enable",
                    userSecurityId = temp.userSecurityId
                };
                var ControlJSONStr = Newtonsoft.Json.JsonConvert.SerializeObject(securityState);
                list2.Add(new HDLSiriControlModel()
                {
                    ControlId = temp.userSecurityId,//不能为空
                    ControlName = temp.name,//不能为空
                    ControlType = "2",//不能为空
                    ControlJSONStr = ControlJSONStr,//不能为空
                    ActionName = Language.CurrentLanguage == "Chinese" ? "安防" : "Security"//不能为空
                });
            }
            securityModel.List = NSArray.FromArray<HDLSiriControlModel>(list2);
            dataSourceList.Add(securityModel);
            //4.跳转Siri添加或者编辑管理页面
            HDLSceneSiri.HDLSiriSceneListViewController vc = new HDLSceneSiri.HDLSiriSceneListViewController();
            vc.DataSource = dataSourceList;
            vc.HomeId = DB_ResidenceData.Instance.CurrentRegion.id;//不能为空
            if (Language.CurrentLanguage == "Chinese")
            {
                vc.TitleName = "快捷指令";
            }
            else
            {
                vc.TitleName = "Shortcut instruction";
            }
            HDL_ON_iOS.AppDelegate.rootViewController.PushViewController(vc, true);
        }
        public void SetData(bool isLogin, string accessToken, string refreshToken, string regionUrl, string homeId)
        {
            var sDM = new SiriKit.SceneDateManager();
            sDM.IsLgoin = isLogin;
            sDM.AccessToken = accessToken;
            sDM.RefreshToken = refreshToken;
            sDM.RegionUrl = regionUrl;
            sDM.HomeId = homeId;
        }
    }
}
HDL-ON_iOS/Resources/Language.ini
@@ -500,6 +500,7 @@
512=Message push is not enabled, please go to settings.
513=Please enter the pairing code
514=Gateway location information is not configured
515=Add Security
 
1000=Room Humidity
1001=V-chip
@@ -1623,7 +1624,7 @@
512=消息推送未开启,请前往设置。
513=请输入配对码
514=未配置网关位置信息
515=添加安防
 
1000=室内湿度
1001=童锁
HDL-ON_iOS/Resources/Phone/PersonalCenter/SiriIcon.png
HDL_APP_Project.sln
@@ -10,6 +10,12 @@
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Blufi", "HdlBluWi\Blufi.csproj", "{2DDF4C3C-6998-432E-9F43-6786D82F0630}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SiriIntentsUI", "SiriIntentsUI\SiriIntentsUI.csproj", "{ACC48A7F-250B-4915-A250-9BC399DBD6B3}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SiriKit", "SiriKit\SiriKit.csproj", "{8B1652FA-5158-4D57-B90D-07BB91766625}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SiriIntents", "SiriIntents\SiriIntents.csproj", "{760980F5-1CD3-4F4F-9134-34D87BECD790}"
EndProject
Global
    GlobalSection(SharedMSBuildProjectFiles) = preSolution
        HDL_ON\HDL_ON.projitems*{09712674-2a38-407b-b1e2-560b2c352f9a}*SharedItemsImports = 4
@@ -63,6 +69,42 @@
        {2DDF4C3C-6998-432E-9F43-6786D82F0630}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
        {2DDF4C3C-6998-432E-9F43-6786D82F0630}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
        {2DDF4C3C-6998-432E-9F43-6786D82F0630}.Debug|Any CPU.Build.0 = Debug|Any CPU
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Debug|Any CPU.ActiveCfg = Debug|iPhone
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Debug|Any CPU.Build.0 = Debug|iPhone
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Debug|iPhone.ActiveCfg = Debug|iPhone
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Debug|iPhone.Build.0 = Debug|iPhone
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Debug|iPhoneSimulator.ActiveCfg = Debug|iPhoneSimulator
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Debug|iPhoneSimulator.Build.0 = Debug|iPhoneSimulator
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Release|Any CPU.ActiveCfg = Release|iPhoneSimulator
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Release|Any CPU.Build.0 = Release|iPhoneSimulator
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Release|iPhone.ActiveCfg = Release|iPhone
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Release|iPhone.Build.0 = Release|iPhone
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Release|iPhoneSimulator.ActiveCfg = Release|iPhoneSimulator
        {ACC48A7F-250B-4915-A250-9BC399DBD6B3}.Release|iPhoneSimulator.Build.0 = Release|iPhoneSimulator
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Debug|Any CPU.Build.0 = Debug|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Debug|iPhone.ActiveCfg = Debug|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Debug|iPhone.Build.0 = Debug|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Release|Any CPU.ActiveCfg = Release|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Release|Any CPU.Build.0 = Release|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Release|iPhone.ActiveCfg = Release|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Release|iPhone.Build.0 = Release|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
        {8B1652FA-5158-4D57-B90D-07BB91766625}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Debug|Any CPU.ActiveCfg = Debug|iPhone
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Debug|Any CPU.Build.0 = Debug|iPhone
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Debug|iPhone.ActiveCfg = Debug|iPhone
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Debug|iPhone.Build.0 = Debug|iPhone
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Debug|iPhoneSimulator.ActiveCfg = Debug|iPhoneSimulator
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Debug|iPhoneSimulator.Build.0 = Debug|iPhoneSimulator
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Release|Any CPU.ActiveCfg = Release|iPhoneSimulator
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Release|Any CPU.Build.0 = Release|iPhoneSimulator
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Release|iPhone.ActiveCfg = Release|iPhone
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Release|iPhone.Build.0 = Release|iPhone
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Release|iPhoneSimulator.ActiveCfg = Release|iPhoneSimulator
        {760980F5-1CD3-4F4F-9134-34D87BECD790}.Release|iPhoneSimulator.Build.0 = Release|iPhoneSimulator
    EndGlobalSection
    GlobalSection(SolutionProperties) = preSolution
        HideSolutionNode = FALSE
HDL_ON/Common/HDLCommon.cs
@@ -426,6 +426,10 @@
                    DB_ResidenceData.Instance.EixtAccount();
                    //4.注销HDLSIP账号登录 2021-08-20
                    HDLLinphone.Current.LogoutAllAccount();
#if __IOS__
                    //5.清空Siri共享数据信息
                    new Other.SkipControl().SetData(false, "", "", "","");
#endif
                }
                catch (Exception ex)
                {
@@ -483,6 +487,11 @@
                        }
                        MainPage.CurPageIndex = 9999;
                        MainPage.UserBasePage.ChooseCollection();
#if __IOS__
                        var sdm = new SiriKit.SceneDateManager();
                        sdm.RegionUrl = DB_ResidenceData.Instance.CurrentRegion.regionUrl;
                        sdm.HomeId = DB_ResidenceData.Instance.CurrentRegion.id;
#endif
                    }
                }
                //Dialog
@@ -522,9 +531,9 @@
        }
        #endregion
#endregion
        #region ■ 常用方法_______________________
#region ■ 常用方法_______________________
        /// <summary>
        /// 设置下划线按钮状态
        /// 统一封装设置方法
@@ -597,9 +606,9 @@
                Control.Ins.SearchLoaclGateway();
            }
        }
        #endregion
#endregion
        #region 跳转打开萤石云方法
#region 跳转打开萤石云方法
        /// <summary>
        /// 获取子账号token并跳转设备列表页面
@@ -701,6 +710,6 @@
            { IsBackground = true }.Start();
        }
        #endregion
#endregion
    }
}
HDL_ON/Common/R.cs
@@ -6,6 +6,10 @@
    {
        /// <summary>
        /// 添加安防
        /// </summary>
        public const int AddSecurity = 515;
        /// <summary>
        /// 未配置网关地址信息
        /// </summary>
        public const int GatewayLocationInformationIsNotConfigured = 514;
HDL_ON/DAL/Server/HttpServerRequest.cs
@@ -45,13 +45,13 @@
        /// <param name="deviceId">设备ID</param>
        /// <param name="deviceKey">功能查询类型:pm25</param>
        /// <returns></returns>
        public ResponsePackNew GetSensorHistory(string qType, string deviceId,string deviceKey)
        public ResponsePackNew GetSensorHistory(string qType, string deviceId, string deviceKey)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("type", qType);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId",  deviceId );
            d.Add("key",  deviceKey );
            d.Add("deviceId", deviceId);
            d.Add("key", deviceKey);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPost(NewAPI.Api_Post_EnvironmentalSensorHistoricalData, requestJson);
@@ -63,7 +63,7 @@
        /// <param name="pageSize">页面大小</param>
        /// <param name="pageNo">页号</param>
        /// <returns></returns>
        public ResponsePackNew GetArmSensorHistory( string deviceId,string pageSize, string pageNo)
        public ResponsePackNew GetArmSensorHistory(string deviceId, string pageSize, string pageNo)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
@@ -78,7 +78,7 @@
        /// 读取最近一个月的数据
        /// </summary>
        /// <returns></returns>
        public ResponsePackNew GetLastMonthHistory(string deviceId,string key)
        public ResponsePackNew GetLastMonthHistory(string deviceId, string key)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
@@ -146,6 +146,12 @@
                UserInfo.Current.RefreshToken = revertData.refreshToken;
                UserInfo.Current.LastTime = DateTime.Now;
                UserInfo.Current.SaveUserInfo();
#if __IOS__
                var sdm = new SiriKit.SceneDateManager();
                sdm.AccessToken = UserInfo.Current.LoginTokenString;
                sdm.RefreshToken = UserInfo.Current.RefreshToken;
#endif
            }
            return revertObj.Code;
        }
@@ -234,7 +240,19 @@
                account = account,
                loginPwd = password
            });
            return HttpUtil.RequestHttpsPost(NewAPI.API_POST_Login, requestJson);
            var pack = HttpUtil.RequestHttpsPost(NewAPI.API_POST_Login, requestJson);
            if (pack != null)
            {
                if (pack.Code == StateCode.SUCCESS)
                {
#if __IOS__
                    var sdm = new SiriKit.SceneDateManager();
                    sdm.IsLgoin = true;
#endif
                }
            }
            return pack;
        }
        /// <summary>
@@ -251,7 +269,19 @@
                verifyCode = vCode,
                grantType = "verify"
            });
            return HttpUtil.RequestHttpsPost(NewAPI.API_POST_Login, requestJson);
            var pack = HttpUtil.RequestHttpsPost(NewAPI.API_POST_Login, requestJson);
            if (pack != null)
            {
                if (pack.Code == StateCode.SUCCESS)
                {
#if __IOS__
                    var sdm = new SiriKit.SceneDateManager();
                    sdm.IsLgoin = true;
#endif
                }
            }
            return pack;
        }
        /// <summary>
@@ -264,7 +294,7 @@
        /// <returns></returns>
        public ResponsePackNew ValidataCodeAndRegister(string account, string password, string code, bool isPhone = false)
        {
            var requestObj = new RegisterObj() { loginPwd = password, verifyCode = code};//, memberName = account
            var requestObj = new RegisterObj() { loginPwd = password, verifyCode = code };//, memberName = account
            if (isPhone)
            {
                requestObj.memberPhone = account;
@@ -345,7 +375,7 @@
                UserInfo.Current.userEmailInfo = info.memberEmail;
                UserInfo.Current.userMobileInfo = info.memberPhone;
                UserInfo.Current.userName = info.memberName;
                if (!string.IsNullOrEmpty(info.memberPhonePrefix))
                {
                    UserInfo.Current.areaCode = info.memberPhonePrefix;
@@ -482,7 +512,7 @@
        /// <summary>
        /// 获取住宅列表
        /// </summary>
        public string GetHomePager(HomeTypeEnum homeType = HomeTypeEnum.ALL,string homeId = "")
        public string GetHomePager(HomeTypeEnum homeType = HomeTypeEnum.ALL, string homeId = "")
        {
            var requestJson = HttpUtil.GetSignRequestJson(new GetHomeListObj() { homeType = homeType.ToString() });
            var resultObj = HttpUtil.RequestHttpsPost(NewAPI.API_POST_Gethomepager, requestJson);
@@ -510,7 +540,7 @@
                            }
                        }
                    }
                    if(UserInfo.Current.regionList.Count== 0)
                    if (UserInfo.Current.regionList.Count == 0)
                    {
                        return "null";
                    }
@@ -553,6 +583,12 @@
                            GetHomeGatewayList();
                        }
                    }
#if __IOS__
                    var sdm = new SiriKit.SceneDateManager();
                    sdm.RegionUrl = DB_ResidenceData.Instance.CurrentRegion.regionUrl;
                    sdm.HomeId = DB_ResidenceData.Instance.CurrentRegion.id;
#endif
                }
            }
@@ -785,7 +821,7 @@
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_Share_GetList, requestJson);
        }
        #endregion
        ///// <summary>
@@ -934,7 +970,7 @@
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("debugPerm", debugPerm);
            var jsonString = HttpUtil.GetSignRequestJson(d,d);
            var jsonString = HttpUtil.GetSignRequestJson(d, d);
            var pack = HttpUtil.RequestHttpsPost(NewAPI.API_Post_Home_UpdateDebugPerm, jsonString);
            return pack;
        }
@@ -993,7 +1029,8 @@
                isProduce = false;
#endif
                if (string.IsNullOrEmpty(OnAppConfig.Instance.PushDeviceToken)) {
                if (string.IsNullOrEmpty(OnAppConfig.Instance.PushDeviceToken))
                {
                    Utlis.WriteLine("PushDeviceToken 为空");
                    return false;
                }
@@ -1004,7 +1041,7 @@
                    deviceName = OnAppConfig.Instance.PhoneName,
                    deviceType = deviceType,
                    produce = isProduce,
                };
                mAddpushinfoObj.languageType = Utlis.GetPostLanguageType();
@@ -1027,11 +1064,11 @@
                            OnAppConfig.Instance.PushId = pushId;
                            OnAppConfig.Instance.SaveConfig();
                            Utlis.WriteLine("PushId: " + pushId);
                            return true;
                        }
                    }
                }
                else
                {
@@ -1115,10 +1152,11 @@
            if (string.IsNullOrEmpty(OnAppConfig.Instance.PushId)) return false;
            try
            {
                var requestJson = HttpUtil.GetSignRequestJson(new PushIdObj() {
                var requestJson = HttpUtil.GetSignRequestJson(new PushIdObj()
                {
                    pushId = OnAppConfig.Instance.PushId
                });
                var revertObj = HttpUtil.RequestHttpsPost(NewAPI.API_POST_PushSerivce_DeleteToken, requestJson);
                if (revertObj.Code == StateCode.SUCCESS)
                {
@@ -1303,9 +1341,9 @@
#endregion
        #endregion
#region 获取天气部分
        #region 获取天气部分
        /// <summary>
        /// 获取指定经纬度的城市信息天气信息
        /// </summary>
@@ -1426,10 +1464,10 @@
        //}
#endregion
        #endregion
#region 备份部分
        #region 备份部分
        ///// <summary>
        ///// 获取住宅备份列表
        ///// </summary>
@@ -1900,10 +1938,10 @@
        }
        */
#endregion
        #endregion
#region Kaede --设备功能——————————————————————————————————
        #region Kaede --设备功能——————————————————————————————————
        /// <summary>
        /// 获取设备列表
        /// </summary>
@@ -1947,14 +1985,14 @@
        /// <param name="productPlatform"></param>
        /// <param name="productBrand"></param>
        /// <returns></returns>
        public ResponsePackNew Get3TyBrandDeviceList(string productPlatform,string productBrand)
        public ResponsePackNew Get3TyBrandDeviceList(string productPlatform, string productBrand)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("categoryType", 1);
            d.Add("productPlatform", productPlatform);
            d.Add("productBrand", productBrand);
            d.Add("networkConfig", true);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_Get3tyBrandDevcieList, requestJson);
        }
@@ -1964,7 +2002,7 @@
        /// <param name="productPlatform"></param>
        /// <param name="productBrand"></param>
        /// <returns></returns>
        public ResponsePackNew IndependentRegister3TyDevcie(string spk,string extDevId,string deviceName,string pairCode = "")
        public ResponsePackNew IndependentRegister3TyDevcie(string spk, string extDevId, string deviceName, string pairCode = "")
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
@@ -2074,7 +2112,7 @@
        /// <summary>
        /// 设备绑定房间
        /// </summary>
        public ResponsePackNew BindDeviceToRoom(List<string> deviceIds,List<string> roomIds)
        public ResponsePackNew BindDeviceToRoom(List<string> deviceIds, List<string> roomIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
@@ -2117,7 +2155,7 @@
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceIds",new List<string>() { deviceId });
            d.Add("deviceIds", new List<string>() { deviceId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_CollectDevice, requestJson);
@@ -2135,9 +2173,9 @@
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_CancelCollectDevice, requestJson);
        }
#endregion
        #endregion
#region Kaede --场景功能--------------------------
        #region Kaede --场景功能--------------------------
        /// <summary>
        /// 获取场景列表
        /// 房间ID可空,默认查询住宅下所有房间
@@ -2164,7 +2202,7 @@
        public ResponsePackNew GetSceneInfo(string seceneId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("userSceneIds",new List<string>() { seceneId });
            d.Add("userSceneIds", new List<string>() { seceneId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetSecneInfo, requestJson);
@@ -2269,9 +2307,9 @@
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_CancelCollectScene, requestJson).Code;
        }
#endregion
        #endregion
#region Kaede --房间功能--------------------------
        #region Kaede --房间功能--------------------------
        /// <summary>
        /// 获取房间列表
        /// </summary>
@@ -2288,7 +2326,7 @@
            d.Add("pageSize", "1000");
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetRoomList, requestJson);
            return pack;
        }
        /// <summary>
@@ -2346,10 +2384,10 @@
            return pack;
        }
#endregion
        #endregion
#region Kaede -- 安防接口____________________________
        #region Kaede -- 安防接口____________________________
        /// <summary>
        /// 获取安防列表
        /// </summary>
@@ -2489,7 +2527,7 @@
        /// <summary>
        /// 查询安防所有记录
        /// </summary>
        public ResponsePackNew GetSecurityLogList(string pageSize,string pageNo)
        public ResponsePackNew GetSecurityLogList(string pageSize, string pageNo)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
@@ -2513,10 +2551,10 @@
            return pack;
        }
#endregion
        #endregion
#region Kaede --第三方品牌功能--------------------------
        #region Kaede --第三方品牌功能--------------------------
        /// <summary>
        /// 获取第三方品牌列表
        /// </summary>
@@ -2541,9 +2579,9 @@
            return pack;
        }
#endregion
        #endregion
#region ■ 萤石云SDK相关接口_________________________
        #region ■ 萤石云SDK相关接口_________________________
        /// <summary>
        /// 河东获取萤石云子账号token的接口
        /// 2021-07-07 新方案接口调整对接
@@ -2569,7 +2607,7 @@
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome( NewAPI.API_POST_FL_Check, requestJson);
            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_FL_Check, requestJson);
            return pack;
        }
        #endregion
@@ -2731,7 +2769,7 @@
        public ResponsePackNew FaceSetting(string imageBytes)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("userFace", @"data:image/jpg;base64,"+imageBytes);
            d.Add("userFace", @"data:image/jpg;base64," + imageBytes);
            d.Add("houseId", DB_ResidenceData.Instance.CurrentRegion.id);
            //MainPage.Log(imageBytes);
HDL_ON/DAL/Server/HttpUtil.cs
@@ -299,6 +299,11 @@
                    UserInfo.Current.LastTime = DateTime.Now;
                    UserInfo.Current.SaveUserInfo();
                    return true;
#if __IOS__
                    var sdm = new SiriKit.SceneDateManager();
                    sdm.AccessToken = UserInfo.Current.LoginTokenString;
                    sdm.RefreshToken = UserInfo.Current.RefreshToken;
#endif
                }
                return false;
            }
HDL_ON/Entity/Function/SecurityAlarm.cs
@@ -13,11 +13,7 @@
    {
        public SecurityAlarm()
        {
            pushConfigs.Add(new SecurityPushConfig()
            {
                pushMethod = "APP",
                pushTarget = new List<string>() { UserInfo.Current.ID }
            });
        }
        /// <summary>
@@ -35,7 +31,7 @@
        /// <summary>
        /// 安防延时
        /// </summary>
        public string delay;
        public string delay ="0";
        /// <summary>
        /// 状态
        /// 布防:enable
@@ -94,6 +90,17 @@
            var ssd = System.Text.Encoding.UTF8.GetBytes(Newtonsoft.Json.JsonConvert.SerializeObject(this));
            FileUtlis.Files.WriteFileByBytes(savePath, ssd);
        }
        /// <summary>
        /// 刷新本地数据
        /// </summary>
        /// <returns></returns>
        public SecurityAlarm RefeshData()
        {
            var dataBytes = FileUtlis.Files.ReadFile(savePath);
            var dataString = System.Text.Encoding.UTF8.GetString(dataBytes);
            var temp = Newtonsoft.Json.JsonConvert.DeserializeObject<SecurityAlarm>(dataString);
            return temp;
        }
        /// <summary>
        /// 保存安防信息
@@ -101,8 +108,22 @@
        public string SaveInfo()
        {
            HttpServerRequest hsr = new HttpServerRequest();
            this.noticeConfig.enable = true;
            this.noticeConfig.noticeContent = Language.StringByID(StringId.SecurityAlarmTipString).Replace("{0}", name);
            if (string.IsNullOrEmpty(this.noticeConfig.noticeContent))
            {
                this.noticeConfig.noticeContent = Language.StringByID(StringId.SecurityAlarmTipString).Replace("{0}", name);
            }
            if (this.noticeConfig.enable)
            {
                if (this.pushConfigs.Count == 0)
                {
                    pushConfigs.Add(new SecurityPushConfig()
                    {
                        pushMethod = "APP",
                        pushTarget = new List<string>() { UserInfo.Current.ID }
                    });
                }
            }
            if (string.IsNullOrEmpty(sid))
            {
                NewSid();
@@ -260,16 +281,16 @@
        public List<SecurityInputCondition> condition = new List<SecurityInputCondition>();
        /// <summary>
        /// 判断条件
        /// </summary>
        public string comparator = "=";
        /// <summary>
        /// 加入输入条件
        /// 本地判断使用
        /// </summary>
        [Newtonsoft.Json.JsonIgnore]
        public bool addCondition = false;
        //[Newtonsoft.Json.JsonIgnore]
        //public bool addCondition = false;
        /// <summary>
        /// 判断条件
        /// </summary>
        public string comparator = "=";
        [Newtonsoft.Json.JsonIgnore]
        Function _function = null;
@@ -459,12 +480,18 @@
        /// </summary>
        public List<SecurityOutputStatus> status = new List<SecurityOutputStatus>();
        /// <summary>
        /// 加入输入条件
        /// 本地判断使用
        /// </summary>
        //[Newtonsoft.Json.JsonIgnore]
        //public bool addCondition = false;
        [Newtonsoft.Json.JsonIgnore]
        public bool addCondition = false;
        public string name = "";
        [Newtonsoft.Json.JsonIgnore]
        public string RoomName = "";
        [Newtonsoft.Json.JsonIgnore]
        Function _function = null;
@@ -515,7 +542,7 @@
                }
            }else if(target_type == "1")
            {
                text = Language.StringByID(StringId.Open);
            }
            return text;
@@ -539,7 +566,7 @@
        /// <summary>
        /// 是否开启通知
        /// </summary>
        public bool enable;
        public bool enable = true;
        /// <summary>
        /// 通知内容
        /// </summary>
HDL_ON/HDL_ON.projitems
@@ -487,6 +487,7 @@
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\EnvironmentalScience\A_EnvironmentalDataCenter.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\2-Classification\SceneControlZone.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\3-Intelligence\Automation\CalculatedDistance.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\ArmCenter\PushConfigPage.cs" />
  </ItemGroup>
  <ItemGroup>
    <Folder Include="$(MSBuildThisFileDirectory)Entity\Device\" />
HDL_ON/UI/UI1-Login/LoginPage.cs
@@ -198,6 +198,7 @@
            bool b = false;
            btnIcon.MouseUpEventHandler += (sender, e) =>
            {
                //ESOnVideo.Current.Test(false);
                //return;
@@ -211,7 +212,7 @@
                    etAccount.Text = "13226233133";//豆豆
                    etAccount.Text = "18316672920";
                    //etAccount.Text = "18316120654";//tujie
                    //etAccount.Text = "15626203746";
                    etAccount.Text = "15626203746";
                    //etAccount.Text = "13450425807";//黄竹溪 knx项目
                }
                else
@@ -230,15 +231,15 @@
                    //etAccount.Text = "15217626103";//昆明金茂项目
                    //etAccount.Text = "18598273624";
                    //etAccount.Text = "tf@smarttech.com.ua";
                    etAccount.Text = "18814122445";//董泽斌 天河办公室
                    //etAccount.Text = "18824864143";//"464027401@qq.com"; //"2791308028@qq.com";//13697499568
                    etAccount.Text = "18402017839";//wjc
                    //etAccount.Text = "18814122445";//董泽斌 天河办公室
                    etAccount.Text = "18824864143";//"464027401@qq.com"; //"2791308028@qq.com";//13697499568
                    //etAccount.Text = "18402017839";//wjc
                    //etAccount.Text = "13430286286";//cwc
                    //etAccount.Text = "13709260805";
                    //etAccount.Text = "support5@hdlchina.com.cn";
                    //etAccount.Text = "13375012441";
                    etAccount.Text = "info@smartlife-ks.com";
                    etAccount.Text = "551775569@qq.com";//wcf
                    //etAccount.Text = "info@smartlife-ks.com";
                    //etAccount.Text = "551775569@qq.com";//wcf
                }
                b = !b;
                etPassword.Text = "123456";
HDL_ON/UI/UI1-Login/LoginPageBLL.cs
@@ -726,6 +726,12 @@
                //UserInfo.Current.CurrentRegion.RegionID = "";
                UserInfo.Current.SaveUserInfo();
                MainPage.Log("登录成功。");
#if __IOS__
                var sdm = new SiriKit.SceneDateManager();
                sdm.AccessToken = UserInfo.Current.LoginTokenString;
                sdm.RefreshToken = UserInfo.Current.RefreshToken;
#endif
                result = true;
                //获取用户信息
                new Thread(() =>
HDL_ON/UI/UI2/3-Intelligence/Automation/LogicView/LogicTypeTitleView.cs
@@ -65,16 +65,21 @@
        /// View的方法
        /// </summary>
        /// <returns></returns>
        public FrameLayout FLayoutView()
        public FrameLayout FLayoutView(bool hadLine = true)
        {
            btnText.TextAlignment = TextAlignment.CenterLeft;
            btnNextIcon.Gravity = Gravity.CenterVertical;
            frameLayout.AddChidren(btnText);
            frameLayout.AddChidren(btnNextIcon);
            btnLine.Y = frameLayout.Height - 1;
            frameLayout.AddChidren(btnLine);
            if (hadLine)
            {
                btnLine.Y = frameLayout.Height - 1;
                frameLayout.AddChidren(btnLine);
            }
            frameLayout.AddChidren(btnClick);
            return frameLayout;
        }
    }
}
HDL_ON/UI/UI2/3-Intelligence/IntelligencePage.cs
@@ -15,6 +15,13 @@
        /// </summary>
        PageLayout contentPageView;
        Button btnAutomationTitle;
        #region 安防区域
        FrameLayout securityView;
        Button btnSecurityTitle;
        #endregion
        #region 场景区域
        FrameLayout scenePageView;
        /// <summary>
@@ -76,51 +83,139 @@
            //判断是否需要隐藏自动化
            if (HideAutoPage)
            {
                btnSceneTilte = new Button()
                if (DB_ResidenceData.Instance.GatewayType == 1)//网关需要加载安防--2021-11-28 19:56:53  刘晓辉将安防放入改界面
                {
                    Y = Application.GetRealHeight(30),
                    //Width = Application.GetRealWidth(170),
                    Height = Application.GetRealHeight(25),
                    TextAlignment = TextAlignment.Center,
                    TextSize = CSS_FontSize.HeadlineFontSize,
                    TextColor = CSS_Color.PromptingColor1,
                    SelectedTextColor = CSS_Color.MainColor,
                    TextID = StringId.Scenes,
                    IsSelected = true
                };
                topView.AddChidren(btnSceneTilte);
                btnAutomationTitle = new Button();
                    btnSceneTilte  = new Button()
                    {
                        Y = Application.GetRealHeight(30),
                        Width = Application.GetRealWidth(170),
                        Height = Application.GetRealHeight(25),
                        TextAlignment = TextAlignment.CenterRight,
                        TextSize = CSS_FontSize.HeadlineFontSize,
                        TextColor = CSS_Color.PromptingColor1,
                        SelectedTextColor = CSS_Color.MainColor,
                        TextID = StringId.Scenes,
                        IsSelected = true
                    };
                    topView.AddChidren(btnSceneTilte);
                    btnSecurityTitle = new Button()
                    {
                        X = Application.GetRealWidth(209),
                        Y = Application.GetRealHeight(30),
                        Width = Application.GetRealWidth(170),
                        Height = Application.GetRealHeight(25),
                        TextAlignment = TextAlignment.CenterLeft,
                        TextSize = CSS_FontSize.TextFontSize,
                        TextColor = CSS_Color.PromptingColor1,
                        SelectedTextColor = CSS_Color.MainColor,
                        TextID = StringId.SecurityCenter,
                    };
                    topView.AddChidren(btnSecurityTitle);
                    btnAutomationTitle = new Button();
                }
                else
                {
                    btnSceneTilte = new Button()
                    {
                        Y = Application.GetRealHeight(30),
                        //Width = Application.GetRealWidth(170),
                        Height = Application.GetRealHeight(25),
                        TextAlignment = TextAlignment.Center,
                        TextSize = CSS_FontSize.HeadlineFontSize,
                        TextColor = CSS_Color.PromptingColor1,
                        SelectedTextColor = CSS_Color.MainColor,
                        TextID = StringId.Scenes,
                        IsSelected = true
                    };
                    topView.AddChidren(btnSceneTilte);
                    btnAutomationTitle = new Button();
                }
            }
            else
            {
                btnSceneTilte = new Button()
                if (DB_ResidenceData.Instance.GatewayType == 1)//网关需要加载安防--2021-11-28 19:56:53  刘晓辉将安防放入改界面
                {
                    Y = Application.GetRealHeight(30),
                    Width = Application.GetRealWidth(170),
                    Height = Application.GetRealHeight(25),
                    TextAlignment = TextAlignment.CenterRight,
                    TextSize = CSS_FontSize.HeadlineFontSize,
                    TextColor = CSS_Color.PromptingColor1,
                    SelectedTextColor = CSS_Color.MainColor,
                    TextID = StringId.Scenes,
                    IsSelected = true
                };
                topView.AddChidren(btnSceneTilte);
                    btnAutomationTitle   = new Button()
                    {
                        Y = Application.GetRealHeight(30),
                        Gravity = Gravity.CenterHorizontal,
                        Height = Application.GetRealHeight(25),
                        TextAlignment = TextAlignment.Center,
                        TextSize = CSS_FontSize.TextFontSize,
                        TextColor = CSS_Color.PromptingColor1,
                        SelectedTextColor = CSS_Color.MainColor,
                        TextID = StringId.Automation,
                        IsSelected = false
                    };
                    topView.AddChidren(btnAutomationTitle);
                    btnAutomationTitle.Width = btnAutomationTitle.GetTextWidth() + Application.GetRealWidth(40);
                btnAutomationTitle = new Button()
                    var otherWidth = (Application.GetRealWidth(375) - btnAutomationTitle.Width) / 2;
                    btnAutomationTitle.X = otherWidth;
                    btnSceneTilte = new Button()
                    {
                        Y = Application.GetRealHeight(30),
                        Width = otherWidth,
                        Height = Application.GetRealHeight(25),
                        TextAlignment = TextAlignment.CenterRight,
                        TextSize = CSS_FontSize.HeadlineFontSize,
                        TextColor = CSS_Color.PromptingColor1,
                        SelectedTextColor = CSS_Color.MainColor,
                        TextID = StringId.Scenes,
                        IsSelected =true
                    };
                    topView.AddChidren(btnSceneTilte);
                    btnSecurityTitle = new Button()
                    {
                        X = btnAutomationTitle.Right,
                        Y = Application.GetRealHeight(30),
                        Width = otherWidth,
                        Height = Application.GetRealHeight(25),
                        TextAlignment = TextAlignment.CenterLeft,
                        TextSize = CSS_FontSize.TextFontSize,
                        TextColor = CSS_Color.PromptingColor1,
                        SelectedTextColor = CSS_Color.MainColor,
                        TextID = StringId.SecurityCenter,
                    };
                    topView.AddChidren(btnSecurityTitle);
                }
                else
                {
                    X = Application.GetRealWidth(209),
                    Y = Application.GetRealHeight(30),
                    Width = Application.GetRealWidth(170),
                    Height = Application.GetRealHeight(25),
                    TextAlignment = TextAlignment.CenterLeft,
                    TextSize = CSS_FontSize.TextFontSize,
                    TextColor = CSS_Color.PromptingColor1,
                    SelectedTextColor = CSS_Color.MainColor,
                    TextID = StringId.Automation,
                };
                topView.AddChidren(btnAutomationTitle);
                    btnSceneTilte = new Button()
                    {
                        Y = Application.GetRealHeight(30),
                        Width = Application.GetRealWidth(170),
                        Height = Application.GetRealHeight(25),
                        TextAlignment = TextAlignment.CenterRight,
                        TextSize = CSS_FontSize.HeadlineFontSize,
                        TextColor = CSS_Color.PromptingColor1,
                        SelectedTextColor = CSS_Color.MainColor,
                        TextID = StringId.Scenes,
                        IsSelected = true
                    };
                    topView.AddChidren(btnSceneTilte);
                    btnAutomationTitle = new Button()
                    {
                        X = Application.GetRealWidth(209),
                        Y = Application.GetRealHeight(30),
                        Width = Application.GetRealWidth(170),
                        Height = Application.GetRealHeight(25),
                        TextAlignment = TextAlignment.CenterLeft,
                        TextSize = CSS_FontSize.TextFontSize,
                        TextColor = CSS_Color.PromptingColor1,
                        SelectedTextColor = CSS_Color.MainColor,
                        TextID = StringId.Automation,
                    };
                    topView.AddChidren(btnAutomationTitle);
                }
            }
            var btnAddIconBg = new Button()
            {
@@ -155,9 +250,28 @@
            {
                LoadAutomationPageView();
            }
            LoadSecurityPageView();
            LoadEventList();
        }
        #region 安防布防
        /// <summary>
        /// 加载安防界面
        /// </summary>
        void LoadSecurityPageView()
        {
            securityView = new FrameLayout();
            contentPageView.AddChidren(securityView);
            var page = new ArmCenterPage();
            securityView.AddChidren(page);
            page.LoadPage(false);
        }
        #endregion
        #region 场景部分
        /// <summary>
        /// 加载场景列表界面
@@ -321,7 +435,6 @@
        /// <summary>
        /// 加载场景控制卡片
        /// </summary>
        //FrameLayout LoadSceneFunctionDiv(FrameLayout view, Scene scene)
        FrameLayout LoadSceneFunctionDiv(int functionView_X, Scene scene)
        {
            var view = new FrameLayout()
@@ -482,8 +595,23 @@
        {
            contentPageView.PageChange = (sender, e) =>
            {
                if (contentPageView.PageIndex == 0)
                if (contentPageView.PageIndex == 2)
                {
                    btnSecurityTitle.IsSelected = true;
                    btnSecurityTitle.TextSize = CSS_FontSize.HeadlineFontSize;
                    btnSecurityTitle.IsBold = true;
                    btnSceneTilte.IsSelected = false;
                    btnSceneTilte.TextSize = CSS_FontSize.TextFontSize;
                    btnSceneTilte.IsBold = false;
                    btnAutomationTitle.IsSelected = false;
                    btnAutomationTitle.TextSize = CSS_FontSize.TextFontSize;
                    btnAutomationTitle.IsBold = false;
                }
                else if (contentPageView.PageIndex == 0)
                {
                    btnSecurityTitle.IsSelected = false;
                    btnSecurityTitle.TextSize = CSS_FontSize.TextFontSize;
                    btnSecurityTitle.IsBold = false;
                    btnSceneTilte.IsSelected = true;
                    btnSceneTilte.TextSize = CSS_FontSize.HeadlineFontSize;
                    btnSceneTilte.IsBold = true;
@@ -493,6 +621,9 @@
                }
                else
                {
                    btnSecurityTitle.IsSelected = false;
                    btnSecurityTitle.TextSize = CSS_FontSize.TextFontSize;
                    btnSecurityTitle.IsBold = false;
                    btnAutomationTitle.IsSelected = true;
                    btnAutomationTitle.TextSize = CSS_FontSize.HeadlineFontSize;
                    btnAutomationTitle.IsBold = true;
@@ -508,6 +639,8 @@
                {
                    return;
                }
                btnSecurityTitle.IsSelected = false;
                btnSecurityTitle.TextSize = CSS_FontSize.TextFontSize;
                btnSceneTilte.IsSelected = true;
                btnSceneTilte.TextSize = CSS_FontSize.HeadlineFontSize;
                btnAutomationTitle.IsSelected = false;
@@ -520,12 +653,26 @@
                {
                    return;
                }
                btnSecurityTitle.IsSelected = false;
                btnSecurityTitle.TextSize = CSS_FontSize.TextFontSize;
                btnAutomationTitle.IsSelected = true;
                btnAutomationTitle.TextSize = CSS_FontSize.HeadlineFontSize;
                btnSceneTilte.IsSelected = false;
                btnSceneTilte.TextSize = CSS_FontSize.TextFontSize;
                contentPageView.PageIndex = 1;
            };
            btnSecurityTitle.MouseUpEventHandler = (sender, e) => {
                if(btnSecurityTitle.IsSelected )
                {
                    return;
                }
                btnSecurityTitle.IsSelected = true;
                btnSecurityTitle.TextSize = CSS_FontSize.HeadlineFontSize;
                btnAutomationTitle.IsSelected = false;
                btnAutomationTitle.TextSize = CSS_FontSize.TextFontSize;
                btnSceneTilte.IsSelected = false;
                btnSceneTilte.TextSize = CSS_FontSize.TextFontSize;
                contentPageView.PageIndex = 2;
            };
        }
        #endregion
HDL_ON/UI/UI2/3-Intelligence/Scene/SceneEditPage.cs
@@ -284,11 +284,6 @@
                        btnSceneDelayInfo.Text = scene.GetDelayText();
                        scene.EditScene();
                    };
                    Dictionary<string, string> items = new Dictionary<string, string>();
                    items.Add("30", "30s");
                    items.Add("60", "1min");
                    items.Add("120", "2min");
                    items.Add("300", "5min");
                    new PublicAssmebly().SetSceneDelayDialog(action,scene.delay);
                };
@@ -484,7 +479,7 @@
                };
                row.AddChidren(btnFunctionDelayInfo);
                if (Convert.ToInt32( scenefunction.delay) > 0)
                if (!string.IsNullOrEmpty(scenefunction.delay) && Convert.ToInt32( scenefunction.delay) > 0)
                {
                    btnFunctionDelayInfo.Text = Language.StringByID(StringId.Delay) + " " + new Scene() { delay = scenefunction.delay }.GetDelayText();
                }
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs
@@ -152,6 +152,10 @@
        /// 智能音箱文本
        /// </summary>
        Button btnSmartSpeakerText;
        /// <summary>
        /// Siri文本
        /// </summary>
        Button btnSiriText;
        public PersonalCenterPage()
@@ -791,12 +795,13 @@
            contentView.AddChidren(supportView);
            int supportViewCellCount = 1;
            #region 智能音箱
            if (!DB_ResidenceData.Instance.CurrentRegion.isOtherShare)
            {
                supportViewCellCount++;
                //supportView 加高 显示3行 3*44
                supportView.Height = Application.GetRealWidth(2*44);
                supportView.Height = Application.GetRealWidth(supportViewCellCount * 44);
                FrameLayout smartSpeakerView = new FrameLayout()
                {
@@ -850,6 +855,79 @@
            #endregion
            #region Siri
            #if __IOS__
            //if (Application.PhoneType >= 12)
            {
                supportViewCellCount++;
                //supportView 加高 显示3行 3*44
                supportView.Height = Application.GetRealWidth(supportViewCellCount * 44);
                FrameLayout siriView = new FrameLayout()
                {
                    Height = Application.GetRealWidth(44),
                };
                supportView.AddChidren(siriView);
                //住宅为当前账号才显示智能音箱入口
                Button btnSiriIcon = new Button()
                {
                    X = Application.GetRealWidth(12),
                    Y = Application.GetRealWidth(10),
                    Width = Application.GetMinRealAverage(24),
                    Height = Application.GetMinRealAverage(24),
                    UnSelectedImagePath = "PersonalCenter/SiriIcon.png",
                };
                siriView.AddChidren(btnSiriIcon);
                btnSiriText = new Button()
                {
                    X = Application.GetRealWidth(48),
                    Width = Application.GetRealWidth(270),
                    Height = Application.GetRealWidth(44),
                    TextColor = CSS_Color.FirstLevelTitleColor,
                    TextAlignment = TextAlignment.CenterLeft,
                    TextSize = CSS_FontSize.TextFontSize
                };
                if(Language.CurrentLanguage == "Chinese")
                {
                    btnSiriText.Text = "Siri快捷方式";
                }else
                {
                    btnSiriText.Text = "Siri Shortcut";
                }
                siriView.AddChidren(btnSiriText);
                btnSiriText.MouseUpEventHandler = (sender, e) => {
                    var ddd =new Other.SkipControl();
                    ddd.SkipSiriView();
                };
                Button btnSiriRight = new Button()
                {
                    X = Application.GetRealWidth(315),
                    Y = Application.GetRealWidth(14),
                    Width = Application.GetMinRealAverage(16),
                    Height = Application.GetMinRealAverage(16),
                    UnSelectedImagePath = "Public/Right.png",
                };
                siriView.AddChidren(btnSiriRight);
                var btnSmartSpeakerViewLine = new Button()
                {
                    X = Application.GetRealWidth(48),
                    Y = Application.GetRealWidth(43),
                    Height = Application.GetRealHeight(1),
                    Width = Application.GetRealWidth(279),
                    BackgroundColor = CSS_Color.DividingLineColor
                };
                siriView.AddChidren(btnSmartSpeakerViewLine);
            }
            #endif
            #endregion
            #region 获取支持
            //FrameLayout supView = new FrameLayout()
            //{
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPageBLL.cs
@@ -251,6 +251,11 @@
            DB_ResidenceData.Instance.EixtAccount();
            //刷新住宅数据
            Common.ApiUtlis.Ins.DownloadData();
#if __IOS__
            var sdm = new SiriKit.SceneDateManager();
            sdm.RegionUrl = DB_ResidenceData.Instance.CurrentRegion.regionUrl;
            sdm.HomeId = DB_ResidenceData.Instance.CurrentRegion.id;
#endif
        }
        #endregion
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/Transfer/TransferingResidencePage.cs
@@ -3,6 +3,7 @@
using HDL_ON.UI.CSS;
using HDL_ON.Stan;
using System.Collections.Generic;
using HDL_ON.Entity;
namespace HDL_ON.UI
{
@@ -228,8 +229,8 @@
                        }
                        else
                        {
                            Entity.DB_ResidenceData.Instance.CurrentRegion = UserInfo.Current.regionList[0];
                            Entity.DB_ResidenceData.Instance.SaveResidenceData();
                            DB_ResidenceData.Instance.CurrentRegion = UserInfo.Current.regionList[0];
                            DB_ResidenceData.Instance.SaveResidenceData();
                            //刷新住宅数据
                            Common.ApiUtlis.Ins.DownloadData();
@@ -241,6 +242,11 @@
                                MainPage.CurPageIndex = 1;
                                userPage.ChoosePersonalCenter();
                            }
#if __IOS__
                            var sdm = new SiriKit.SceneDateManager();
                            sdm.RegionUrl = DB_ResidenceData.Instance.CurrentRegion.regionUrl;
                            sdm.HomeId = DB_ResidenceData.Instance.CurrentRegion.id;
#endif
                        }
                    }
                };
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddAlarmDeploymentPage.cs
@@ -26,6 +26,16 @@
        SecurityAlarm securityAlarm;
        Action refreshAction;
        /// <summary>
        /// 安防输出-临时
        /// </summary>
        List<SecurityOutput> tempOutput = new List<SecurityOutput>();
        /// <summary>
        /// 安防输入-临时
        /// </summary>
        List<SecurityInput> tempInput = new List<SecurityInput>();
        public AddAlarmDeploymentPage(SecurityAlarm alarm, Action action)
        {
            bodyView = this;
@@ -33,10 +43,8 @@
            refreshAction = action;
        }
        public void LoadPage()
        public void LoadPage(string title = "")
        {
            new TopViewDiv(bodyView, Language.StringByID(StringId.Setting)).LoadTopView();
            bodyView.BackgroundColor = CSS_Color.BackgroundColor;
            contentView = new VerticalScrolViewLayout()
@@ -46,95 +54,202 @@
            };
            bodyView.AddChidren(contentView);
            #region 布防信息
            var deploymentTitleRow = new FrameLayout()
            if (string.IsNullOrEmpty(title))
            {
                Height = Application.GetRealHeight(44),
                new TopViewDiv(bodyView, Language.StringByID(StringId.AddSecurity)).LoadTopView();
                #region 布防信息
                var deploymentTitleRow = new FrameLayout()
                {
                    Height = Application.GetRealHeight(44),
                    BackgroundColor = CSS_Color.MainBackgroundColor,
                };
                contentView.AddChidren(deploymentTitleRow);
                var btnDeploymentTitle = new Button()
                {
                    X = Application.GetRealWidth(16),
                    TextColor = CSS_Color.MainColor,
                    TextAlignment = TextAlignment.CenterLeft,
                    TextSize = CSS_FontSize.SubheadingFontSize,
                    TextID = StringId.DeploymentInformation,
                    IsBold = true,
                };
                deploymentTitleRow.AddChidren(btnDeploymentTitle);
                deploymentTitleRow.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(43), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
                #region 布防名称
                var deploymentNameRow = new FrameLayout()
                {
                    Height = Application.GetRealHeight(50),
                    BackgroundColor = CSS_Color.MainBackgroundColor,
                };
                contentView.AddChidren(deploymentNameRow);
                var btnDeploymentNameTitle = new Button()
                {
                    X = Application.GetRealWidth(16),
                    Width = Application.GetRealWidth(72),
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.FirstLevelTitleColor,
                    TextSize = CSS_FontSize.TextFontSize,
                    TextID = StringId.Name,
                };
                deploymentNameRow.AddChidren(btnDeploymentNameTitle);
                btnDeploymentNameTitle.Text += ":";
                var btnDeploymentName = new Button()
                {
                    X = Application.GetRealWidth(88),
                    Width = Application.GetRealWidth(230),
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.TextualColor,
                    TextSize = CSS_FontSize.TextFontSize,
                    Text = securityAlarm.name
                };
                deploymentNameRow.AddChidren(btnDeploymentName);
                deploymentNameRow.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(49), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
                LoadEvent_EditSecurityAlarmName(btnDeploymentName);
                #endregion
                #region 触发延时
                var delayedRow = new FrameLayout()
                {
                    Height = Application.GetRealHeight(50),
                    BackgroundColor = CSS_Color.MainBackgroundColor,
                };
                contentView.AddChidren(delayedRow);
                var btnDelayedTitle = new Button()
                {
                    X = Application.GetRealWidth(16),
                    Width = Application.GetRealWidth(72),
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.FirstLevelTitleColor,
                    TextSize = CSS_FontSize.TextFontSize,
                    TextID = StringId.TriggerDelay,
                };
                delayedRow.AddChidren(btnDelayedTitle);
                btnDelayedTitle.Text += ":";
                var btnDelayedText = new Button()
                {
                    X = Application.GetRealWidth(88),
                    Width = Application.GetRealWidth(330),
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.TextualColor,
                    TextSize = CSS_FontSize.TextFontSize,
                    Text = securityAlarm.delay + "s"
                };
                delayedRow.AddChidren(btnDelayedText);
                btnDelayedText.MouseUpEventHandler = (sender, e) =>
                {
                    Action<string> action = (obj) =>
                    {
                        securityAlarm.delay = obj;
                        btnDelayedText.Text = securityAlarm.delay + "s";
                    };
                    new PublicAssmebly().SetSceneDelayDialog(action, securityAlarm.delay);
                };
                var btnDelayedRight = new Button()
                {
                    X = Application.GetRealWidth(343),
                    Gravity = Gravity.CenterVertical,
                    Width = Application.GetMinRealAverage(16),
                    Height = Application.GetMinRealAverage(16),
                    UnSelectedImagePath = "Public/RightIcon.png",
                };
                delayedRow.AddChidren(btnDelayedRight);
                delayedRow.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(49), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
                #endregion
                #endregion
                contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8), BackgroundColor = CSS_Color.BackgroundColor });
            }
            else
            {
                new TopViewDiv(bodyView, title).LoadTopView();
            }
            //布防功能
            iniDefenseView();
            //告警目标
            iniAlarmView();
            #region  执行推送
            ///上下间隔12像素
            contentView.AddChidren(new FrameLayout { Height = Application.GetRealHeight(12) });
            ///执行推送iew
            FrameLayout pushView = new FrameLayout()
            {
                Height = Application.GetRealHeight(50),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            contentView.AddChidren(deploymentTitleRow);
            contentView.AddChidren(pushView);
            var btnDeploymentTitle = new Button()
            var btnPushTitle = new Button()
            {
                X = Application.GetRealWidth(16),
                TextColor = CSS_Color.MainColor,
                TextColor = CSS_Color.FirstLevelTitleColor,
                TextAlignment = TextAlignment.CenterLeft,
                TextSize = CSS_FontSize.SubheadingFontSize,
                TextID = StringId.DeploymentInformation,
                TextSize = CSS_FontSize.TextFontSize,
                TextID = StringId.push,
                IsBold = true,
            };
            deploymentTitleRow.AddChidren(btnDeploymentTitle);
            pushView.AddChidren(btnPushTitle);
            deploymentTitleRow.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(43), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
            #region 布防名称
            var deploymentNameRow = new FrameLayout()
            var btnSwitchPush = new Button()
            {
                Height = Application.GetRealHeight(50),
                BackgroundColor = CSS_Color.MainBackgroundColor,
                Width = Application.GetRealWidth(36),
                Height = Application.GetRealWidth(36),
                X = Application.GetRealWidth(323),
                UnSelectedImagePath = "LogicIcon/off.png",
                SelectedImagePath = "LogicIcon/on.png",
                Gravity = Gravity.CenterVertical,
            };
            contentView.AddChidren(deploymentNameRow);
            pushView.AddChidren(btnSwitchPush);
            var btnDeploymentNameTitle = new Button()
            ///是否要推送点击事件
            btnSwitchPush.MouseUpEventHandler += (sender, e) =>
            {
                X = Application.GetRealWidth(16),
                Width = Application.GetRealWidth(72),
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.FirstLevelTitleColor,
                TextSize = CSS_FontSize.TextFontSize,
                TextID = StringId.Name,
                //账号列表为空默认推送当前账号
                if (securityAlarm.pushConfigs.Count == 0)
                {
                    //初始化对象
                    var pushConfigs = new SecurityPushConfig();
                    //默认添加推送当前账号
                    pushConfigs.pushTarget.Add(UserInfo.Current.ID);
                    securityAlarm.pushConfigs.Add(pushConfigs);
                }
                btnSwitchPush.IsSelected = !btnSwitchPush.IsSelected;
                if (btnSwitchPush.IsSelected)
                {
                    securityAlarm.noticeConfig.enable = true;
                }
                else
                {
                    securityAlarm.noticeConfig.enable = false;
                }
            };
            deploymentNameRow.AddChidren(btnDeploymentNameTitle);
            btnDeploymentNameTitle.Text += ":";
            var btnDeploymentName = new Button()
            {
                X = Application.GetRealWidth(88),
                Width = Application.GetRealWidth(230),
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.TextualColor,
                TextSize = CSS_FontSize.TextFontSize,
                Text = securityAlarm.name
            };
            deploymentNameRow.AddChidren(btnDeploymentName);
            deploymentNameRow.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(49), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
            LoadEvent_EditSecurityAlarmName(btnDeploymentName);
            pushView.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(49), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
            #endregion
            /*
            #region 触发延时
            var delayedRow = new FrameLayout()
            #region 发送通知
            ///发送通知View
            var pushMsgView = new FrameLayout()
            {
                Height = Application.GetRealHeight(50),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            contentView.AddChidren(delayedRow);
            var btnDelayedTitle = new Button()
            {
                X = Application.GetRealWidth(16),
                Width = Application.GetRealWidth(72),
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.FirstLevelTitleColor,
                TextSize = CSS_FontSize.TextFontSize,
                TextID = StringId.TriggerDelay,
            };
            delayedRow.AddChidren(btnDelayedTitle);
            btnDelayedTitle.Text += ":";
            var btnDelayedText = new Button()
            {
                X = Application.GetRealWidth(88),
                Width = Application.GetRealWidth(230),
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.TextualColor,
                TextSize = CSS_FontSize.TextFontSize,
                Text = securityAlarm.name
            };
            delayedRow.AddChidren(btnDelayedText);
            var btnDelayedRight = new Button()
            contentView.AddChidren(pushMsgView);
            var btnPushMsgRight = new Button()
            {
                X = Application.GetRealWidth(343),
                Gravity = Gravity.CenterVertical,
@@ -142,22 +257,37 @@
                Height = Application.GetMinRealAverage(16),
                UnSelectedImagePath = "Public/RightIcon.png",
            };
            delayedRow.AddChidren(btnDelayedRight);
            pushMsgView.AddChidren(btnPushMsgRight);
            //delayedRow.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(49), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
            #endregion
            */
            var btnPushMsgTitle = new Button()
            {
                X = Application.GetRealWidth(16),
                Width = Application.GetRealWidth(372),
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.FirstLevelTitleColor,
                TextSize = CSS_FontSize.TextFontSize,
                TextID = StringId.fasongtongzhi,
                IsBold = true,
            };
            pushMsgView.AddChidren(btnPushMsgTitle);
            btnPushMsgTitle.MouseUpEventHandler = (sender, e) => {
                var inputPushText = new PushConfigPage();
                MainPage.BasePageView.AddChidren(inputPushText);
                inputPushText.Show(securityAlarm);
                MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
            };
            ///上下间隔62像素
            contentView.AddChidren(new FrameLayout { Height = Application.GetRealHeight(40) });
            #endregion
            contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8), BackgroundColor = CSS_Color.BackgroundColor });
            //布防功能
            iniDefenseView();
#if DEBUG
            //告警目标
            iniAlarmView();
#endif
            #region 底部区域
            var bottomView = new FrameLayout()
@@ -209,17 +339,22 @@
                    tip.Show(MainPage.BaseView);
                    return;
                }
                //if (securityAlarm.output.Count == 0)
                //{
                //    var tip = new Tip()
                //    {
                //        Text = "请选择告警目标",
                //        CloseTime = 3,
                //        Direction = AMPopTipDirection.None
                //    };
                //    tip.Show(MainPage.BaseView);
                //    return;
                //}
                if (securityAlarm.output.Count == 0)
                {
                    var tipText = "请选择告警目标";
                    if(Language.CurrentLanguage !="Chinese")
                    {
                        tipText = "Please select the alarm target";
                    }
                    var tip = new Tip()
                    {
                        Text = tipText,
                        CloseTime = 3,
                        Direction = AMPopTipDirection.None
                    };
                    tip.Show(MainPage.BaseView);
                    return;
                }
                var waitPage = new Loading();
                waitPage.Start();
@@ -227,6 +362,7 @@
                {
                    try
                    {
                        var code = securityAlarm.SaveInfo();
                        if (code == StateCode.SUCCESS)
                        {
@@ -276,6 +412,8 @@
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            contentView.AddChidren(deploymentFunctionRow);
            deploymentFunctionRow.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(43), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
            var btnFunctionTitle = new Button()
            {
@@ -339,12 +477,9 @@
                    {
                        inputTargetView.AddChidren(new InputRow(target.GetFunction().name, target.GetFunction().GetRoomListName(), target.StateText()));
                    }
                    inputTargetView.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(49), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
                }
                inputTargetView.Height = Application.GetRealHeight(65 * securityAlarm.input.Count);
                //if (outputTargetView != null)
                //{
                //    contentView.AddChidren(outputTargetView);
                //}
            }
            else
            {
@@ -381,6 +516,7 @@
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            contentView.AddChidren(outputRow);
            outputRow.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(43), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
            var btnOutputRowTitle = new Button()
            {
@@ -420,9 +556,11 @@
            outputTargetView = new VerticalScrolViewLayout()
            {
                ScrollEnabled = false,
                Height =0,
            };
            contentView.AddChidren(outputTargetView);
            outputTargetView.Height = Application.GetRealHeight(65 * securityAlarm.output.Count);
            iniAlarmListView();
            #endregion
@@ -440,7 +578,11 @@
            {
                foreach (var outTarget in securityAlarm.output)
                {
                    outputTargetView.AddChidren(new OutputRow(outTarget.GetFunction().name, outTarget.GetFunction().GetRoomListName(), "打开"));
                    if (outTarget.GetFunction() != null)
                    {
                        outputTargetView.AddChidren(new OutputRow(outTarget.GetFunction().name, outTarget.GetFunction().GetRoomListName(), outTarget.StateText()));
                    }
                    outputTargetView.AddChidren(new Button() { Gravity = Gravity.CenterHorizontal, Y = Application.GetRealHeight(49), Height = 1, BackgroundColor = CSS_Color.DividingLineColor });
                }
                outputTargetView.Height = Application.GetRealHeight(65 * securityAlarm.output.Count);
            }
@@ -456,6 +598,7 @@
                    IsMoreLines = true,
                    BackgroundColor = CSS_Color.MainBackgroundColor,
                });
                outputTargetView.Height = Application.GetRealHeight(68);
            }
        }
@@ -480,7 +623,6 @@
                        }.Show(bodyView);
                        return;
                    }
                    btnDeploymentName.Text = securityAlarm.name = str;
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddInputPage.cs
@@ -14,13 +14,11 @@
        Action<SecurityAlarm> refreshAction;
        SecurityAlarm securityAlarm;
        List<SecurityInput> inputList = new List<SecurityInput>();
        public AddInputPage(SecurityAlarm alarm,Action<SecurityAlarm> action)
        SecurityAlarm alarm;
        public AddInputPage(SecurityAlarm inAlarm,Action<SecurityAlarm> action)
        {
            bodyView = this;
            securityAlarm = alarm;
            alarm = inAlarm;
            refreshAction = action;
        }
@@ -65,14 +63,17 @@
                Text = DB_ResidenceData.Instance.CurFloor.roomName,
            };
            showdFunctionTypeRow.AddChidren(btnFloor);
            btnFloor.MouseUpEventHandler += (sender, e) =>
            btnFloor.MouseUpEventHandler = (sender, e) =>
            {
                string nowSelectId = null;
                var listAllFun = FunctionList.List.GetArmSensorList();
                var list = FunctionList.List.GetArmSensorList();
#if DEBUG
                list.AddRange(FunctionList.List.GetLightList());
#endif
                //显示下拉界面
                var form = new FloorRoomSelectPopupView();
                form.ShowDeviceFunctionView(btnFloor, listAllFun, (selectId, listFun) =>
                form.ShowDeviceFunctionView(btnFloor, list, (selectId, listFun) =>
                {
                    nowSelectId = selectId;
                    //重新刷新设备列表
@@ -92,8 +93,12 @@
            bodyView.AddChidren(functionListView);
            var listAllFun = FunctionList.List.GetArmSensorList();
#if DEBUG
            listAllFun.AddRange(FunctionList.List.GetLightList());
#endif
            LoadFunctionListRow(FunctionList.List.GetArmSensorList());
            LoadFunctionListRow(listAllFun);
@@ -122,16 +127,8 @@
            bottomView.AddChidren(btnConfrim);
            btnConfrim.MouseUpEventHandler = (sender, e) =>
            {
                securityAlarm.input = new List<SecurityInput>();
                foreach (var input in inputList)
                {
                    if (input.addCondition)
                    {
                        securityAlarm.input.Add(input);
                    }
                }
                this.RemoveFromParent();
                refreshAction?.Invoke(securityAlarm);
                refreshAction?.Invoke(alarm);
            };
            
@@ -151,13 +148,10 @@
                functions = FunctionList.List.GetArmSensorList();
            }
#if DEBUG
            functions.AddRange(FunctionList.List.GetLightList());
#endif
            foreach (var function in functions)
            {
                var input = securityAlarm.input.Find((obj) => obj.sid == function.sid);
                var input = alarm.input.Find((obj) => obj.sid == function.sid);
                if (input == null)
                {
                    input = new SecurityInput();
@@ -188,32 +182,32 @@
                            break;
                    }
                    input.condition = new List<SecurityInputCondition>()
                {
                    new SecurityInputCondition()
                    {
                        key = inKey,
                        value = inValue,
                    }
                };
                        new SecurityInputCondition()
                        {
                            key = inKey,
                            value = inValue,
                        }
                    };
                    if (function.spk == SPK.LightSwitch || function.spk == SPK.LightRGB || function.spk == SPK.LightDimming)
                    {
                        input.condition = new List<SecurityInputCondition>()
                    {
                        new SecurityInputCondition()
                        {
                            key = FunctionAttributeKey.OnOff,
                            value = "off",
                        }
                    };
                            new SecurityInputCondition()
                            {
                                key = FunctionAttributeKey.OnOff,
                                value = "off",
                            }
                        };
                    }
                }
                else
                {
                    input.addCondition = true;
                }
                inputList.Add(input);
                //else
                //{
                //    //input.addCondition = true;
                //    alarm.input.Add(input);
                //}
                FrameLayout functionRow = new FrameLayout()
                {
@@ -268,37 +262,53 @@
                };
                functionRow.AddChidren(btnChooseIcon);
                btnChooseIcon.MouseUpEventHandler = (sender, e) => {
                btnChooseIcon.MouseUpEventHandler = (sender, e) =>
                {
                    btnChooseIcon.IsSelected = !btnChooseIcon.IsSelected;
                    if(btnChooseIcon.IsSelected)
                    var tempLocal = alarm.input.Find((obj) =>
                        obj.sid == input.sid
                    );
                    if (btnChooseIcon.IsSelected)
                    {
                        input.addCondition = true;
                        //if (input.condition.Count==0)
                        //{
                        //    ShowStateDialog(input, btnState,btnChooseIcon,function.spk);
                        //}
                        //input.addCondition = true;
                        if (tempLocal == null)
                            alarm.input.Add(input);
                    }
                    else
                    {
                        input.addCondition = false;
                        //input.addCondition = false;
                        if (tempLocal != null)
                        {
                            alarm.input.Remove(input);
                        }
                    }
                };
                btnState.MouseUpEventHandler = (sender, e) =>
                {
                    //ShowStateDialog(input, btnState, btnChooseIcon, function.spk);
                    btnChooseIcon.IsSelected = !btnChooseIcon.IsSelected;
                    var tempLocal = alarm.input.Find((obj) =>
                        obj.sid == input.sid
                    );
                    if (btnChooseIcon.IsSelected)
                    {
                        input.addCondition = true;
                        //input.addCondition = true;
                        if (tempLocal == null)
                            alarm.input.Add(input);
                    }
                    else
                    {
                        input.addCondition = false;
                        //input.addCondition = false;
                        if (tempLocal != null)
                        {
                            alarm.input.Remove(input);
                        }
                    }
                };
                if (input.addCondition)
                var localInput = alarm.input.Find((obj) =>
                           obj.sid == input.sid
                       );
                if (localInput!=null)
                {
                    btnChooseIcon.IsSelected = true;
                    btnState.Text = input.StateText();
@@ -414,8 +424,12 @@
                }
                var localInput = alarm.input.Find((obj) =>
                        obj.sid == input.sid
                    );
                if (localInput == null)
                    alarm.input.Add(input);
                input.addCondition = true;
                if (btnChoose != null)
                {
                    btnChoose.IsSelected = true;
@@ -448,7 +462,12 @@
                }
                input.addCondition = true;
                var localInput = alarm.input.Find((obj) =>
                        obj.sid == input.sid
                    );
                if (localInput == null)
                    alarm.input.Add(input);
                if (btnChoose != null)
                {
                    btnChoose.IsSelected = true;
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/AddOutputPage.cs
@@ -29,17 +29,19 @@
        VerticalScrolViewLayout functionListView;
        SecurityAlarm securityAlarm;
        Action<SecurityAlarm> refreshAction;
        List<SecurityOutput> outputList = new List<SecurityOutput>();
        /// <summary>
        /// 本地功能转换的输出列表(灯光、场景)
        /// </summary>
        List<SecurityOutput> allocatedList = new List<SecurityOutput>();
        List<Function> allocatedList = new List<Function>();
        SecurityAlarm alarm;
        public AddOutputPage(SecurityAlarm function, Action<SecurityAlarm> action)
        public AddOutputPage(SecurityAlarm inOutput ,Action<SecurityAlarm> action)
        {
            bodyView = this;
            securityAlarm = function;
            refreshAction = action;
            alarm = inOutput;
        }
@@ -83,6 +85,7 @@
                Text = DB_ResidenceData.Instance.CurFloor.roomName,
            };
            showdFunctionTypeRow.AddChidren(btnFloor);
            LoadDialog_ChangeFloor();
            #endregion
@@ -95,31 +98,9 @@
            bodyView.AddChidren(functionListView);
            SetData();
            foreach (var function in FunctionList.List.Functions)
            {
                if (!MainPage.SceneSupportFunctionList.Contains(function.spk))
                {
                    continue;
                }
                if (function == null)
                {
                    continue;
                }
                function.roomIds.Remove(null);
                    allocatedList.Add(function);
            }
            LoadFunctionListRow(null);
            LoadFunctionListRow();
            var bottomView = new FrameLayout()
            {
@@ -146,51 +127,97 @@
            bottomView.AddChidren(btnConfrim);
            btnConfrim.MouseUpEventHandler = (sender, e) =>
            {
                securityAlarm.output = new List<SecurityOutput>();
                foreach (var output in outputList)
                {
                    if (output.addCondition)
                    {
                        securityAlarm.output.Add(output);
                    }
                }
                this.RemoveFromParent();
                refreshAction?.Invoke(securityAlarm);
                refreshAction?.Invoke(alarm);
            };
        }
        /// <summary>
        /// 配置数据
        /// </summary>
        void SetData(string roomId="")
        {
            allocatedList.Clear();
            foreach (var function in FunctionList.List.GetLightList())
            {
                if (function == null)
                {
                    continue;
                }
                if (!string.IsNullOrEmpty(roomId) && roomId == "ALLSELECT")
                {
                    if (!function.roomIds.Contains(roomId))
                    {
                        continue;
                    }
                }
                function.roomIds.Remove(null);
                var tempStatus = new List<SecurityOutputStatus>();
                tempStatus.Add(new SecurityOutputStatus() { key = FunctionAttributeKey.OnOff, value = "on" });
                allocatedList.Add(new SecurityOutput
                {
                    target_type = "0",
                    sid = function.sid,
                    status = tempStatus,
                    name = function.name,
                    RoomName = function.GetRoomListName(),
                });
            }
            foreach (var scene in FunctionList.List.scenes)
            {
                if (scene == null)
                {
                    continue;
                }
                if (!string.IsNullOrEmpty(roomId))
                {
                    if (!scene.roomIds.Contains(roomId))
                    {
                        continue;
                    }
                }
                scene.roomIds.Remove(null);
                var tempStatus = new List<SecurityOutputStatus>();
                tempStatus.Add(new SecurityOutputStatus() { key = "value", value = "0" });
                allocatedList.Add(new SecurityOutput
                {
                    target_type = "1",
                    sid = scene.sid,
                    status = tempStatus,
                    name = scene.name,
                    RoomName = scene.GetRoomListName(),
                });
            }
        }
        // <summary>
        /// 显示功能Row
        /// </summary>
        void LoadFunctionListRow(List<Function> functions)
        void LoadFunctionListRow()
        {
            functionListView.RemoveAll();
            if (functions == null)
            foreach (var function in allocatedList)
            {
                functions = allocatedList;
            }
            foreach (var function in functions)
            {
                var output = securityAlarm.output.Find((obj) => obj.sid == function.sid);
                var output = alarm.output.Find((obj) => obj.sid == function.sid);
                if (output == null)
                {
                    output = new SecurityOutput();
                    output = new SecurityOutput() { status = new List<SecurityOutputStatus> { new SecurityOutputStatus {
                         key = FunctionAttributeKey.OnOff,
                         value = "on"
                    } } };
                    output.sid = function.sid;
                }
                else
                {
                    output.addCondition = true;
                }
                outputList.Add(output);
                //else
                //{
                //    output.addCondition = true;
                //}
                FrameLayout functionRow = new FrameLayout()
                {
@@ -217,7 +244,7 @@
                    Y = Application.GetRealHeight(24),
                    Width = Application.GetRealWidth(200),
                    Height = Application.GetRealHeight(41),
                    Text = function.GetRoomListName(),
                    Text = function.RoomName,
                    TextAlignment = TextAlignment.CenterLeft,
                    TextColor = CSS_Color.PromptingColor1,
                    TextSize = CSS_FontSize.PromptFontSize_SecondaryLevel,
@@ -247,17 +274,22 @@
                btnChooseIcon.MouseUpEventHandler = (sender, e) => {
                    btnChooseIcon.IsSelected = !btnChooseIcon.IsSelected;
                    var tempLocal = alarm.input.Find((obj) =>
                        obj.sid == output.sid
                    );
                    if (btnChooseIcon.IsSelected)
                    {
                        output.addCondition = true;
                        if (output.status.Count == 0)
                        {
                            ShowStateDialog(output, btnState,btnChooseIcon);
                        }
                        //input.addCondition = true;
                        if (tempLocal == null)
                            alarm.output.Add(output);
                    }
                    else
                    {
                        output.addCondition = false;
                        //input.addCondition = false;
                        if (tempLocal != null)
                        {
                            alarm.output.Remove(output);
                        }
                    }
                };
                btnState.MouseUpEventHandler = (sender, e) =>
@@ -265,8 +297,9 @@
                    ShowStateDialog(output, btnState, btnChooseIcon);
                };
                var localOutput = alarm.output.Find((obj) => obj.sid == output.sid);
                if (output.addCondition)
                if (localOutput!=null)
                {
                    btnChooseIcon.IsSelected = true;
                    btnState.Text = output.StateText();
@@ -284,7 +317,6 @@
            }
        }
        private void ShowStateDialog(SecurityOutput output, Button btnState, Button btnChoose = null)
@@ -320,12 +352,12 @@
            {
                Height = Application.GetRealHeight(44),
                TextAlignment = TextAlignment.Center,
                TextColor = CSS_Color.MainColor,
                SelectedTextColor = CSS_Color.MainColor,
                TextColor = CSS_Color.PromptingColor1,
                TextSize = CSS_FontSize.SubheadingFontSize,
                TextID = StringId.On
                TextID = StringId.On,
            };
            optinView.AddChidren(btnOpen);
            optinView.AddChidren(new Button()
            {
                Height = 1,
@@ -336,11 +368,17 @@
            {
                Height = Application.GetRealHeight(44),
                TextAlignment = TextAlignment.Center,
                SelectedTextColor = CSS_Color.MainColor,
                TextColor = CSS_Color.PromptingColor1,
                TextID = StringId.OFF,
                TextSize = CSS_FontSize.SubheadingFontSize,
            };
            optinView.AddChidren(btnClose);
            if (output.status.Count > 0)
            {
                btnOpen.IsSelected =  output.status[0].value.ToLower() == "on";
                btnClose.IsSelected = !btnOpen.IsSelected;
            }
            Button btnCancel = new Button()
@@ -369,8 +407,10 @@
                        value = "on",
                    }
                };
                output.addCondition = true;
                if (btnChoose != null)
                var localInput = alarm.output.Find((obj) =>
                   obj.sid == output.sid
                );
                if (localInput == null)
                {
                    btnChoose.IsSelected = true;
                }
@@ -388,8 +428,10 @@
                        value = "off",
                    }
                };
                output.addCondition = true;
                if (btnChoose != null)
                var localInput = alarm.output.Find((obj) =>
                 obj.sid == output.sid
                );
                if (localInput == null)
                {
                    btnChoose.IsSelected = true;
                }
@@ -420,18 +462,18 @@
        void LoadDialog_ChangeFloor()
        {
            string nowSelectId = null;
            btnFloor.MouseUpEventHandler += (sender, e) =>
            btnFloor.MouseUpEventHandler = (sender, e) =>
            {
                var listAllFun = new List<Function>();
                listAllFun.AddRange(allocatedList);
                //listAllFun.AddRange(allocatedList);
                //显示下拉界面
                var form = new FloorRoomSelectPopupView();
                form.ShowDeviceFunctionView(btnFloor, listAllFun, (selectId, listFun) =>
                {
                    nowSelectId = selectId;
                    SetData(selectId);
                    //重新刷新设备列表
                    this.LoadFunctionListRow(listFun);
                    this.LoadFunctionListRow();
                }, nowSelectId);
            };
        }
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/ArmCenterPage.cs
@@ -58,17 +58,18 @@
            bodyView = this;
        }
        public void LoadPage()
        public void LoadPage(bool addNav = true)
        {
            Action skipAction = () => {
            };
            new TopViewDiv(bodyView, Language.StringByID(StringId.SecurityCenter)).LoadTopView_ArmCenter(skipAction);
            if (addNav)
            {
                new TopViewDiv(bodyView, Language.StringByID(StringId.SecurityCenter)).LoadTopView_ArmCenter(skipAction);
            }
            VerticalScrolViewLayout contentView = new VerticalScrolViewLayout()
            {
                Y = Application.GetRealHeight(64),
                Y = addNav? Application.GetRealHeight(64):0,
                Height = Application.GetRealHeight(667 - 64),
                BackgroundColor = CSS_Color.MainBackgroundColor,
                ScrollEnabled = false,
@@ -194,6 +195,8 @@
                Height = Application.GetRealHeight(20),
            });
            #region 固定布防区域
            /*
            var fixedDeploymentView = new FrameLayout()
@@ -239,11 +242,26 @@
                Width = Application.GetRealWidth(24),
            });
            #endregion
            //灾害报警
            var disasterAlarmView = new FixedArmView("FunctionIcon/ArmCenter/DisasterAlarmIcon.png", Language.StringByID(StringId.DisasterDefense), Language.StringByID(StringId.Defense24Hour));
            EventHandler<MouseEventArgs> disasterAlarmViewClick = (sender, e) => {
                var disasterAlarm = FunctionList.List.securities.Find((obj) => obj.type == "all_day");
                if (disasterAlarm == null)
                {
                    disasterAlarm = new SecurityAlarm() { name = "alldaydefense", type = "all_day" };
                }
                else
                {
                    disasterAlarm = disasterAlarm.RefeshData();
                }
                var addDefensePage = new AddAlarmDeploymentPage(disasterAlarm, null);
                MainPage.BasePageView.AddChidren(addDefensePage);
                addDefensePage.LoadPage(Language.StringByID(StringId.DisasterDefense));
                MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
            };
            disasterAlarmView.SetClick(disasterAlarmViewClick);
            fixedDeploymentTypeView.AddChidren(disasterAlarmView);
            fixedDeploymentTypeView.AddChidren(new Button()
@@ -253,6 +271,22 @@
            //防盗报警
            var burglarAlarmView = new FixedArmView("FunctionIcon/ArmCenter/BurglarAlarmIcon.png", Language.StringByID(StringId.BurglarAlarm), Language.StringByID(StringId.AlarmMute));
            EventHandler<MouseEventArgs> burglarAlarmViewClick = (sender, e) => {
                var burglarAlarm = FunctionList.List.securities.Find((obj) => obj.type == "mute");
                if (burglarAlarm == null)
                {
                    burglarAlarm = new SecurityAlarm() { name = "mutedefense", type = "mute" };
                }
                else
                {
                    burglarAlarm = burglarAlarm.RefeshData();
                }
                var addDefensePage = new AddAlarmDeploymentPage(burglarAlarm, null);
                MainPage.BasePageView.AddChidren(addDefensePage);
                addDefensePage.LoadPage(Language.StringByID(StringId.BurglarAlarm));
                MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
            };
            disasterAlarmView.SetClick(disasterAlarmViewClick);
            fixedDeploymentTypeView.AddChidren(burglarAlarmView);
            */
            #endregion
@@ -323,12 +357,12 @@
                customDeploymentView.AddChidren(view);
                EventHandler<MouseEventArgs> event1 = (sender, e) =>
                {
                    Action refreshAction = () =>
                    Action addDefenseRefreshAction = () =>
                    {
                        iniCustomDeploymentView();
                    };
                    var addDefensePage = new AddAlarmDeploymentPage(new SecurityAlarm(), refreshAction);
                    var addDefensePage = new AddAlarmDeploymentPage(new SecurityAlarm(), addDefenseRefreshAction);
                    MainPage.BasePageView.AddChidren(addDefensePage);
                    addDefensePage.LoadPage();
                    MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
@@ -424,6 +458,8 @@
                {
                    iniCustomDeploymentView();
                };
                    alarm = alarm.RefeshData();
                var armSetPage = new AddAlarmDeploymentPage(alarm,refreshAction);
                MainPage.BasePageView.AddChidren(armSetPage);
                armSetPage.LoadPage();
@@ -572,6 +608,10 @@
    /// </summary>
    public class FixedArmView : FrameLayout
    {
        Button btnIcon;
        Button btnTitle;
        Button btnTitleTip;
        /// <summary>
        /// 固定布防控件
        /// </summary>
@@ -586,7 +626,7 @@
            this.BorderColor = CSS_Color.MainColor;
            this.BorderWidth = 1;
            var btnIcon = new Button()
            btnIcon = new Button()
            {
                X = Application.GetRealWidth(15),
                Width = Application.GetRealWidth(24),
@@ -596,7 +636,7 @@
            };
            this.AddChidren(btnIcon);
            var btnTitle = new Button()
            btnTitle = new Button()
            {
                X = Application.GetRealWidth(55),
                Width = Application.GetRealWidth(89),
@@ -609,7 +649,7 @@
            };
            this.AddChidren(btnTitle);
            var btnTitleTip = new Button()
            btnTitleTip = new Button()
            {
                X = Application.GetRealWidth(55),
                Y = Application.GetRealHeight(23),
@@ -619,10 +659,20 @@
                TextColor = CSS_Color.PromptingColor1,
                TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                Text = titleTip,
                IsMoreLines = true,
            };
            this.AddChidren(btnTitleTip);
        }
        /// <summary>
        /// 设置点击事件
        /// </summary>
        /// <param name="handler"></param>
        public void  SetClick(EventHandler<MouseEventArgs> handler)
        {
            btnTitleTip.MouseUpEventHandler = btnIcon.MouseUpEventHandler = handler;
        }
    }
}
HDL_ON/UI/UI2/FuntionControlView/ArmCenter/PushConfigPage.cs
New file
@@ -0,0 +1,196 @@
using System;
using System.Collections.Generic;
using HDL_ON.UI.UI2.Intelligence.Automation;
using Shared;
namespace HDL_ON.UI
{
    public class PushConfigPage : FrameLayout
    {
        FrameLayout bodyView;
        public PushConfigPage()
        {
            bodyView = this;
        }
        public void Show(Entity.SecurityAlarm alarm)
        {
            new TopViewDiv(bodyView, Language.StringByID(StringId.fasongtongzhi)).LoadTopView();
            this.BackgroundColor = CSS.CSS_Color.BackgroundColor;
            var viewLayout = new FrameLayout()
            {
                Y = Application.GetRealHeight(64),
                Height = Application.GetRealHeight(527),
            };
            bodyView.AddChidren(viewLayout);
            #region  通知内容
            UI2.Intelligence.Automation.LogicView.AddOutputInputTextView addInputTextView = new UI2.Intelligence.Automation.LogicView.AddOutputInputTextView();
            addInputTextView.btnIf.TextID = StringId.tongzhineirong;
            viewLayout.AddChidren(addInputTextView.FLayoutView(46, 12));
            ///输入推送文本
            EditTextView textBox = new EditTextView//EditText
            {
                Y = Application.GetRealHeight(42),
                X = Application.GetRealWidth(16),
                Width = Application.GetRealWidth(343),
                Height = Application.GetRealHeight(152),
                TextAlignment = TextAlignment.TopLeft,
                Radius = (uint)Application.GetRealHeight(12),
                Text = alarm.noticeConfig.noticeContent,
                TextSize = UI2.Intelligence.Automation.LogicView.TextSize.text14,
                TextColor = CSS.CSS_Color.textColor,
                PlaceholderText = Language.StringByID(StringId.xianzhichangdu),//"(100字以内)",
                PlaceholderTextColor = CSS.CSS_Color.textCancelColor,
                BackgroundColor = CSS.CSS_Color.textWhiteColor,
            };
            viewLayout.AddChidren(textBox);
            textBox.TextChangeEventHandler += (sender, e) =>
            {
                var leng = e.Length;
                if (leng > 100)
                {
                    textBox.Text = e.Substring(0, 100);
#if __Android__
                    textBox.SetSelectionEnd();
#endif
                }
            };
            #endregion
            #region  App推送
            UI2.Intelligence.Automation.LogicView.LogicTypeTitleView appPush = new UI2.Intelligence.Automation.LogicView.LogicTypeTitleView();
            appPush.frameLayout.Y = Application.GetRealHeight(206);
            appPush.frameLayout.Radius = (uint)Application.GetRealHeight(12);
            appPush.btnText.TextID = StringId.apptuisong;
            appPush.btnText.X = Application.GetRealWidth(12);
            viewLayout.AddChidren(appPush.FLayoutView(false));
            //定义一个局部账号列表用来记录选中数据;
            List<string> selectedAccountList = new List<string>();
            appPush.btnClick.MouseUpEventHandler += (sender, e) =>
            {
                var userList = new List<HDL_ON.Entity.ResidenceMemberInfo>();
                Loading loading = new Loading();
                this.AddChidren(loading);
                loading.Start();
                new System.Threading.Thread(() =>
                {
                    try
                    {
                        userList = Send.GetResidenceMemberAccount();
                    }
                    catch { }
                    finally
                    {
                        Application.RunOnMainThread(() =>
                        {
                            loading.Hide();
                            userList.Add(new Entity.ResidenceMemberInfo { childAccountId = UserInfo.Current.ID, childAccountPhone = UserInfo.Current.userMobileInfo, childAccountEmail = UserInfo.Current.userEmailInfo });
                            //住宅子账号列表
                            List<string> accountList = new List<string>();
                            //之前状态列表
                            List<string> stateList = new List<string>();
                            for (int i = 0; i < userList.Count; i++)
                            {
                                var user = userList[i];
                                accountList.Add(user.Account);
                            }
                            if (alarm.pushConfigs.Count > 0)
                            {
                                var list = alarm.pushConfigs[0].pushTarget;
                                for (int i = 0; i < userList.Count; i++)
                                {
                                    var user = userList[i];
                                    if (list.Contains(user.childAccountId))
                                    {
                                        stateList.Add(user.Account);
                                    }
                                }
                            }
                            PublicInterface view = new PublicInterface();
                            view.FrameOrVvList(this, accountList, stateList, StringId.zhanghaoxuanze
                               , (list) =>
                               {
                                   //清空旧数据列表
                                   selectedAccountList.Clear();
                                   for (int i = 0; i < userList.Count; i++)
                                   {
                                       var user = userList[i];
                                       if (list.Contains(user.Account))
                                       {
                                           selectedAccountList.Add(user.childAccountId);
                                       }
                                   }
                               });
                        });
                    }
                })
                { IsBackground = true }.Start();
            };
            #endregion
            #region  确认
            UI2.Intelligence.Automation.LogicView.SaveView saveView = new UI2.Intelligence.Automation.LogicView.SaveView();
            saveView.btnSave.TextID = StringId.queren;
            saveView.frameLayout.SetCornerWithSameRadius(Application.GetRealHeight(24), HDLUtils.RectCornerTopLeft | HDLUtils.RectCornerTopRight);
            this.AddChidren(saveView.FLayoutView());
            saveView.btnClick.MouseUpEventHandler += (e, sen) =>
            {
                alarm.noticeConfig.noticeContent = textBox.Text.Trim();
                if (selectedAccountList.Count > 0)
                {
                    alarm.pushConfigs.Clear();//清空旧数据列表
                    alarm.pushConfigs.Add(new Entity.SecurityPushConfig { pushTarget = selectedAccountList });
                }
                //账号列表为空默认推送当前账号
                if (alarm.pushConfigs.Count == 0)
                {
                    //初始化对象
                    Entity.SecurityPushConfig pushConfigs = new Entity.SecurityPushConfig();
                    //默认添加推送当前账号
                    pushConfigs.pushTarget.Add(UserInfo.Current.ID);
                    alarm.pushConfigs.Add(pushConfigs);
                }
                this.RemoveFromParent();
            };
            #endregion
        }
        /// <summary>
        /// 手机账号为先,手机账号为空,其次到邮箱账号
        /// </summary>
        private string Account
        {
            get
            {
                ///手机账号为先,手机账号为空,其次到邮箱账号;
                if (!string.IsNullOrEmpty(UserInfo.Current.userMobileInfo))
                {
                    //默认推送当前手机账号
                    return UserInfo.Current.userMobileInfo;
                }
                else
                {
                    //默认推送当前邮箱账号
                    return UserInfo.Current.userEmailInfo;
                }
            }
        }
    }
}
SiriBinding/ApiDefinition.cs
New file
@@ -0,0 +1,86 @@
using System;
using ObjCRuntime;
using Foundation;
using UIKit;
using Intents;
namespace HdlSiri
{
    // @interface HDLRunSceneIntent : INIntent
    [Watch(5, 0), NoTV, Mac(11, 0), iOS(12, 0)]
    [BaseType(typeof(INIntent))]
    interface HDLRunSceneIntent
    {
        // @property (readwrite, copy, nonatomic) NSString * _Nullable sceneName;
        [NullAllowed, Export("sceneName")]
        string SceneName { get; set; }
        // @property (readwrite, copy, nonatomic) NSString * _Nullable sceneId;
        [NullAllowed, Export("sceneId")]
        string SceneId { get; set; }
    }
    // @protocol HDLRunSceneIntentHandling <NSObject>
    /*
    Check whether adding [Model] to this declaration is appropriate.
    [Model] is used to generate a C# class that implements this protocol,
    and might be useful for protocols that consumers are supposed to implement,
    since consumers can subclass the generated class instead of implementing
    the generated interface. If consumers are not supposed to implement this
    protocol, then [Model] is redundant and will generate code that will never
    be used.
    */
    [Watch(5, 0), NoTV, Mac(11, 0), iOS(12, 0)]
    [Protocol]
    [BaseType(typeof(NSObject))]
    interface HDLRunSceneIntentHandling
    {
        // @required -(void)handleRunScene:(HDLRunSceneIntent * _Nonnull)intent completion:(void (^ _Nonnull)(HDLRunSceneIntentResponse * _Nonnull))completion __attribute__((swift_name("handle(intent:completion:)")));
        [Abstract]
        [Export("handleRunScene:completion:")]
        void HandleRunScene(HDLRunSceneIntent intent, Action<HDLRunSceneIntentResponse> completion);
        // @optional -(void)confirmRunScene:(HDLRunSceneIntent * _Nonnull)intent completion:(void (^ _Nonnull)(HDLRunSceneIntentResponse * _Nonnull))completion __attribute__((swift_name("confirm(intent:completion:)")));
        [Export("confirmRunScene:completion:")]
        void ConfirmRunScene(HDLRunSceneIntent intent, Action<HDLRunSceneIntentResponse> completion);
    }
    // @interface HDLRunSceneIntentResponse : INIntentResponse
    [Watch(5, 0), NoTV, Mac(11, 0), iOS(12, 0)]
    [BaseType(typeof(INIntentResponse))]
    [DisableDefaultCtor]
    interface HDLRunSceneIntentResponse
    {
        // -(instancetype _Nonnull)initWithCode:(HDLRunSceneIntentResponseCode)code userActivity:(NSUserActivity * _Nullable)userActivity __attribute__((objc_designated_initializer));
        [Export("initWithCode:userActivity:")]
        [DesignatedInitializer]
        IntPtr Constructor(HDLRunSceneIntentResponseCode code, [NullAllowed] NSUserActivity userActivity);
        // +(instancetype _Nonnull)successIntentResponseWithSceneName:(NSString * _Nonnull)sceneName __attribute__((swift_name("success(sceneName:)")));
        [Static]
        [Export("successIntentResponseWithSceneName:")]
        HDLRunSceneIntentResponse SuccessIntentResponseWithSceneName(string sceneName);
        // +(instancetype _Nonnull)failureIntentResponseWithErrorMessage:(NSString * _Nonnull)errorMessage __attribute__((swift_name("failure(errorMessage:)")));
        [Static]
        [Export("failureIntentResponseWithErrorMessage:")]
        HDLRunSceneIntentResponse FailureIntentResponseWithErrorMessage(string errorMessage);
        // @property (readwrite, copy, nonatomic) NSString * _Nullable errorMessage;
        [NullAllowed, Export("errorMessage")]
        string ErrorMessage { get; set; }
        // @property (readwrite, copy, nonatomic) NSString * _Nullable successMessage;
        [NullAllowed, Export("successMessage")]
        string SuccessMessage { get; set; }
        // @property (readwrite, copy, nonatomic) NSString * _Nullable sceneName;
        [NullAllowed, Export("sceneName")]
        string SceneName { get; set; }
        // @property (readonly, nonatomic) HDLRunSceneIntentResponseCode code;
        [Export("code")]
        HDLRunSceneIntentResponseCode Code { get; }
    }
}
SiriBinding/Properties/AssemblyInfo.cs
New file
@@ -0,0 +1,34 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using Foundation;
// This attribute allows you to mark your assemblies as “safe to link”.
// When the attribute is present, the linker—if enabled—will process the assembly
// even if you’re using the “Link SDK assemblies only” option, which is the default for device builds.
[assembly: LinkerSafe]
// Information about this assembly is defined by the following attributes.
// Change them to the values specific to your project.
[assembly: AssemblyTitle("NativeLibrary")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("NativeLibrary")]
[assembly: AssemblyCopyright("Copyright ©  2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
// The form "{Major}.{Minor}.*" will automatically update the build and revision,
// and "{Major}.{Minor}.{Build}.*" will update just the revision.
[assembly: AssemblyVersion("1.0.*")]
// The following attributes are used to specify the signing key for the assembly,
// if desired. See the Mono documentation for more information about signing.
//[assembly: AssemblyDelaySign(false)]
//[assembly: AssemblyKeyFile("")]
SiriBinding/SiriBinding.csproj
New file
@@ -0,0 +1,56 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProjectTypeGuids>{8FFB629D-F513-41CE-95D2-7ECE97B6EEEC};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
    <ProjectGuid>{77FFAB61-395D-4AD3-863E-C4E32B5038E7}</ProjectGuid>
    <TemplateGuid>{b6f3ff35-79b2-4f25-a2fc-60a7cf61013b}</TemplateGuid>
    <OutputType>Library</OutputType>
    <RootNamespace>NativeLibrary</RootNamespace>
    <IPhoneResourcePrefix>Resources</IPhoneResourcePrefix>
    <AssemblyName>NativeLibrary</AssemblyName>
    <RestoreProjectStyle>PackageReference</RestoreProjectStyle>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>portable</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\Debug</OutputPath>
    <DefineConstants>DEBUG;</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <DebugType>portable</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\Release</OutputPath>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="System" />
    <Reference Include="Xamarin.iOS" />
  </ItemGroup>
  <ItemGroup>
    <Folder Include="Resources\" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="Properties\AssemblyInfo.cs" />
  </ItemGroup>
  <ItemGroup>
    <ObjcBindingApiDefinition Include="ApiDefinition.cs" />
  </ItemGroup>
  <ItemGroup>
    <ObjcBindingCoreSource Include="Structs.cs" />
  </ItemGroup>
  <ItemGroup>
    <NativeReference Include="..\ThirdPartyIntegration\siri\libOnProSiriIntents.a">
      <Kind>Static</Kind>
      <SmartLink>False</SmartLink>
    </NativeReference>
  </ItemGroup>
  <Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.ObjCBinding.CSharp.targets" />
</Project>
SiriBinding/Structs.cs
New file
@@ -0,0 +1,18 @@
using ObjCRuntime;
namespace HdlSiri
{
    [Watch(5, 0), NoTV, Mac(11, 0), iOS(12, 0)]
    [Native]
    public enum HDLRunSceneIntentResponseCode : long
    {
        Unspecified = 0,
        Ready,
        ContinueInApp,
        InProgress,
        Success,
        Failure,
        FailureRequiringAppLaunch,
        Error = 100
    }
}
SiriIntents/Entitlements.plist
New file
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>com.apple.security.application-groups</key>
    <array>
        <string>group.com.hdl.onpro</string>
    </array>
    <key>com.apple.developer.siri</key>
    <true/>
</dict>
</plist>
SiriIntents/HDLRunSceneIntentHandlder.cs
New file
@@ -0,0 +1,146 @@
using System;
using System.Collections.Generic;
using Foundation;
using HDLSceneSiri;
using ObjCRuntime;
using UIKit;
//using HdlSiri;
namespace SiriIntents
{
    public class HDLRunSceneIntentHandlder : HDLRunSceneIntentHandling
    {
        public override void ConfirmHDLRunScene (HDLRunSceneIntent intent,  Action<HDLRunSceneIntentResponse> completion)
        {
            if (UIDevice.CurrentDevice.CheckSystemVersion(12, 0))
            {
                if (Server.HttpServerRequest.Ins.DataManager.IsLgoin)
                {
                    var rsp = new HDLRunSceneIntentResponse(HDLRunSceneIntentResponseCode.InProgress, null);
                    if (NSLocale.PreferredLanguages[0].Contains("zh-"))
                    {
                        rsp.SuccessMessage = "请等待...";
                    }
                    else
                    {
                        rsp.SuccessMessage = "Please wait...";
                    }
                    completion(rsp);
                }
                else
                {
                    var rsp = new HDLRunSceneIntentResponse(HDLRunSceneIntentResponseCode.Failure, null);
                    if (NSLocale.PreferredLanguages[0].Contains("zh-"))
                    {
                        rsp.SuccessMessage = "账号未登录";
                    }
                    else
                    {
                        rsp.SuccessMessage = "Not logged in to the app";
                    }
                    completion(rsp);
                }
            }
            else
            {
                var rsp = new HDLRunSceneIntentResponse(HDLRunSceneIntentResponseCode.ContinueInApp, null);
                rsp.SuccessMessage = "Ok";
                completion(rsp);
            }
        }
        public override void HandleHDLRunScene(HDLRunSceneIntent intent,Action<HDLRunSceneIntentResponse> completion)
        {
            if (UIDevice.CurrentDevice.CheckSystemVersion(12, 0))
            {
                if (Server.HttpServerRequest.Ins.DataManager.IsLgoin)
                {
                    var result = "-1";
                    if (intent.ControlType == "1")
                    {
                        result = Server.HttpServerRequest.Ins.ExecuteScene(intent.ControlId);
                    }
                    else
                    {
                        var security = Newtonsoft.Json.JsonConvert.DeserializeObject<SecurityState>(intent.ControlJSONStr);
                        var sendObj = new List<SecurityState>() { new SecurityState() {
                             gatewayId =security.gatewayId,sid = security.sid, status = security.status, userSecurityId = security.userSecurityId
                        } };
                        result = Server.HttpServerRequest.Ins.SetSecurityStatus(sendObj);
                    }
                    if (result == "0")
                    {
                        var rsp = new HDLRunSceneIntentResponse(HDLRunSceneIntentResponseCode.Success, null);
                        if (NSLocale.PreferredLanguages[0].Contains("zh-"))
                        {
                            rsp.SuccessMessage = "执行成功";
                        }
                        else
                        {
                            rsp.SuccessMessage = "Successful execution";
                        }
                        completion(rsp);
                    }
                    else
                    {
                        var rsp = new HDLRunSceneIntentResponse(HDLRunSceneIntentResponseCode.Failure, null);
                        if (NSLocale.PreferredLanguages[0].Contains("zh-"))
                        {
                            rsp.SuccessMessage = "执行失败";
                        }
                        else
                        {
                            rsp.SuccessMessage = "Execution failed";
                        }
                        completion(rsp);
                    }
                }
                else
                {
                    var rsp = new HDLRunSceneIntentResponse(HDLRunSceneIntentResponseCode.Failure, null);
                    if (NSLocale.PreferredLanguages[0].Contains("zh-"))
                    {
                        rsp.SuccessMessage = "账号未登录";
                    }
                    else
                    {
                        rsp.SuccessMessage = "Not logged in to the app";
                    }
                    completion(rsp);
                }
            }
            else
            {
                var rsp = new HDLRunSceneIntentResponse(HDLRunSceneIntentResponseCode.ContinueInApp, null);
                rsp.SuccessMessage = "Ok";
                completion(rsp);
            }
        }
    }
    /// <summary>
    /// 安防状态配置
    /// </summary>
    public class SecurityState
    {
        /// <summary>
        /// 安防云端id
        /// </summary>
        public string userSecurityId;
        /// <summary>
        /// 网关id 网关id 如果传的是sid该字段需要传
        /// </summary>
        public string gatewayId;
        /// <summary>
        /// 安防sid
        /// </summary>
        public string sid;
        /// <summary>
        /// 状态 enable布防、disable撒防
        /// </summary>
        public string status;
    }
}
SiriIntents/Info.plist
New file
@@ -0,0 +1,44 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>CFBundleIdentifier</key>
    <string>com.hdl.onpro.siri</string>
    <key>CFBundleDevelopmentRegion</key>
    <string>en</string>
    <key>CFBundleInfoDictionaryVersion</key>
    <string>6.0</string>
    <key>CFBundlePackageType</key>
    <string>XPC!</string>
    <key>CFBundleShortVersionString</key>
    <string>1.3.202111171</string>
    <key>CFBundleVersion</key>
    <string>1.3.11171</string>
    <key>MinimumOSVersion</key>
    <string>12.0</string>
    <key>NSExtension</key>
    <dict>
        <key>NSExtensionAttributes</key>
        <dict>
            <key>IntentsRestrictedWhileLocked</key>
            <array>
                <string>HDLRunSceneIntent</string>
            </array>
            <key>IntentsSupported</key>
            <array>
                <string>HDLRunSceneIntent</string>
            </array>
            <key>IntentsRestrictedWhileProtectedDataUnavailable</key>
            <array>
                <string>HDLRunSceneIntent</string>
            </array>
        </dict>
        <key>NSExtensionPointIdentifier</key>
        <string>com.apple.intents-service</string>
        <key>NSExtensionPrincipalClass</key>
        <string>IntentHandler</string>
    </dict>
    <key>CFBundleDisplayName</key>
    <string>SiriIntents</string>
</dict>
</plist>
SiriIntents/IntentHandler.cs
New file
@@ -0,0 +1,134 @@
using System;
using System.Collections.Generic;
using Foundation;
using HDLSceneSiri;
using Intents;
namespace SiriIntents
{
    // As an example, this class is set up to handle Message intents.
    // You will want to replace this or add other intents as appropriate.
    // The intents you wish to handle must be declared in the extension's Info.plist.
    // You can test your example integration by saying things to Siri like:
    // "Send a message using <myApp>"
    // "<myApp> John saying hello"
    // "Search for messages in <myApp>"
    [Register("IntentHandler")]
    public class IntentHandler : INExtension//, IINSendMessageIntentHandling, IINSearchForMessagesIntentHandling, IINSetMessageAttributeIntentHandling
    {
        protected IntentHandler(IntPtr handle) : base(handle)
        {
            // Note: this .ctor should not contain any initialization logic.
        }
        public override NSObject GetHandler(INIntent intent)
        {
            // This is the default implementation.  If you want different objects to handle different intents,
            // you can override this and return the handler you want for that particular intent.
            if (intent is HDLRunSceneIntent)
            {
                return new HDLRunSceneIntentHandlder();
            }
            return this;
        }
        //// Implement resolution methods to provide additional information about your intent (optional).
        //[Export("resolveRecipientsForSearchForMessages:withCompletion:")]
        //public void ResolveRecipients(INSendMessageIntent intent, Action<INPersonResolutionResult[]> completion)
        //{
        //    var recipients = intent.Recipients;
        //    // If no recipients were provided we'll need to prompt for a value.
        //    if (recipients.Length == 0)
        //    {
        //        completion(new INPersonResolutionResult[] { INPersonResolutionResult.NeedsValue });
        //        return;
        //    }
        //    var resolutionResults = new List<INPersonResolutionResult>();
        //    foreach (var recipient in recipients)
        //    {
        //        var matchingContacts = new INPerson[] { recipient }; // Implement your contact matching logic here to create an array of matching contacts
        //        if (matchingContacts.Length > 1)
        //        {
        //            // We need Siri's help to ask user to pick one from the matches.
        //            resolutionResults.Add(INPersonResolutionResult.GetDisambiguation(matchingContacts));
        //        }
        //        else if (matchingContacts.Length == 1)
        //        {
        //            // We have exactly one matching contact
        //            resolutionResults.Add(INPersonResolutionResult.GetSuccess(recipient));
        //        }
        //        else
        //        {
        //            // We have no contacts matching the description provided
        //            resolutionResults.Add(INPersonResolutionResult.Unsupported);
        //        }
        //    }
        //    completion(resolutionResults.ToArray());
        //}
        //[Export("resolveContentForSendMessage:withCompletion:")]
        //public void ResolveContent(INSendMessageIntent intent, Action<INStringResolutionResult> completion)
        //{
        //    var text = intent.Content;
        //    if (!string.IsNullOrEmpty(text))
        //        completion(INStringResolutionResult.GetSuccess(text));
        //    else
        //        completion(INStringResolutionResult.NeedsValue);
        //}
        //// Once resolution is completed, perform validation on the intent and provide confirmation (optional).
        //[Export("confirmSendMessage:completion:")]
        //public void ConfirmSendMessage(INSendMessageIntent intent, Action<INSendMessageIntentResponse> completion)
        //{
        //    // Verify user is authenticated and your app is ready to send a message.
        //    var userActivity = new NSUserActivity("INSendMessageIntent");
        //    var response = new INSendMessageIntentResponse(INSendMessageIntentResponseCode.Ready, userActivity);
        //    completion(response);
        //}
        //// Handle the completed intent (required).
        //public void HandleSendMessage(INSendMessageIntent intent, Action<INSendMessageIntentResponse> completion)
        //{
        //    // Implement your application logic to send a message here.
        //    var userActivity = new NSUserActivity("INSendMessageIntent");
        //    var response = new INSendMessageIntentResponse(INSendMessageIntentResponseCode.Success, userActivity);
        //    completion(response);
        //}
        //// Implement handlers for each intent you wish to handle.
        //// As an example for messages, you may wish to add HandleSearchForMessages and HandleSetMessageAttribute.
        //public void HandleSearchForMessages(INSearchForMessagesIntent intent, Action<INSearchForMessagesIntentResponse> completion)
        //{
        //    // Implement your application logic to find a message that matches the information in the intent.
        //    var userActivity = new NSUserActivity("INSearchForMessagesIntent");
        //    var response = new INSearchForMessagesIntentResponse(INSearchForMessagesIntentResponseCode.Success, userActivity);
        //    // Initialize with found message's attributes
        //    var sender = new INPerson(new INPersonHandle("sarah@example.com", INPersonHandleType.EmailAddress), null, "Sarah", null, null, null);
        //    var recipient = new INPerson(new INPersonHandle("+1-415-555-5555", INPersonHandleType.PhoneNumber), null, "John", null, null, null);
        //    var message = new INMessage("identifier", "I am so excited about SiriKit!", NSDate.Now, sender, new INPerson[] { recipient });
        //    response.Messages = new INMessage[] { message };
        //    completion(response);
        //}
        //public void HandleSetMessageAttribute(INSetMessageAttributeIntent intent, Action<INSetMessageAttributeIntentResponse> completion)
        //{
        //    // Implement your application logic to set the message attribute here.
        //    var userActivity = new NSUserActivity("INSetMessageAttributeIntent");
        //    var response = new INSetMessageAttributeIntentResponse(INSetMessageAttributeIntentResponseCode.Success, userActivity);
        //    completion(response);
        //}
    }
}
SiriIntents/Server/HttpServerRequest.cs
New file
@@ -0,0 +1,101 @@
using System.Collections.Generic;
using SiriKit;
namespace SiriIntents.Server
{
    public class HttpServerRequest
    {
        static HttpServerRequest _httpServerRequest;
        public static HttpServerRequest Ins {
            get
            {
                if(_httpServerRequest == null)
                {
                    _httpServerRequest = new HttpServerRequest();
                }
                return _httpServerRequest;
            }
        }
        SceneDateManager _dateManager;
        public SceneDateManager DataManager {
            get
            {
                if(_dateManager== null)
                {
                    _dateManager = new SceneDateManager();
                }
                return _dateManager;
            }
        }
        #region ■ 通用请求接口_______________________
        /// <summary>
        /// 根椐用户账号获取注册区域 免登录 // 检测账号是否注册也用这个接口
        /// </summary>
        /// <param name="account"></param>
        /// <returns></returns>
        public ResponsePackNew GetRegionByAccount(string account)
        {
            var requestJson = HttpUtil.GetSignRequestJson(new RegionByAccountObj() { account = account });
            return HttpUtil.RequestHttpsPost(NewAPI.API_POST_GetRegionByAccount, requestJson, HttpUtil.GlobalRequestHttpsHost);
        }
        /// <summary>
        /// 刷新Token
        /// </summary>
        /// <returns></returns>
        public string RefreshToken()
        {
            var requestJson = HttpUtil.GetSignRequestJson(new RefreshTokenObj()
            {
                refreshToken = DataManager.RefreshToken,
            });
            var revertObj = HttpUtil.RequestHttpsPost(NewAPI.API_POST_Login, requestJson);
            if (revertObj.Code == StateCode.SUCCESS)
            {
                var revertData = Newtonsoft.Json.JsonConvert.DeserializeObject<UserLoginRes>(revertObj.Data.ToString());
                DataManager.RefreshToken = revertData.refreshToken;
                DataManager.AccessToken = revertData.headerPrefix + revertData.accessToken;
            }
            return revertObj.Code;
        }
        #endregion
        /// <summary>
        /// 执行场景
        /// </summary>
        /// <returns></returns>
        public string ExecuteScene(string userSceneId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DataManager.HomeId);
            d.Add("userSceneIds", new List<string>() { userSceneId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(
                NewAPI.Api_Post_ExecuteSecne, requestJson).Code;
        }
        /// <summary>
        /// 设置安防防区状态
        /// </summary>
        public string SetSecurityStatus(object securityStates)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DataManager.HomeId);
            d.Add("securitys", securityStates);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome(
                NewAPI.Api_Post_Security_StatusSet, requestJson);
            return pack.Code;
        }
    }
}
SiriIntents/Server/HttpUtil.cs
New file
@@ -0,0 +1,412 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Security.Cryptography;
using System.Text;
using RestSharp;
namespace SiriIntents.Server
{
    public class HttpUtil
    {
        #region **********全局常量**********
        /// <summary>
        /// 固定域名,正式环境
        /// 公共域名就近解析
        /// </summary>
        //public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com";
        public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";//mmmm
        /// <summary>
        /// RegionMark
        /// </summary>
        public const string RegionMark = "HDL";
        /// <summary>
        /// 请求超时时间
        /// </summary>
        public const int TIME_OUT = 15;
        /// <summary>
        /// 特殊接口请求超时时间
        /// </summary>
        public const int TIME_OUT_LONG = 20;
        /////// <summary>
        /////// Bearer 暂时设为空,从登陆成功的返回的headerPrefix参数动态获取
        /////// </summary>
        //public const string TOKEN_BEARER = "Bearer ";
        #endregion
        #region **********网络请求封装**********
        /// <summary>
        /// POST请求方法 body参数
        /// 针对住宅相关接口封装
        /// 调用住宅当前所在区域域名
        /// 如果是分享住宅,使用主人的token进行相关操作
        /// </summary>
        /// <param name="apiPath"></param>
        /// <param name="bodyParameterJson"></param>
        /// <param name="mTimeout"></param>
        /// <returns></returns>
        public static ResponsePackNew RequestHttpsPostFroHome(string apiPath, string bodyParameterJson, int mTimeout = TIME_OUT)
        {
            string urlHead = HttpServerRequest.Ins.DataManager.RegionUrl;
            //var replaceToken = "";
            //if (DB_ResidenceData.residenceData.residecenInfo.IsOthreShare)
            //{
            //    replaceToken = DB_ResidenceData.residenceData.MasterToken;
            //}
            return RequestHttps(Method.POST, apiPath, bodyParameterJson, null, null, urlHead, "", mTimeout);
        }
        /// <summary>
        /// POST请求方法 body参数
        /// </summary>
        /// <param name="apiPath"></param>
        /// <param name="bodyParameterJson"></param>
        /// <param name="urlHead"></param>
        /// <param name="needErrorTip"></param>
        /// <param name="replaceToken"></param>
        /// <param name="mTimeout"></param>
        /// <returns></returns>
        public static ResponsePackNew RequestHttpsPost(string apiPath, string bodyParameterJson, string urlHead = "", string replaceToken = "", int mTimeout = TIME_OUT)
        {
            return RequestHttps(Method.POST, apiPath, bodyParameterJson, null, null, urlHead, replaceToken, mTimeout);
        }
        /// <summary>
        /// POST请求方法 queryDictionary
        /// </summary>
        /// <param name="apiPath"></param>
        /// <param name="queryDictionary"></param>
        /// <param name="urlHead"></param>
        /// <param name="needErrorTip"></param>
        /// <param name="replaceToken"></param>
        /// <param name="mTimeout"></param>
        /// <returns></returns>
        public static ResponsePackNew RequestHttpsPost(string apiPath, Dictionary<string, object> queryDictionary, string urlHead = "", string replaceToken = "", int mTimeout = TIME_OUT)
        {
            return RequestHttps(Method.POST, apiPath, null, queryDictionary, null, urlHead, replaceToken, mTimeout);
        }
        /// <summary>
        /// 通用  请求服务器方法
        /// </summary>
        /// <param name="method"></param>
        /// <param name="apiPath"></param>
        /// <param name="bodyParameterJson"></param>
        /// <param name="queryDictionary"></param>
        /// <param name="urlSegmentDictionary"></param>
        /// <param name="urlHead"></param>
        /// <param name="replaceToken"></param>
        /// <param name="mTimeout"></param>
        /// <returns></returns>
        static ResponsePackNew RequestHttpsBase(Method method, string apiPath, string bodyParameterJson = null, Dictionary<string, object> queryDictionary = null, Dictionary<string, object> urlSegmentDictionary = null, string urlHead = "", string replaceToken = "", int mTimeout = TIME_OUT)
        {
            //Dome模式登录
            #region HttpWebRequest
            try
            {
                string requestFullUrl = urlHead + apiPath;
                RestClient client = new RestClient(requestFullUrl);
                RestRequest request = new RestRequest(method);
                request.Timeout = mTimeout * 1000;
                request.AddHeader("content-type", "application/json");
                request.AddHeader("Authorization", HttpServerRequest.Ins.DataManager.AccessToken);
                if (bodyParameterJson != null)
                {
                    request.AddParameter("application/json", bodyParameterJson, ParameterType.RequestBody);
                }
                if (queryDictionary != null)
                {
                    foreach (var data in queryDictionary)
                    {
                        request.AddQueryParameter(data.Key, data.Value.ToString());
                    }
                }
                if (urlSegmentDictionary != null)
                {
                    foreach (var data in urlSegmentDictionary)
                    {
                        request.AddUrlSegment(data.Key, data.Value.ToString());
                    }
                }
                IRestResponse response = client.Execute(request);
                if (response.StatusCode == HttpStatusCode.OK)
                {
                    try
                    {
                        ResponsePackNew revertObj = new ResponsePackNew() { };
                        revertObj = Newtonsoft.Json.JsonConvert.DeserializeObject<ResponsePackNew>(response.Content);
                        //*****一些判空处理*****************
                        if (revertObj.Code == null)
                        {
                            revertObj.Code = StateCode.DATA_EXCEPTION;
                        }
                        if (revertObj.Data == null)
                        {
                            revertObj.Data = "";
                        }
                        //*****一些判空处理*****************
                        return revertObj;
                    }
                    catch (Exception ex)
                    {
                        return new ResponsePackNew() { Code = StateCode.DATA_EXCEPTION };
                    }
                }
                else
                {
                    return new ResponsePackNew() { Code = StateCode.NETWORK_ERROR };
                }
            }
            catch (Exception ex)
            {
                return new ResponsePackNew() { Code = StateCode.NETWORK_ERROR };
            }
            #endregion
        }
        /// <summary>
        /// 通用  请求服务器方法
        /// 增加token过期处理
        /// </summary>
        /// <param name="method"></param>
        /// <param name="apiPath"></param>
        /// <param name="bodyParameterJson"></param>
        /// <param name="queryDictionary"></param>
        /// <param name="urlSegmentDictionary"></param>
        /// <param name="urlHead"></param>
        /// <param name="replaceToken"></param>
        /// <param name="mTimeout"></param>
        /// <returns></returns>
        public static ResponsePackNew RequestHttps(Method method, string apiPath, string bodyParameterJson = null, Dictionary<string, object> queryDictionary = null, Dictionary<string, object> urlSegmentDictionary = null, string urlHead = "", string replaceToken = "", int mTimeout = TIME_OUT)
        {
            var responsePackNew = RequestHttpsBase(method, apiPath, bodyParameterJson, queryDictionary, urlSegmentDictionary, urlHead, replaceToken, mTimeout);
            //*****************Token过期处理*****************
            if (responsePackNew.Code == StateCode.TOKEN_EXPIRED)
            {
                //刷新Token
                if (RefreshToken()) {
                    return RequestHttpsBase(method, apiPath, bodyParameterJson, queryDictionary, urlSegmentDictionary, urlHead, replaceToken, mTimeout);
                }
                else
                {
                    return responsePackNew;
                }
            }
            //*****************Token过期处理*****************
            return responsePackNew;
        }
        /// <summary>
        /// 刷新  Token
        /// </summary>
        /// <returns></returns>
        static bool RefreshToken()
        {
            try
            {
                var requestJson = GetSignRequestJson(new RefreshTokenObj()
                {
                    refreshToken = HttpServerRequest.Ins.DataManager.RefreshToken,
                });
                var revertObj = RequestHttpsBase(Method.POST, NewAPI.API_POST_Login, requestJson);
                if (revertObj.Code == StateCode.SUCCESS)
                {
                    var revertData = Newtonsoft.Json.JsonConvert.DeserializeObject<UserLoginRes>(revertObj.Data.ToString());
                    HttpServerRequest.Ins.DataManager.AccessToken = revertData.headerPrefix + revertData.accessToken;
                    HttpServerRequest.Ins.DataManager.RefreshToken = revertData.refreshToken;
                    return true;
                }
                return false;
            }
            catch
            {
                return false;
            }
        }
        #endregion
        #region **********签名校验**********
        /// <summary>
        ///
        /// </summary>
        const string APP_KEY = "HDL-HOME-APP-TEST";
        /// <summary>
        ///
        /// </summary>
        const string SECRET_KEY = "WeJ8TY88vbakCcnvH8G1tDUqzLWY8yss";
        /// <summary>
        /// 获取当前时间戳值
        /// </summary>
        /// <returns></returns>
        static string GetTimestamp()
        {
            System.DateTime startTime = TimeZone.CurrentTimeZone.ToLocalTime(new System.DateTime(1970, 1, 1)); // 当地时区
            return ((long)(DateTime.Now - startTime).TotalMilliseconds).ToString(); // 相差秒数
            //return ((long)(DateTime.Now - startTime).TotalSeconds).ToString(); // 相差秒数
        }
        /// <summary>
        ///
        /// </summary>
        /// <param name="signstr"></param>
        /// <returns></returns>
        static string SignMD5Encrypt(string s)
        {
            byte[] sign = MD5.Create().ComputeHash(UTF8Encoding.UTF8.GetBytes(s));
            string signstr = string.Empty;
            foreach (byte item in sign)
            {
                signstr += item.ToString("X2");
            }
            return signstr.ToLower();
        }
        /// <summary>
        /// 判断当前值是否需要参与签名,保持跟云端一致
        /// 空字符串不参与
        /// 数组,集合,对象不参与
        /// </summary>
        /// <param name="valueStr"></param>
        /// <returns></returns>
        static bool IfValueNeedSign(string valueStr)
        {
            if (string.IsNullOrEmpty(valueStr) || valueStr.StartsWith("{") || valueStr.StartsWith("["))
            {
                return false;
            }
            return true;
        }
        /// <summary>
        /// 2020-11-02
        /// 基础服务的接口都要校验sign
        /// 计算sign签名
        /// </summary>
        /// <returns></returns>
        public static string GetSignRequestJson(object requestObj,Dictionary<string,object> paramDictionary = null)
        {
            try
            {
                //1. 将model实体转为Dictionary<string, object>
                if (paramDictionary == null)
                {
                    paramDictionary = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<string, object>>(Newtonsoft.Json.JsonConvert.SerializeObject(requestObj));
                }
                //2. 计算sign
                if (paramDictionary != null)
                {
                    paramDictionary.Add("appKey", APP_KEY);
                    paramDictionary.Add("timestamp", GetTimestamp());
                    //2.1 字典升序
                    paramDictionary = paramDictionary.OrderBy(o => o.Key).ToDictionary(o => o.Key, p => p.Value);
                    //2.2 拼接按URL键值对
                    string str = string.Empty;
                    foreach (KeyValuePair<string, object> item in paramDictionary)
                    {
                        //Value为null不参加校验
                        if (item.Value != null)
                        {
                            //Value.ToString()为null或者""也不参加校验
                            //if (!string.IsNullOrEmpty(item.Value.ToString()) && (item.Value is string || item.Value.GetType().IsValueType))
                            //{
                            //检测当前参数是否需要参与校验
                            if (IfValueNeedSign(item.Value.ToString()))
                            {
                                //如果是bool类型,要转小写
                                if (item.Value is bool)
                                {
                                    str += item.Key + "=" + item.Value.ToString().ToLower() + "&";
                                }
                                else
                                {
                                    str += item.Key + "=" + item.Value.ToString() + "&";
                                }
                            }
                        }
                    }
                    //2.3 拼接SECRET_KEY
                    str = str.Substring(0, str.Length - 1) + SECRET_KEY;
                    //2.4 MD5转换+转小写
                    var signstr = SignMD5Encrypt(str);
                    paramDictionary.Add("sign", signstr);
                    var signResult = Newtonsoft.Json.JsonConvert.SerializeObject(paramDictionary);
                    return signResult;
                }
                else
                {
                    return "";
                }
            }
            catch
            {
                return "";
            }
        }
        #endregion
    }
    /// <summary>
    /// 响应参数
    /// </summary>
    [Serializable]
    public class ResponsePackNew
    {
        /// <summary>
        /// 响应状态码
        /// </summary>
        public string Code;
        /// <summary>
        /// 响应内容
        /// </summary>
        public object Data;
        /// <summary>
        /// 响应错误信息
        /// </summary>
        public string message = "";
        /// <summary>
        /// 这个是请求错误时的扩展数据,以后所有的附带扩展数据都会放在这里面动态维护
        /// </summary>
        public object extra;
        ///// <summary>
        ///// isSuccess
        ///// </summary>
        //public bool isSuccess;
        ///// <summary>
        ///// timestamp
        ///// </summary>
        //public string timestamp;
    }
}
SiriIntents/Server/IMessageCommon.cs
New file
@@ -0,0 +1,151 @@
using System;
using System.Collections.Generic;
namespace SiriIntents.Server
{
    /// <summary>
    /// 接口类的返回信息
    /// </summary>
    public class IMessageCommon
    {
        /// <summary>
        /// 接口类的返回信息
        /// </summary>
        private static IMessageCommon m_Current = null;
        /// <summary>
        /// 接口类的返回信息
        /// </summary>
        public static IMessageCommon Current
        {
            get
            {
                if (m_Current == null)
                {
                    m_Current = new IMessageCommon();
                }
                return m_Current;
            }
        }
        /// <summary>
        /// 是否在获取token
        /// </summary>
        public bool isGetingToken;
        /// <summary>
        /// 无视错误(访问云端时,此操作将不会弹出错误)
        /// </summary>
        public bool IgnoreError = false;
        ///// <summary>
        ///// 全部信息
        ///// </summary>
        //private Dictionary<string, Dictionary<string, int>> dicMsg = null;
        /// <summary>
        /// 通用错误码
        /// </summary>
        private Dictionary<string, int> stateCodeDic = null;
        /// <summary>
        /// 根据接口的状态码,翻译返回信息
        /// </summary>
        /// <param name="requestName">接口</param>
        /// <param name="revertObj">云端返回的数据</param>
        /// <param name="pra">请求参数</param>
        /// <returns></returns>
        public string GetMsgByRequestName(string statuCode)
        {
            if (IgnoreError == true)
            {
                //无视错误
                return null;
            }
            //共通码
            if (stateCodeDic.ContainsKey(statuCode) == true)
            {
                return "-1";// Language.StringByID(stateCodeDic[statuCode]);
            }
            //if (dicMsg.ContainsKey(requestName) == true && dicMsg[requestName].ContainsKey(statuCode) == true)
            //{
            //    //在册的Msg
            //    return Language.StringByID(dicMsg[requestName][statuCode]);
            //}
            return "-1";//Language.StringByID(StringId.FailedRequestServer) + "\n(" + statuCode + ")";
        }
        /// <summary>
        /// StartRefreshToken
        /// </summary>
        public void StartRefreshToken()
        {
            if (isGetingToken) return;
            new System.Threading.Thread(() =>
            {
                isGetingToken = true;
                try
                {
                    var success = new HttpServerRequest().RefreshToken();
                }
                catch
                {
                }
                finally
                {
                    isGetingToken = false;
                }
            })
            { IsBackground = true }.Start();
        }
    }
    /// <summary>
    /// 常用状态码管理
    /// </summary>
    public class StateCode
    {
        /// <summary>
        /// 网络请求异常
        /// APP自定义错误码
        /// </summary>
        public const string NETWORK_ERROR = "-1";
        /// <summary>
        /// 数据解析错误
        /// APP自定义错误码
        /// </summary>
        public const string DATA_EXCEPTION = "-2";
        /// <summary>
        /// 请求成功的状态码
        /// </summary>
        public const string SUCCESS = "0";
        /// <summary>
        /// 验证码校验失败
        /// </summary>
        public const string VERIFICATION_CODE_WRONG = "14";
        /// <summary>
        /// 会话超时,请更新token
        /// </summary>
        public const string TOKEN_EXPIRED = "10001";
        /// <summary>
        /// 账号不存在的错误码
        /// </summary>
        public const string ACCOUNT_NOT_EXIST = "10010";
        /// <summary>
        /// 登录锁定,密码错误次数过多
        /// 密码输入错误超过10次,请30分钟后重试!
        /// </summary>
        public const string AccountLoginLock = "10019";
    }
}
SiriIntents/Server/NewAPI.cs
New file
@@ -0,0 +1,756 @@
using System;
namespace SiriIntents.Server
{
    public class NewAPI
    {
        //#region 新微服务接口
        //***********************************************
        //注意:和住宅相关的接口要请求住宅所在区域的域名   regionUrl
        //***********************************************
        #region ■ RegionCluster -- 全球区域列表___________________________
        /// <summary>
        /// 根椐用户账号获取注册区域 免登录 // 检测账号是否注册也用这个接口
        /// </summary>
        public const string API_POST_GetRegionByAccount = "/smart-footstone/region/regionByAccount";
        /// <summary>
        /// 获取全球区域列表 免登录
        /// </summary>
        public const string API_POST_GlobalRegionList = "/smart-footstone/region/globalRegionList";
        #endregion
        #region ■ AcCluster -- 登录和注册部分___________________________
        /// <summary>
        /// 帐号登录
        /// </summary>
        public const string API_POST_Login = "/smart-footstone/member/oauth/login";
        /// <summary>
        /// 输入验证码注册
        /// </summary>
        public const string API_POST_Member_Register = "/smart-footstone/member/oauth/register";
        /// <summary>
        /// 用户找回密码
        /// </summary>
        public const string API_POST_Member_ForgetPwd = "/smart-footstone/member/oauth/forgetPwd";
        /// <summary>
        /// 修改密码
        /// </summary>
        public const string API_POST_Update_Pwd = "/smart-footstone/member/memberInfo/updatePwd";
        /// <summary>
        /// 发送验证码
        /// </summary>
        public const string API_POST_Verification_Send = "/smart-footstone/verification/message/send";
        /// <summary>
        /// 验证消息验证码
        /// </summary>
        public const string API_POST_Verification_Check = "/smart-footstone/verification/message/check";
        #region 用户信息、头像、绑定认证(手机/邮箱)
        /// <summary>
        /// 获取个人信息
        /// </summary>
        public const string API_POST_Member_GetMemberInfo = "/smart-footstone/member/memberInfo/getMemberInfo";
        /// <summary>
        /// 更新个人信息
        /// </summary>
        public const string API_POST_Member_UpdateMemberInfo = "/smart-footstone/member/memberInfo/updateMemberInfo";
        /// <summary>
        /// 根据账号获取个人信息
        /// </summary>
        public const string API_POST_Member_GetMemberInfoByAccount = "/smart-footstone/member/memberInfo/getMemberInfoByAccount";
        ///// <summary>
        ///// 上传头像
        ///// </summary>
        //public const string API_POST_Head_Upload = "/home-wisdom/app/head/portrait/upload";
        ///// <summary>
        ///// 下载头像
        ///// </summary>
        //public const string API_POST_Head_Down = "/home-wisdom/app/head/portrait/down";
        ///// <summary>
        ///// 根据账号下载头像
        ///// </summary>
        //public const string API_POST_Head_DownWithAccount = "/home-wisdom/app/head/portrait/downWithAccount";
        /// <summary>
        /// 绑定认证(手机/邮箱)
        /// </summary>
        public const string API_POST_Member_BindWithAccount = "/smart-footstone/member/memberInfo/bindWithAccount";
        /// <summary>
        /// 解绑认证(手机/邮箱)
        /// </summary>
        public const string API_POST_Member_UnbindWithAccount = "/smart-footstone/member/memberInfo/unbindWithAccount";
        #endregion
        /// <summary>
        /// 查询功能介绍列表
        /// </summary>
        public const string API_POST_FunctionIntroductionList = "/home-wisdom/app/functionIntroduction/list";
        #endregion
        #region ■ HomeCluster -- 住宅管理接口___________________________
        /// <summary>
        /// 绑定住宅
        /// </summary>
        public const string Api_Post_BindlingResidence = "/app/home/deliver";
        /// <summary>
        /// 获取住宅分页
        /// </summary>
        public const string API_POST_Gethomepager = "/home-wisdom/app/home/list";
        /// <summary>
        /// 删除住宅
        /// </summary>
        public const string API_POST_Home_Delete = "/home-wisdom/app/home/delete";
        /// <summary>
        /// 更新住宅
        /// </summary>
        public const string API_POST_Home_UpdateHome = "/home-wisdom/app/home/update";
        /// <summary>
        /// 住宅迁移
        /// </summary>
        public const string API_POST_Home_Transfer = "/home-wisdom/app/home/transfer";
        /// <summary>
        /// 更改住宅权限
        /// </summary>
        public const string API_Post_Home_UpdateDebugPerm = "/home-wisdom/app/home/updateDebugPerm";
        /// <summary>
        /// 过户
        /// </summary>
        public const string API_Post_TransferResidence = "/home-wisdom/app/home/transfer";
        /// <summary>
        /// 管理员权限迁移
        /// </summary>
        public const string API_Post_AdminAuthorityMigration = "/home-wisdom/app/home/ownerConvert";
        #endregion
        #region ■ 子账号 -- 添加住宅成员___________________________
        /// <summary>
        /// 添加子账户
        /// </summary>
        public const string API_POST_Child_Add = "/home-wisdom/app/child/account/add";
        /// <summary>
        /// 删除子账户
        /// </summary>
        public const string API_POST_Child_Delete = "/home-wisdom/app/child/account/delete";
        /// <summary>
        /// 根据住宅 id 查询所有的子账户
        /// </summary>
        public const string API_POST_Child_FindAll = "/home-wisdom/app/child/account/findAll";
        /// <summary>
        /// 更新远程控制
        /// </summary>
        public const string API_POST_Child_Update = "/home-wisdom/app/child/account/update";
        /// <summary>
        /// 子账号管理员获取主账号授权Token
        /// </summary>
        public const string API_POST_Child_GetMasterToken = "/home-wisdom/app/child/account/masterToken/get";
        ///// <summary>
        ///// 下载子账号头像
        ///// </summary>
        //public const string API_POST_Child_DownloadHeadImage = "/home-wisdom/app/child/account/getHeadPortrait";
        /// <summary>
        /// 下载账号头像
        /// </summary>
        public const string API_POST_DownloadHeadImage = "/home-wisdom/app/head/portrait/downWithAccount";
        #region 数据分享
        /// <summary>
        /// 分享指定文件给指定成员
        /// </summary>
        public const string API_POST_Home_Share_Add = "/home-wisdom/app/home/share/add";
        /// <summary>
        /// 查询指定成员的所有分享文件
        /// </summary>
        public const string API_POST_Home_Share_FindAll = "/home-wisdom/app/home/share/findAll";
        /// <summary>
        /// 下载指定的分享文件
        /// </summary>
        public const string API_POST_Home_Share_DownOne = "/home-wisdom/app/home/share/downOne";
        /// <summary>
        /// 删除指定的分享文件
        /// </summary>
        public const string API_POST_Home_Share_Delete = "/home-wisdom/app/home/share/delete";
        #endregion
        #endregion
        #region  ■ GatewayCluster -- 网关___________________________
        ///// <summary>
        ///// 绑定网关到住宅
        ///// </summary>
        //public const string API_POST_BindGateway = "/home-wisdom/app/gateway/bindGateway";
        /// <summary>
        /// 获取住宅网关分页
        /// </summary>
        public const string API_POST_GetGatewayList = "/home-wisdom/app/gateway/getGatewayList";
        /// <summary>
        /// 获取网关信息
        /// </summary>
        public const string Api_Post_GetGatewayInfo = "/home-wisdom/app/gateway/info";
        ///// <summary>
        ///// 解绑绑网关到住宅
        ///// </summary>
        public const string API_POST_UntieGateway = "/home-wisdom/app/gateway/untieGateway";
        #endregion
        #region ■ GatewayCenterCluster -- 网关中心服务器___________________________
        ///// <summary>
        ///// 网关登录
        ///// </summary>
        //public const string API_POST_GatewayLogin = "/GatewayCenterCluster/V1/gatewayLogin";
        #endregion
        #region ■ ClientCenterCluster -- 客户端中心服务器___________________________
        /// <summary>
        /// 获取远程连接
        /// </summary>
        public const string API_POST_GetMqttRemoteInfo = "/home-wisdom/app/mqtt/getRemoteInfo";
        #endregion
        #region ■ HomebackupCluster -- 住宅备份微服务___________________________
        ///// <summary>
        ///// 创建文件夹
        ///// </summary>
        //public const string API_POST_Folder_Create = "/home-wisdom/app/backup/folder/create";
        ///// <summary>
        ///// 删除文件夹
        ///// </summary>
        //public const string API_POST_Folder_Delete = "/home-wisdom/app/backup/folder/delete";
        ///// <summary>
        ///// 查找所有文件夹
        ///// </summary>
        //public const string API_POST_Folder_FindAll = "/home-wisdom/app/backup/folder/findAll";
        ///// <summary>
        ///// 更新文件夹
        ///// </summary>
        //public const string API_POST_Folder_Update = "/home-wisdom/app/backup/folder/update";
        ///// <summary>
        ///// 上传文件
        ///// </summary>
        //public const string API_POST_File_Create = "/home-wisdom/app/backup/file/create";
        /////// <summary>
        /////// 删除文件
        /////// </summary>
        ////public const string API_DELETE_File_Delete = "/HomebackupCluster/V1/file/delete";
        ///// <summary>
        ///// 下载备份文件
        ///// </summary>
        //public const string API_POST_File_Down = "/home-wisdom/app/backup/file/downOne";
        ///// <summary>
        ///// 查询一个文件夹所有文件名
        ///// </summary>
        //public const string API_POST_File_FindAll = "/home-wisdom/app/backup/file/findAll";
        #endregion
        #region ■ Speaker -- 语音控制服务___________________________
        /// <summary>
        /// 获取已授权的音箱列表
        /// </summary>
        public const string API_POST_Speaker_List_Get = "/smart-footstone/app/token/list";
        /// <summary>
        /// 编辑音箱授权备注
        /// </summary>
        public const string API_POST_Speaker_Remark_Update = "/smart-footstone/app/token/update";
        /// <summary>
        /// 解绑音箱
        /// </summary>
        public const string API_POST_Speaker_Unbind = "/smart-footstone/app/token/delete";
        /// <summary>
        /// 获取音箱分配的设备和场景列表
        /// </summary>
        public const string API_POST_Speaker_DeviceList_Get = "/home-wisdom/app/tokenRelation/list";
        /// <summary>
        /// 更新音箱控制的设备和场景目标
        /// </summary>
        public const string API_POST_Speaker_DeviceList_Update = "/home-wisdom/app/tokenRelation/save";
        #endregion
        #region ■ PushSerivce -- 推送服务接口___________________________
        /// <summary>
        /// 注册推送接口
        /// 批量推送绑定家居社区接口
        /// 2021-09-09 对接新接口支持物业公告推送
        /// communityCodes 不传 默认所有住宅或者小区都收到推送
        /// </summary>
        public const string API_POST_PushSerivce_AddToken = "/smart-footstone/app/push-information/addPushToken";
        /// <summary>
        /// 注销推送接口
        /// 批量解绑家居社区
        /// 2021-09-09 对接新接口支持物业公告推送
        /// </summary>
        public const string API_POST_PushSerivce_DeleteToken = "/smart-footstone/app/push-information/unBindPushToken";
        ///// <summary>
        ///// 添加推送Token
        ///// </summary>
        //public const string API_POST_PushSerivce_AddToken = "/smart-footstone/app/push-information/add";
        ///// <summary>
        ///// 删除推送Token
        ///// </summary>
        //public const string API_POST_PushSerivce_DeleteToken = "/smart-footstone/app/push-information/delete";
        ///// <summary>
        /////// 获取推送消息记录
        /////// </summary>
        //public const string API_POST_PushSerivce_Getpushmessagelist = "/smart-footstone/app/message/list";
        /// <summary>
        /// 获取推送消息记录 分页
        /// </summary>
        public const string API_POST_PushSerivce_Getpushmessagelist_Paging = "/smart-footstone/app/message/page";
        /// <summary>
        /// 清空推送的消息记录
        /// </summary>
        public const string API_POST_PushSerivce_Clearmessagelist = "/smart-footstone/app/message/clear";
        /// <summary>
        /// 标记消息已读
        /// </summary>
        public const string API_POST_PushSerivce_Markread = "/smart-footstone/app/message/read";
        /// <summary>
        /// 标记消息全部已读
        /// </summary>
        public const string API_POST_PushSerivce_ALLMarkread = "/smart-footstone/app/message/read_all";
        /// <summary>
        /// 通过主键id删除一条推送记录
        /// </summary>
        public const string API_POST_PushSerivce_Deletepushinfo = "/smart-footstone/app/message/delete_by_id";
        /// <summary>
        /// 获取物业公告详情
        /// </summary>
        public const string API_POST_PushSerivce_GetNoticeInfo = "/community-footstone/app/notice/info";
        #endregion
        #region ■  -- 检测更新接口___________________________
        /// <summary>
        /// 检测更新,是否需要强制更新
        /// </summary>
        public const string API_POST_CheckAppVersion = "/smart-footstone/app/appVersion/check";
        ///// <summary>
        ///// 查询APP最新版本
        ///// </summary>
        //public const string API_POST_GetAppVersion = "/smart-footstone/app/getAppVersion";
        #endregion
        #region ■  -- 房间场景背景图片上传下载接口___________________________
        /// <summary>
        /// 上传图片
        /// </summary>
        public const string API_POST_UploadImage = "/home-wisdom/app/images/upload_image";
        /// <summary>
        /// 查询图片路径
        /// </summary>
        public const string API_POST_GetImageUrl = "/home-wisdom/app/images/get_image_url";
        #endregion
        #region Kaede -- 设备接口____________________________
        /// <summary>
        /// 获取设备列表
        /// </summary>
        public const string Api_Post_GetDevcieList = "/home-wisdom/app/device/list";
        /// <summary>
        /// 获取第三方品牌设备列表
        /// </summary>
        public const string Api_Post_Get3tyBrandDevcieList = "/home-wisdom/app/product/list";
        /// <summary>
        /// 注册第三方设备
        /// </summary>
        public const string Api_Post_IndependentRegister3TyDevcie = "/home-wisdom/app/device/independentRegister";
        /// <summary>
        /// 获取设备详情
        /// </summary>
        public const string Api_Post_GetDevcieInfoList = "/home-wisdom/app/device/info";
        /// <summary>
        /// 刷新设备状
        /// </summary>
        public const string Api_Post_RefreshDeviceStatus = "/home-wisdom/app/device/status/refresh";
        /// <summary>
        /// 设备控制
        /// </summary>
        public const string Api_Post_ControlDevice = "/home-wisdom/app/device/control";
        /// <summary>
        /// 编辑设备信息
        /// </summary>
        public const string Api_Post_EditDevice = "/home-wisdom/app/device/edit";
        /// <summary>
        /// 设备绑定房间
        /// </summary>
        public const string Api_Post_BindDeviceToRoom = "/home-wisdom/app/device/bindRoom";
        /// <summary>
        /// 设备解绑房间
        /// </summary>
        public const string Api_Post_UnbindDeviceToRoom = "/home-wisdom/app/device/unbindRoom";
        /// <summary>
        /// 设备名称修改
        /// </summary>
        public const string Api_Post_EditDeviceName = "/home-wisdom/app/device/rename";
        /// <summary>
        /// 收藏设备
        /// </summary>
        public const string Api_Post_CollectDevice = "/home-wisdom/app/device/collect";
        /// <summary>
        /// 取消收藏设备
        /// </summary>
        public const string Api_Post_CancelCollectDevice = "/home-wisdom/app/device/cancelCollect";
        /// <summary>
        /// 获取环境传感器历史数据 小时/周/月统计数据
        /// </summary>
        public const string Api_Post_EnvironmentalSensorHistoricalData = "/home-wisdom/app/statistics/device/hourWeekMonth";
        /// <summary>
        /// 获取安防传感器历史数据
        /// </summary>
        public const string Api_Post_ArmSensorHistoricalData = "/home-wisdom/app/device/message";
        /// <summary>
        /// 读取最近一个月的数据
        /// </summary>
        public const string Api_Post_SensorLastMonthHistoricalData = "/home-wisdom/app/statistics/device/monthDiff";
        #endregion
        #region Kaede -- 场景接口____________________________
        /// <summary>
        /// 获取场景列表
        /// </summary>
        public const string Api_Post_GetSecneList = "/home-wisdom/app/scene/list";
        /// <summary>
        /// 获取场景详情
        /// </summary>
        public const string Api_Post_GetSecneInfo = "/home-wisdom/app/scene/info";
        /// <summary>
        /// 添加场景
        /// </summary>
        public const string Api_Post_AddSecne = "/home-wisdom/app/scene/add";
        /// <summary>
        /// 编辑场景
        /// </summary>
        public const string Api_Post_EditSecne = "/home-wisdom/app/scene/update";
        /// <summary>
        /// 删除场景
        /// </summary>
        public const string Api_Post_DeleteSecne = "/home-wisdom/app/scene/delete";
        /// <summary>
        /// 执行场景
        /// </summary>
        public const string Api_Post_ExecuteSecne = "/home-wisdom/app/scene/execute";
        /// <summary>
        /// 收藏场景
        /// </summary>
        public const string Api_Post_CollectScene = "/home-wisdom/app/scene/collect";
        /// <summary>
        /// 取消收藏场景
        /// </summary>
        public const string Api_Post_CancelCollectScene = "/home-wisdom/app/scene/cancelCollect";
        #endregion
        #region Kaede -- 房间接口____________________________
        /// <summary>
        /// 获取设备列表
        /// </summary>
        public const string Api_Post_GetRoomList = "/home-wisdom/app/room/list";
        /// <summary>
        /// 添加房间
        /// </summary>
        public const string Api_Post_AddRoom = "/home-wisdom/app/room/add";
        /// <summary>
        /// 删除房间
        /// </summary>
        public const string Api_Post_DelRoom = "/home-wisdom/app/room/delete";
        /// <summary>
        /// 修改房间
        /// </summary>
        public const string Api_Post_UpdateRoom = "/home-wisdom/app/room/update";
        #endregion
        #region Kaede -- 安防接口____________________________
        /// <summary>
        /// 获取安防列表
        /// </summary>
        public const string Api_Post_Security_List = "/home-wisdom/app/security/list";
        /// <summary>
        /// 获取安防详情
        /// </summary>
        public const string Api_Post_Security_Info = "/home-wisdom/app/security/info";
        /// <summary>
        /// 添加安防
        /// </summary>
        public const string Api_Post_Security_Add = "/home-wisdom/app/security/add";
        /// <summary>
        /// 编辑安防
        /// </summary>
        public const string Api_Post_Security_Edit = "/home-wisdom/app/security/edit";
        /// <summary>
        /// 删除安防
        /// </summary>
        public const string Api_Post_Security_Delete = "/home-wisdom/app/security/delete";
        /// <summary>
        /// 读取安防防区状态
        /// </summary>
        public const string Api_Post_Security_StatusRead = "/home-wisdom/app/security/statusRead";
        /// <summary>
        /// 设置安防防区状态
        /// </summary>
        public const string Api_Post_Security_StatusSet = "/home-wisdom/app/security/statusSet";
        /// <summary>
        /// 安防bypass设置
        /// </summary>
        public const string Api_Post_Security_BypassSet = "/home-wisdom/app/security/bypassSet";
        /// <summary>
        /// 安防bypass读取
        /// </summary>
        public const string Api_Post_Security_BypassRead = "/home-wisdom/app/security/bypassRead";
        /// <summary>
        /// 查询安防所有记录
        /// </summary>
        public const string Api_Post_Security_ListSecurityLog = "/home-wisdom/app/security/listSecurityLog";
        /// <summary>
        /// 查询安防报警记录
        /// </summary>
        public const string Api_Post_Security_ListAlarmLog = "/home-wisdom/app/security/listAlarmLog";
        #endregion
        #region ■  -- 房间、设备、场景分享___________________________
        /// <summary>
        /// 添加分享
        /// </summary>
        public const string API_POST_Share_Add = "/home-wisdom/app/share/add";
        /// <summary>
        /// 删除分享
        /// </summary>
        public const string API_POST_Share_Delete = "/home-wisdom/app/share/delete";
        /// <summary>
        /// 获取分享
        /// </summary>
        public const string API_POST_Share_GetList = "/home-wisdom/app/share/list";
        #endregion
        #region ■  -- 自动化接口___________________________
        /// <summary>
        /// 获取自动化列表
        /// </summary>
        public const string API_POST_Logic_List = "/home-wisdom/app/logic/list";
        /// <summary>
        ///获取自动化详情
        /// </summary>
        public const string API_POST_Logic_Info = "/home-wisdom/app/logic/info";
        /// <summary>
        /// 添加自动化
        /// </summary>
        public const string API_POST_Logic_Add = "/home-wisdom/app/logic/add";
        /// <summary>
        /// 编辑自动化
        /// </summary>
        public const string API_POST_Logic_Update = "/home-wisdom/app/logic/update";
        /// <summary>
        /// 删除自动化
        /// </summary>
        public const string API_POST_Logic_Delete = "/home-wisdom/app/logic/delete";
        /// <summary>
        /// 启用禁用自动化
        /// </summary>
        public const string API_POST_Logic_Enable = "/home-wisdom/app/logic/enable";
        #endregion
        #region -- 第三方设备相关接口___________________________
        /// <summary>
        /// 获取添加过的品牌列表
        /// </summary>
        public const string Api_Post_GetBindBrandList = "/home-wisdom/app/product/brand/bindList";
        /// <summary>
        /// 获取品牌列表
        /// </summary>
        public const string Api_Post_GetBrandList = "/home-wisdom/app/product/brand/list";
        #region ■  -- 红外宝接口___________________________
        /// <summary>
        /// 红外宝设备定位
        /// </summary>
        public const string API_POST_Ir_DeviceFind = "/home-wisdom/app/device/ir/deviceFind";
        /// <summary>
        /// 红外宝下的遥控器列表
        /// </summary>
        public const string API_POST_Ir_List = ":/home-wisdom/app/device/ir/list";
        /// <summary>
        /// 遥控器红外码学习
        /// </summary>
        public const string API_POST_Ir_CodeStudy = "/home-wisdom/app/device/ir/codeStudy";
        /// <summary>
        ///红外宝红外码库试码
        /// </summary>
        public const string API_POST_Ir_CodeTest = "/home-wisdom/app/device/ir/codeTest";
        /// <summary>
        /// 红外宝遥控器添加
        /// </summary>
        public const string API_POST_Ir_Add = "/home-wisdom/app/device/ir/add";
        /// <summary>
        /// 遥控器自学按键删除
        /// </summary>
        public const string API_POST_Ir_CodeRemove = "/home-wisdom/app/device/ir/codeRemove";
        /// <summary>
        /// 获取设备详情通过(spk,sid)
        /// </summary>
        public const string Api_Post_GetinfoBySid = "/home-wisdom/app/device/infoBySid";
        /// <summary>
        /// 红外宝/遥控器删除
        /// </summary>
        public const string API_POST_Ir_DeviceDel = "/home-wisdom/app/device/remove";
        /// <summary>
        /// 修改设备名称
        /// </summary>
        public const string API_POST_Ir_DeviceRename = "/home-wisdom/app/device/rename";
        #endregion
        #endregion
        #region ■  -- 萤石SDK相关接口___________________________
        /// <summary>
        /// 河东获取萤石云子账号token的接口
        /// </summary>
        public const string API_POST_EZ_GetChildToken = "/home-wisdom/platform/yingshi/child/token";
        #endregion
        #region  ■  -- 丰林相关相关接口___________________________
        /// <summary>
        /// 检查住宅是否绑定丰林,并获取门口机列表
        /// </summary>
        public const string API_POST_FL_Check = "/home-wisdom/app/fl/vi/check";
        /// <summary>
        /// 接听
        /// </summary>
        public const string API_POST_FL_Answer = "/home-wisdom/app/fl/vi/answer";
        /// <summary>
        /// 拒接
        /// </summary>
        public const string API_POST_FL_Reject = "/home-wisdom/app/fl/vi/reject";
        /// <summary>
        /// 开锁成功
        /// </summary>
        public const string API_POST_FL_Unlock = "/home-wisdom/app/fl/vi/unlock";
        /// <summary>
        /// 通话视频截图上传
        /// </summary>
        public const string API_POST_FL_Screenshot = "/home-wisdom/app/fl/vi/screenshot";
        /// <summary>
        /// 挂断
        /// </summary>
        public const string API_POST_FL_HangUp = "/home-wisdom/app/fl/vi/hang-up";
        /// <summary>
        /// 删除通话记录
        /// </summary>
        public const string API_POST_FL_DeleteCallInfo = "/home-wisdom/app/fl/vi/delete";
        /// <summary>
        /// 获取门口机列表
        /// </summary>
        public const string API_POST_FL_List = "http://112.74.164.111:180/api.php/Device/getmonitorUUID";
        /// <summary>
        /// 动态密码/二维码开锁
        /// </summary>
        public const string API_POST_FL_QRcode = "http://112.74.164.111:180/api.php/Device/setdynamicpwd";
        #endregion
        #region 可视对讲标准通用接口
        /// <summary>
        /// 获取可视对讲设备列表(所有对接可视对讲都包含一起)
        /// </summary>
        public const string API_POST_VideoDeviceList = "/home-wisdom/platform/imou/listVisualSpeaks";
        /// <summary>
        /// 远程开门
        /// </summary>
        public const string API_POST_VideoDevice_OpenDoorbell = "/home-wisdom/platform/imou/openDoorbell";
        /// <summary>
        /// 更改通话状态
        /// </summary>
        public const string API_POST_VideoDevice_UpdateCallStatus = "/home-wisdom/platform/imou/updateCallStatus";
        /// <summary>
        /// 获取通话记录
        /// </summary>
        public const string API_POST_FL_GetCallList = "/home-wisdom/platform/imou/listCallRecords";
        /// <summary>
        /// 人脸录入
        /// </summary>
        public const string Api_Post_InputUserFace = "/community-wisdom/app/doorDevice/inputUserFaceHouse";
        /// <summary>
        /// 开关人脸功能
        /// </summary>
        public const string Api_Post_SwitchFaceFunction = "/community-wisdom/app/doorDevice/updateCustomerFaceClose";
        /// <summary>
        /// 获取住户详情
        /// </summary>
        public const string Api_Post_GetCustomerInfo = "/basis-footstone/app/customer/detail";
        /// 住宅sip账号获取
        /// </summary>
        public const string API_POST_VideoDevice_GetSipAccount = "/home-wisdom/app/home/getSipAccount";
        #endregion
        #region  ■  -- 门锁相关接口_______________________________
        /// <summary>
        /// 判断门锁是否第一使用
        /// </summary>
        public const string API_POST_DoorisFirstUse = "/home-wisdom/app/device/door/isUserBind";
        /// <summary>
        /// 门锁第一次使用时,绑定的密码
        /// </summary>
        public const string API_POST_DoorBindFirstUsePsw = "/home-wisdom/app/device/door/userBind";
        /// <summary>
        /// 获取门锁所有的密码
        /// </summary>
        public const string API_POST_GetDoorAllPsw = "/home-wisdom/app/device/door/getPwds";
        /// <summary>
        /// 门锁分配密码给用户
        /// </summary>
        public const string API_POST_DoorAssignPswToUser = "/home-wisdom/app/device/door/pwdAllot";
        /// <summary>
        /// 门锁的历史记录
        /// </summary>
        public const string API_POST_DoorHistory = "/home-wisdom/app/device/door/logs";
        #endregion
        #region  ■  -- SIP相关接口_______________________________
        #endregion
        /// <summary>
        /// 绑定source面板
        /// </summary>
        public const string Api_Post_BindSourcePanel = "/home-wisdom/source/screen/home/bind";
    }
    ///// <summary>
    ///// BaseRequestObj
    ///// </summary>
    //[System.Serializable]
    //public class BaseRequestObj
    //{
    //    public string RequestVersion = MainPage.CodeIDString;
    //    public string RequestSource = MainPage.ClientType;
    //    public string LoginAccessToken;
    //}
}
SiriIntents/Server/NewApiRes.cs
New file
@@ -0,0 +1,1510 @@
using System;
using System.Collections.Generic;
namespace SiriIntents.Server
{
    #region  **************************************新服务器**************************************
    [System.Serializable]
    public class BaseNoTokenObj
    {
        //public string RequestVersion = MainPage.CodeIDString;
        ////请求来源
        //public string clientType = MainPage.ClientType;
    }
    [System.Serializable]
    public class NullObj
    {
    }
    #region ■ 全球区域列表 ____________________________
    [System.Serializable]
    public class GetRegionListObj
    {
        /// <summary>
        /// 区域标识
        /// </summary>
        public string regionMark;
    }
    [System.Serializable]
    public class RegionByAccountObj
    {
        /// <summary>
        /// 账号
        /// </summary>
        public string account;
    }
    [System.Serializable]
    public class GlobalRegionListRes
    {
        public string regionId;
        public string regionName;
        public string regionUrl;
    }
    /// <summary>
    /// 分页
    /// </summary>
    public class BasePagingObj
    {
        public int totalCount = 0;
        public int totalPage = 0;
        public int pageNo = 0;
        public int pageSize = 0;
    }
    #endregion
    #region  ■ 登录 ____________________________
    [System.Serializable]
    public class LoginObj
    {
        /// <summary>
        /// 账号
        /// </summary>
        public string account;
        /// <summary>
        /// 密码
        /// </summary>
        public string loginPwd;
        /// <summary>
        /// 授权类型,可用值:captcha,refresh_token,password,verify
        /// </summary>
        public string grantType = "password";
        /// <summary>
        /// 平台 WEB、APP、WX、ALIPAY
        /// </summary>
        public string platform = "APP";
        /// <summary>
        /// 验证码,短信登录时候用
        /// </summary>
        public string verifyCode;
    }
    /// <summary>
    /// 刷新token
    /// </summary>
    [System.Serializable]
    public class RefreshTokenObj
    {
        /// <summary>
        /// refreshToken
        /// </summary>
        public string refreshToken;
        /// <summary>
        /// 授权类型,可用值:captcha,refresh_token,password,verify
        /// </summary>
        public string grantType = "refresh_token";
        /// <summary>
        /// 平台 WEB、APP、WX、ALIPAY
        /// </summary>
        public string platform = "APP";
    }
    /// <summary>
    ///
    /// </summary>
    [Serializable]
    public class UserLoginRes
    {
        /// <summary>
        ///
        /// </summary>
        public string expiresIn;
        /// <summary>
        ///
        /// </summary>
        public string refreshToken;
        /// <summary>
        ///
        /// </summary>
        public string accessToken;
        /// <summary>
        /// 账号类型 "C":C端账号
        /// </summary>
        public string userType;
        /// <summary>
        /// Token "Bearer "
        /// </summary>
        public string headerPrefix;
        /// <summary>
        /// 用户ID
        /// </summary>
        public string userId;
        /// <summary>
        /// 用户名字
        /// </summary>
        public string name;
    }
    /// <summary>
    /// 登录锁定后的异常扩展参数
    /// </summary>
    [Serializable]
    public class AccountLoginLockExtraRes
    {
        /// <summary>
        /// 最大允许的密码错误次数
        /// </summary>
        public int maxPwdErrorNum;
        /// <summary>
        /// 当前错误次数
        /// </summary>
        public int currentPwdErrorNum;
        /// <summary>
        /// 解锁事件
        /// </summary>
        public long unlockTime;
    }
    #endregion
    #region  ■ 注册 ____________________________
    //用户输入手机验证码进行验证注册
    [System.Serializable]
    public class RegisterObj
    {
        /// <summary>
        /// 用户账号[手机号]
        /// </summary>
        public string memberPhone;
        /// <summary>
        /// 用户账号[邮箱]
        /// </summary>
        public string memberEmail;
        /// <summary>
        /// 验证码
        /// </summary>
        public string verifyCode;
        ///// <summary>
        ///// 手机注册的要加这个,短信区域代码,如+86
        ///// </summary>
        //public string phoneAreaCode;
        /// <summary>
        /// 登陆密码,需要MD5处理
        /// </summary>
        public string loginPwd;
        /// <summary>
        /// 会员昵称
        /// </summary>
        public string memberName;
    }
    /// <summary>
    /// 发送验证码
    /// </summary>
    [System.Serializable]
    public class VerifyCodeSendObj
    {
        /// <summary>
        /// 手机号
        /// </summary>
        public string phone;
        /// <summary>
        /// 手机号前缀
        /// </summary>
        public string phonePrefix;
        /// <summary>
        /// 语言
        /// </summary>
        public string languageType;
        /// <summary>
        /// 邮箱
        /// </summary>
        public string mail;
        /// <summary>
        /// 1:注册 2:找回密码 3:绑定4:验证码登陆 5:敏感数据
        /// 默认传1
        /// </summary>
        public int verifyType = 1;
        /// <summary>
        /// 验证码过期时间(秒),默认5分钟
        /// </summary>
        public int expireSecond = 300;
    }
    /// <summary>
    /// 验证验证码
    /// </summary>
    [System.Serializable]
    public class VerifyCodeCheckObj
    {
        /// <summary>
        /// 手机号
        /// </summary>
        public string phone;
        /// <summary>
        /// 邮箱
        /// </summary>
        public string mail;
        /// <summary>
        /// 1:注册 2:找回密码 3:绑定 4:验证码登陆 5:敏感数据
        /// 默认传1
        /// </summary>
        public int verifyType = 1;
        /// <summary>
        /// 验证码过期时间(秒),默认5分钟
        /// </summary>
        public string verifyCode;
        /// <summary>
        /// 验证成功后验证码是否失效 不传值或者true失效,只有传false的时候,校验通过后验证码也不失效
        /// </summary>
        public bool verifySuccessFail = true;
    }
    //[System.Serializable]
    //public class SignPhoneObj
    //{
    //    public string phone;
    //    public int Company;// 短信模板编号  int 是
    //}
    #endregion
    #region ■ 忘记密码 ____________________________
    //ForgetPwd 忘记密码,手机或邮箱方式
    [System.Serializable]
    public class ForgetPwdObj
    {
        /// <summary>
        /// 手机账号
        /// </summary>
        public string memberPhone;
        /// <summary>
        /// 邮箱账号
        /// </summary>
        public string memberEmail;
        /// <summary>
        /// 验证码
        /// </summary>
        public string verifyCode;
        /// <summary>
        /// 新密码
        /// </summary>
        public string loginPwd;
    }
    /// <summary>
    /// 更改个人密码
    /// </summary>
    [System.Serializable]
    public class UpdatePwdObj
    {
        /// <summary>
        /// 旧密码
        /// </summary>
        public string loginPwd;
        /// <summary>
        /// 新密码
        /// </summary>
        public string loginNewPwd;
    }
    #endregion
    #region ■ 帐号信息 ____________________________
    /// <summary>
    /// 获取个人信息
    /// </summary>
    [System.Serializable]
    public class MemberInfoRes
    {
        /// <summary>
        /// 用户ID
        /// </summary>
        public string memberId;
        /// <summary>
        /// 用户昵称
        /// </summary>
        public string memberName;
        /// <summary>
        /// 用户邮箱
        /// </summary>
        public string memberEmail;
        /// <summary>
        /// 用户手机号
        /// </summary>
        public string memberPhone;
        /// <summary>
        /// 国家区号
        /// </summary>
        public string memberPhonePrefix;
        /// <summary>
        /// 登录名
        /// </summary>
        public string loginName;
        /// <summary>
        /// 用户头像
        /// </summary>
        public string memberHeadIcon;
    }
    /// <summary>
    /// 更新个人信息
    /// </summary>
    [System.Serializable]
    public class UpdateMemberNameRes
    {
        /// <summary>
        /// 用户昵称
        /// </summary>
        public string memberName;
    }
    /// <summary>
    /// 更新个人头像
    /// </summary>
    [System.Serializable]
    public class UpdateMemberHeadIconRes
    {
        /// <summary>
        /// 用户头像
        /// </summary>
        public string memberHeadIcon;
    }
    /// <summary>
    /// 绑定认证(手机/邮箱)
    /// </summary>
    [System.Serializable]
    public class BindWithAccountObj
    {
        /// <summary>
        /// 用户手机
        /// </summary>
        public string memberPhone;
        /// <summary>
        /// 用户手机
        /// </summary>
        public string memberEmail;
        /// <summary>
        /// 验证吗
        /// </summary>
        public string verifyCode;
    }
    /// <summary>
    /// 解绑绑定认证(手机/邮箱)
    /// </summary>
    [System.Serializable]
    public class UnBindAccountObj
    {
        /// <summary>
        /// 解绑标示,PHONE,EMAIL
        /// </summary>
        public string unBindLabel;
    }
    #endregion
    #region ■ 住宅相关 ____________________________
    #region 获取住宅分页
    [System.Serializable]
    public class GetHomeListObj
    {
        /// <summary>
        /// 住宅类型
        /// </summary>
        public string homeType;
        /// <summary>
        /// 不自动生成默认住宅
        /// </summary>
        public bool autoGenerate = false;
    }
    [Serializable]
    public class AddOrUpdateHomeObj
    {
        /// <summary>
        ///
        /// </summary>
        public string homeId;
        /// <summary>
        ///
        /// </summary>
        public string homeType;
        /// <summary>
        ///
        /// </summary>
        public double latitude;
        /// <summary>
        ///
        /// </summary>
        public double longitude;
        /// <summary>
        /// 住宅名称
        /// </summary>
        public string homeName;
        /// <summary>
        /// 住宅地址
        /// </summary>
        public string homeAddress;
    }
    //[Serializable]
    //public class GethomepagerRes
    //{
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public int totalPages;
    //    public int totalElements;
    //    public bool last;
    //    public bool first;
    //    public int numberOfElements;
    //    public int size;
    //    public int number;
    //    public bool empty;
    //    public List<RegionInfoRes> content = new List<RegionInfoRes> ();
    //}
    //[Serializable]
    //public class HomeInfoRes
    //{
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public int totalPages;
    //    public int totalElements;
    //    public bool last;
    //    public bool first;
    //    public int numberOfElements;
    //    public int size;
    //    public int number;
    //    public bool empty;
    //    public List<RegionInfoRes> content = new List<RegionInfoRes> ();
    //}
    #endregion
    #region 绑定网关
    [System.Serializable]
    public class BindGatewayObj
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// 网关MAC
        /// </summary>
        public string mac;
        /// <summary>
        /// 住宅类型
        /// </summary>
        public string gatewayType;
        /// <summary>
        /// 子网号
        /// </summary>
        public int subnetId;
        /// <summary>
        /// 设备号
        /// </summary>
        public int deviceId;
    }
    #endregion
    #region 获取住宅网关列表
    //[Serializable]
    //public class HomeGatewayRes
    //{
    //    public int totalPages;
    //    public int totalElements;
    //    public bool last;
    //    public bool first;
    //    public int numberOfElements;
    //    public int size;
    //    public int number;
    //    public bool empty;
    //    public List<HomeGatewayInfo> content = new List<HomeGatewayInfo>();
    //}
    [Serializable]
    public class HomeGatewayInfo
    {
        /// <summary>
        /// 网关ID
        /// </summary>
        public string gatewayId ="";
        /// <summary>
        /// 网关snID
        /// </summary>
        public string sn = "";
        /// <summary>
        ///
        /// </summary>
        public string aesKey = "";
        /// <summary>
        /// BUSUDPGATEWAY,
        /// AGATEWAY,
        /// ZIGBEEGATEWAY,
        /// KNXGATEWAY
        /// </summary>
        public string gatewayType = "";
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId = "";
        /// <summary>
        ///
        /// </summary>
        public string mac = "";
        /// <summary>
        ///
        /// </summary>
        public string primaryKey = "";
        /// <summary>
        ///
        /// </summary>
        public string encryptionType = "";
        /// <summary>
        /// 子网号
        /// </summary>
        public int subnetId;
        /// <summary>
        /// 设备号
        /// </summary>
        public int deviceId;
        /// <summary>
        /// 网关状态
        /// ON_LINE(0,"在线"),
        /// OFF_LINE(1,"下线"),;
        /// </summary>
        public bool gatewayStatus;
        ///// <summary>
        /////
        ///// </summary>
        //public string gwFirmwareVersion;
        ///// <summary>
        /////
        ///// </summary>
        //public string projectName;
        ///// <summary>
        /////
        ///// </summary>
        //public string userName;
        ///// <summary>
        /////
        ///// </summary>
        //public string groupName;
        ///// <summary>
        /////
        ///// </summary>
        //public string gatewayName;
    }
    #endregion
    #region 解绑网关
    /// <summary>
    /// 解绑网关
    /// </summary>
    [System.Serializable]
    public class UntieGatewayObj
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// 网关MAC
        /// </summary>
        public string mac;
    }
    #endregion
    #endregion
    #region ■ 备份相关 ____________________________
    /// <summary>
    /// 更新文件夹名字
    /// </summary>
    ///
    [System.Serializable]
    public class BackupFolderCreateObj
    {
        /// <summary>
        /// 备份分类 0:交互工程备份 1:自定义工程备份 2:用户自动备份 3:用户自定义备份 [填写 0~3]
        /// </summary>
        public string backupClassify = string.Empty;
        /// <summary>
        /// 备份数据分类
        /// </summary>
        public string backupDataType = string.Empty;
        /// <summary>
        /// 住宅 ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// APP备份文件夹名字
        /// </summary>
        public string folderName;
    }
    [System.Serializable]
    public class BackupFolderCreateRes
    {
        /// <summary>
        /// 文件夹id
        /// </summary>
        public string id;
        ///// <summary>
        /////
        ///// </summary>
        //public string homeId;
        ///// <summary>
        /////
        ///// </summary>
        //public string backupDataType;
        ///// <summary>
        /////
        ///// </summary>
        //public string backupClassify;
        /// <summary>
        /// 文件夹名字
        /// </summary>
        public string folderName;
        ///// <summary>
        /////
        ///// </summary>
        //public int backupUtcTime;
        ///// <summary>
        /////
        ///// </summary>
        //public int createonutc;
    }
    /// <summary>
    /// 备份列表名的信息
    /// </summary>
    ///
    [System.Serializable]
    public class BackupListNameInfoRes
    {
        /// <summary>
        /// 文件夹 ID
        /// </summary>
        public string id;
        /// <summary>
        /// 住宅 ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// backupDataType
        /// </summary>
        public string backupDataType = string.Empty;
        /// <summary>
        /// backupClassify
        /// </summary>
        public string backupClassify;
        /// <summary>
        /// backupClassify
        /// </summary>
        public string folderName = string.Empty;
        /// <summary>
        /// backupUtcTime
        /// </summary>
        public string backupUtcTime;
        ///// <summary>
        ///// createonutc
        ///// </summary>
        //public string createUtcTime;
    }
    /// <summary>
    /// 更新文件夹名字
    /// </summary>
    ///
    [System.Serializable]
    public class UpdateBackupObj
    {
        ///// <summary>
        ///// 备份分类 0:交互工程备份 1:自定义工程备份 2:用户自动备份 3:用户自定义备份 [填写 0~3]
        ///// </summary>
        //public string backupClassify = string.Empty;
        ///// <summary>
        ///// 备份数据分类
        ///// </summary>
        //public string backupDataType = string.Empty;
        /// <summary>
        /// 住宅 ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// APP备份文件夹名字
        /// </summary>
        public string folderName;
        /// <summary>
        /// 文件夹 id
        /// </summary>
        public string folderId;
    }
    /// <summary>
    /// 单个备份文件信息
    /// </summary>
    [System.Serializable]
    public class BackupFileInfoRes
    {
        /// <summary>
        /// 文件主键 id
        /// </summary>
        public string id;
        /// <summary>
        /// 文件夹主键 id
        /// </summary>
        public string backupFolderId;
        /// <summary>
        /// 手机号住宅的文件名称
        /// </summary>
        public string fileName;
        ///// <summary>
        /////
        ///// </summary>
        //public long createUtcTime;
    }
    /// <summary>
    /// 查找所有文件 或者 删除备份文件夹
    /// </summary>
    [System.Serializable]
    public class BackupFolderIdObj
    {
        /// <summary>
        /// 文件夹主键 id
        /// </summary>
        public string folderId;
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
    }
    /// <summary>
    /// 下载备份
    /// </summary>
    [System.Serializable]
    public class BackupFileDownObj
    {
        /// <summary>
        /// 文件夹主键 id
        /// </summary>
        public string folderId;
        /// <summary>
        /// 文件id
        /// </summary>
        public string fileId;
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
    }
    #endregion
    #region ■ 子账号相关 ____________________________
    #region 添加、查询、删除子账号
    /// <summary>
    /// ChildBaseObj
    /// </summary>
    [System.Serializable]
    public class ChildBaseObj
    {
        /// <summary>
        /// 子账号ID childAccountId
        /// </summary>
        public string childAccountId;
        /// <summary>
        /// 住宅
        /// </summary>
        public string homeId;
    }
    /// <summary>
    /// 添加子账号
    /// </summary>
    [System.Serializable]
    public class ChildAddObj
    {
        /// <summary>
        ///
        /// </summary>
        public string homeId;
        /// <summary>
        /// 子用户的电话或者邮箱
        /// </summary>
        public string account;
        /// <summary>
        /// 子账户类型 ORDINARY、DEBUG、ADMIN
        /// </summary>
        public string childAccountType;
        ///// <summary>
        ///// 是否允许远程控制 0:允许 1:不允许
        ///// </summary>
        //public bool isRemoteControl = true;
        /// <summary>
        /// 子账号昵称
        /// </summary>
        public string nickName;
    }
    /// <summary>
    /// 删除子账号
    /// </summary>
    [System.Serializable]
    public class ChildDeleteObj : ChildBaseObj
    {
    }
    /// <summary>
    /// HomeIdObj
    /// </summary>
    [System.Serializable]
    public class HomeIdObj
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
    }
    /// <summary>
    /// 更新子账号备注名字
    /// </summary>
    [System.Serializable]
    public class UpdateChildNickNameObj : ChildBaseObj
    {
        /// <summary>
        /// nickName
        /// </summary>
        public string nickName;
    }
    /// <summary>
    /// 更新远程控制
    /// </summary>
    [System.Serializable]
    public class UpdateRemoteObj : ChildBaseObj
    {
        /// <summary>
        /// 是否允许远程控制
        /// </summary>
        public bool isRemoteControl;
        /// <summary>
        /// 子账户类型 ORDINARY、DEBUG、ADMIN
        /// </summary>
        public string childAccountType;
    }
    /// <summary>
    /// 修改是否允许创建场景
    /// </summary>
    [System.Serializable]
    public class UpdateChildAllowCreateSceneObj : ChildBaseObj
    {
        /// <summary>
        /// 是否允许创建场景
        /// </summary>
        public bool isAllowCreateScene;
    }
    /// <summary>
    ///
    /// </summary>
    [System.Serializable]
    public class AccountObj
    {
        /// <summary>
        /// 账号
        /// </summary>
        public string account;
    }
    #endregion
    #region 数据分享
    /// <summary>
    /// 查询某住宅某子账号的分享文件信息
    /// </summary>
    [System.Serializable]
    public class HomeShareFindAll : ChildBaseObj
    {
    }
    /// <summary>
    /// 查询某住宅某子账号的分享文件信息
    /// </summary>
    [System.Serializable]
    public class ChildShareFileInfoRes
    {
        /// <summary>
        /// 主键ID
        /// </summary>
        public string id;
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// 子账号ID
        /// </summary>
        public string childAccountId;
        /// <summary>
        /// 文件名
        /// </summary>
        public string fileName;
        /// <summary>
        /// 创建时间
        /// </summary>
        public string createTime;
    }
    /// <summary>
    /// 下载分享
    /// </summary>
    [System.Serializable]
    public class ShareFileDownObj
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// 分享文件id
        /// </summary>
        public string homeShareId;
    }
    #endregion
    #endregion
    #region ■ GetMqttRemoteInfo ____________________________
    [Serializable]
    public class GetMqttRemoteInfoObj
    {
        /// <summary>
        /// 平台标示 ClientId账号拼接用
        /// </summary>
        public string attachClientId;
        /// <summary>
        /// 住宅类型 1.ZIGBEE 2.BUSPRO 3.A 4.ALL
        /// </summary>
        public string homeType;
    }
    #endregion
    /// <summary>
    /// 手机区号
    /// </summary>
    [System.Serializable]
    public class AreaCodeRes
    {
        /// <summary>
        ///
        /// </summary>
        public string Name;
        /// <summary>
        ///
        /// </summary>
        public string Code;
        /// <summary>
        ///
        /// </summary>
        public string Id;
    }
    #region 数据分享
    ///// <summary>
    ///// 添加分享
    ///// </summary>
    //[System.Serializable]
    //public class ShareData
    //{
    //    /// <summary>
    //    /// 住宅ID
    //    /// </summary>
    //    public int homeId;
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public List<ShareDatasItem> shareDatas;
    //    /// <summary>
    //    /// 子账号ID
    //    /// </summary>
    //    public List<string> childAccountIds;
    //}
    /// <summary>
    /// 添加分享
    /// </summary>
    [System.Serializable]
    public class AddShareObj
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
        /// <summary>
        ///
        /// </summary>
        public List<ShareData> shareDatas;
        /// <summary>
        /// 子账号ID
        /// </summary>
        public List<string> childAccountIds;
    }
    /// <summary>
    ///
    /// </summary>
    public class ShareData
    {
        /// <summary>
        /// 分享类型表id
        /// </summary>
        public string shareTypeId;
        /// <summary>
        /// 子帐号ID
        /// </summary>
        public string childAccountId;
        /// <summary>
        /// 分享类型 1.ROOM  2.DEVICE 3.SCENE
        /// </summary>
        public string shareType = "DEVICE";
    }
    /// <summary>
    /// 删除分享
    /// </summary>
    [System.Serializable]
    public class DeleteShareObj
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
        /// <summary>
        ///
        /// </summary>
        public List<ShareData> shareDatas;
    }
    /// <summary>
    /// 获取分享
    /// </summary>
    [System.Serializable]
    public class GetShareObj
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// 子账号ID
        /// </summary>
        public string childAccountId;
        ///// <summary>
        ///// 分享类型 1.ROOM  2.DEVICE 3.SCENE
        ///// 不传默认查全部
        ///// </summary>
        //public string shareType = "DEVICE";
    }
    #endregion
    #region 图片上传下载
    /// <summary>
    /// 上传图片
    /// </summary>
    [System.Serializable]
    public class UploadImageObj
    {
        /// <summary>
        /// 前缀标识
        /// </summary>
        public string prefix;
        /// <summary>
        /// 关联ID
        /// </summary>
        public string uid;
        /// <summary>
        /// 文件名称
        /// </summary>
        public string fileName;
        /// <summary>
        /// 图片二进制流
        /// </summary>
        public byte[] content;
    }
    /// <summary>
    /// 查询图片路径
    /// </summary>
    [System.Serializable]
    public class GetImageUrlObj
    {
        /// <summary>
        /// 图片下载路径标识
        /// </summary>
        public string imageKey;
    }
    #endregion
    #endregion
    /// <summary>
    /// 极光推送消息
    /// </summary>
    [System.Serializable]
    public class JPushMessageInfo
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string HomeId;
        /// <summary>
        /// 推送标题
        /// </summary>
        public string Title;
        /// <summary>
        /// 推送内容
        /// </summary>
        public string Content;
        /// <summary>
        /// 推送附加数据
        /// </summary>
        public string Extras;
        /// <summary>
        /// 信息类型
        /// </summary>
        public string messageType = "";
        /// <summary>
        /// 扩展数据内容
        /// </summary>
        public string expantContent = "";
    }
    /// <summary>
    /// 极光推送消息
    /// </summary>
    [System.Serializable]
    public class JPushExpandData
    {
        /// <summary>
        /// 附加内容
        /// </summary>
        public string expandData;
    }
    /// <summary>
    /// 极光推送消息
    /// </summary>
    [System.Serializable]
    public class ExpandData
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string homeId;
        /// <summary>
        /// 附加内容
        /// </summary>
        public string expantContent;
        /// <summary>
        ///  信息类型
        /// </summary>
        public string messageType;
    }
    /// <summary>
    /// 萤石云子账号token
    /// </summary>
    [System.Serializable]
    public class EZChildAccessToken
    {
        /// <summary>
        /// token
        /// </summary>
        public string accessToken;
        /// <summary>
        ///  过期时间
        /// </summary>
        public string expireTime;
    }
    #region 音箱
    /// <summary>
    /// 获取音箱列表
    /// </summary>
    [System.Serializable]
    public class GetSpeakerObj : HomeIdObj
    {
        /// <summary>
        /// 平台名称
        /// </summary>
        public string platformName;
        /// <summary>
        ///  页面大小
        /// </summary>
        public int pageSize = 100;
        /// <summary>
        ///  页面序号
        /// </summary>
        public int pageNo = 1;
    }
    [System.Serializable]
    public class SpeakerObj : HomeIdObj
    {
        /// <summary>
        /// 记录的主键id
        /// </summary>
        public string tokenId;
    }
    /// <summary>
    /// 更新音箱备注
    /// </summary>
    [System.Serializable]
    public class UpdateSpeakerRemarkObj : SpeakerObj
    {
        /// <summary>
        /// 备注
        /// </summary>
        public string remark;
    }
    /// <summary>
    /// 获取音箱分配的设备和场景列表
    /// </summary>
    [System.Serializable]
    public class GetSpeakerDeviceListObj : HomeIdObj
    {
        /// <summary>
        /// 记录的主键id
        /// </summary>
        public string tokenId;
    }
    /// <summary>
    /// 配置的语音设备和场景数据
    /// </summary>
    [System.Serializable]
    public class SpeakerTargetInfo
    {
        /// <summary>
        /// 控制的目标Id,云端的设备Id或者场景Id
        /// </summary>
        public string targetId;
        /// <summary>
        /// 是否是设备,场景为false
        /// </summary>
        public bool isDevice;
        /// <summary>
        /// 目标名称
        /// </summary>
        public string targetName;
        /// <summary>
        /// 扩展参数当前rowview是否选中
        /// </summary>
        public bool IsSelect;
    }
    //[System.Serializable]
    //public class SpeakerTargetInfoRow: SpeakerTargetInfo
    //{
    //    /// <summary>
    //    /// 当前rowview是否选中
    //    /// </summary>
    //    public bool isSelect;
    //}
        /// <summary>
        /// 更新音箱控制的设备和场景目标
        /// </summary>
        [System.Serializable]
    public class UpdateSpeakerDeviceListObj : SpeakerObj
    {
        /// <summary>
        /// 备注
        /// </summary>
        public List<SpeakerTargetInfo> targetInfos;
    }
    /// <summary>
    /// 更新音箱控制的设备和场景目标
    /// </summary>
    [System.Serializable]
    public class SpeakerListRes
    {
        /// <summary>
        /// 音箱列表
        /// </summary>
        public List<SpeakerInfo> list;
    }
    /// <summary>
    /// 音箱信息
    /// </summary>
    [System.Serializable]
    public class SpeakerInfo
    {
        /// <summary>
        ///
        /// </summary>
        public string platformName { get; set; }
        /// <summary>
        ///
        /// </summary>
        public string remark { get; set; }
        /// <summary>
        ///
        /// </summary>
        public string tokenId { get; set; }
        /// <summary>
        ///
        /// </summary>
        public string userId { get; set; }
        /// <summary>
        ///
        /// </summary>
        public string userRegion { get; set; }
        /// <summary>
        ///
        /// </summary>
        public string homeId { get; set; }
        /// <summary>
        ///
        /// </summary>
        public string homeRegion { get; set; }
    }
    #endregion
    //#region 旧接口
    ///// <summary>
    /////
    ///// </summary>
    //public class FindCityObj
    //{
    //    /// <summary>
    //    /// 城市ID
    //    /// </summary>
    //    public string Cid;
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public string Location;
    //    /// <summary>
    //    /// 城市
    //    /// </summary>
    //    public string City;
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public string Province;
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public string Country;
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public string TimeZone;
    //}
    ///// <summary>
    /////
    ///// </summary>
    //public class GetWeatherObj
    //{
    //    public string Temperature;
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public string Humidity;
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public string PM25;
    //    /// <summary>
    //    ///
    //    /// </summary>
    //    public string Weather;
    //}
    //#endregion
}
SiriIntents/SiriIntents.csproj
New file
@@ -0,0 +1,124 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">iPhoneSimulator</Platform>
    <ProjectGuid>{760980F5-1CD3-4F4F-9134-34D87BECD790}</ProjectGuid>
    <ProjectTypeGuids>{EE2C853D-36AF-4FDB-B1AD-8E90477E2198};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
    <OutputType>Library</OutputType>
    <RootNamespace>SiriIntents</RootNamespace>
    <AssemblyName>SiriIntents</AssemblyName>
    <IPhoneResourcePrefix>Resources</IPhoneResourcePrefix>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhoneSimulator' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\iPhoneSimulator\Debug</OutputPath>
    <DefineConstants>DEBUG;</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <CodesignKey>iPhone Developer</CodesignKey>
    <MtouchDebug>true</MtouchDebug>
    <MtouchNoSymbolStrip>true</MtouchNoSymbolStrip>
    <MtouchFastDev>true</MtouchFastDev>
    <IOSDebuggerPort>28717</IOSDebuggerPort>
    <MtouchLink>None</MtouchLink>
    <MtouchArch>x86_64</MtouchArch>
    <MtouchHttpClientHandler>NSUrlSessionHandler</MtouchHttpClientHandler>
    <DeviceSpecificBuild>false</DeviceSpecificBuild>
    <MtouchVerbosity></MtouchVerbosity>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhone' ">
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\iPhone\Release</OutputPath>
    <DefineConstants></DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <CodesignKey>iPhone Developer</CodesignKey>
    <MtouchUseLlvm>true</MtouchUseLlvm>
    <MtouchFloat32>true</MtouchFloat32>
    <CodesignEntitlements>Entitlements.plist</CodesignEntitlements>
    <MtouchLink>SdkOnly</MtouchLink>
    <MtouchArch>ARM64</MtouchArch>
    <MtouchHttpClientHandler>NSUrlSessionHandler</MtouchHttpClientHandler>
    <MtouchVerbosity></MtouchVerbosity>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhoneSimulator' ">
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\iPhoneSimulator\Release</OutputPath>
    <DefineConstants></DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <CodesignKey>iPhone Developer</CodesignKey>
    <MtouchNoSymbolStrip>true</MtouchNoSymbolStrip>
    <MtouchLink>None</MtouchLink>
    <MtouchArch>x86_64</MtouchArch>
    <MtouchHttpClientHandler>NSUrlSessionHandler</MtouchHttpClientHandler>
    <MtouchVerbosity></MtouchVerbosity>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhone' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\iPhone\Debug</OutputPath>
    <DefineConstants>DEBUG;</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <CodesignKey>iPhone Developer</CodesignKey>
    <DeviceSpecificBuild>true</DeviceSpecificBuild>
    <MtouchDebug>true</MtouchDebug>
    <MtouchNoSymbolStrip>true</MtouchNoSymbolStrip>
    <MtouchFastDev>true</MtouchFastDev>
    <MtouchFloat32>true</MtouchFloat32>
    <CodesignEntitlements>Entitlements.plist</CodesignEntitlements>
    <IOSDebuggerPort>52238</IOSDebuggerPort>
    <MtouchLink>SdkOnly</MtouchLink>
    <MtouchArch>ARM64</MtouchArch>
    <MtouchHttpClientHandler>NSUrlSessionHandler</MtouchHttpClientHandler>
    <MtouchVerbosity></MtouchVerbosity>
    <CodesignProvision>OnProSiri211125-1-Dev</CodesignProvision>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="System" />
    <Reference Include="System.Xml" />
    <Reference Include="System.Core" />
    <Reference Include="Xamarin.iOS" />
    <Reference Include="Shared.IOS.HDLSceneSiri">
      <HintPath>..\DLL\IOS\Shared.IOS.HDLSceneSiri.dll</HintPath>
    </Reference>
    <Reference Include="Newtonsoft.Json">
      <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\netstandard2.0\Newtonsoft.Json.dll</HintPath>
    </Reference>
    <Reference Include="RestSharp">
      <HintPath>..\packages\RestSharp.106.13.0\lib\netstandard2.0\RestSharp.dll</HintPath>
    </Reference>
  </ItemGroup>
  <ItemGroup>
    <Folder Include="Resources\" />
    <Folder Include="Server\" />
  </ItemGroup>
  <ItemGroup>
    <None Include="Info.plist" />
    <None Include="Entitlements.plist" />
    <None Include="packages.config" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="IntentHandler.cs" />
    <Compile Include="Server\HttpServerRequest.cs" />
    <Compile Include="Server\HttpUtil.cs" />
    <Compile Include="Server\IMessageCommon.cs" />
    <Compile Include="Server\NewAPI.cs" />
    <Compile Include="Server\NewApiRes.cs" />
    <Compile Include="HDLRunSceneIntentHandlder.cs" />
  </ItemGroup>
  <ItemGroup>
    <ProjectReference Include="..\SiriKit\SiriKit.csproj">
      <Project>{8B1652FA-5158-4D57-B90D-07BB91766625}</Project>
      <Name>SiriKit</Name>
    </ProjectReference>
  </ItemGroup>
  <Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.AppExtension.CSharp.targets" />
</Project>
SiriIntents/packages.config
New file
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
  <package id="Newtonsoft.Json" version="13.0.1" targetFramework="xamarinios10" />
  <package id="RestSharp" version="106.13.0" targetFramework="xamarinios10" />
</packages>
SiriIntentsUI/Entitlements.plist
New file
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>com.apple.security.application-groups</key>
    <array>
        <string>group.com.hdl.onpro</string>
    </array>
    <key>com.apple.developer.siri</key>
    <true/>
</dict>
</plist>
SiriIntentsUI/Info.plist
New file
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>CFBundleDisplayName</key>
    <string>SiriIntentsUI</string>
    <key>CFBundleName</key>
    <string>SiriIntentsUI</string>
    <key>CFBundleIdentifier</key>
    <string>com.hdl.onpro.siriui</string>
    <key>CFBundleDevelopmentRegion</key>
    <string>en</string>
    <key>CFBundleInfoDictionaryVersion</key>
    <string>6.0</string>
    <key>CFBundlePackageType</key>
    <string>XPC!</string>
    <key>CFBundleShortVersionString</key>
    <string>1.3.202111171</string>
    <key>CFBundleVersion</key>
    <string>1.3.11171</string>
    <key>MinimumOSVersion</key>
    <string>12.0</string>
    <key>NSExtension</key>
    <dict>
        <key>NSExtensionAttributes</key>
        <dict>
            <key>IntentsSupported</key>
            <array>
                <string>HDLRunSceneIntent</string>
            </array>
            <key>IntentsRestrictedWhileLocked</key>
            <array>
                <string>HDLRunSceneIntent</string>
            </array>
            <key>IntentsRestrictedWhileProtectedDataUnavailable</key>
            <array>
                <string>HDLRunSceneIntent</string>
            </array>
        </dict>
        <key>NSExtensionMainStoryboard</key>
        <string>MainInterface</string>
        <key>NSExtensionPointIdentifier</key>
        <string>com.apple.intents-ui-service</string>
    </dict>
</dict>
</plist>
SiriIntentsUI/IntentViewController.cs
New file
@@ -0,0 +1,105 @@
using System;
using CoreGraphics;
using Foundation;
using HDLSceneSiri;
//using HDLSceneSiri;
using Intents;
using IntentsUI;
using UIKit;
namespace SiriIntentsUI
{
    public partial class IntentViewController : UIViewController, IINUIHostedViewControlling
    {
        protected IntentViewController(IntPtr handle) : base(handle)
        {
        }
        //public override void ViewDidLoad()
        //{
        //    base.ViewDidLoad();
        //    // Do any required interface  here.
        //}
        //public override void DidReceiveMemoryWarning()
        //{
        //    // Releases the view if it doesn't have a superview.
        //    base.DidReceiveMemoryWarning();
        //    // Release any cached data, images, etc that aren't in use.
        //}
        [Export("configureWithInteraction:context:completion:")]
        public void Configure(INInteraction interaction, INUIHostedViewContext context, Action<CGSize> completion)
        {
            throw new NotImplementedException();
        }
        CGSize DesiredSize()
        {
            return ExtensionContext.GetHostedViewMaximumAllowedSize();
        }
        [Export("configureViewForParameters:ofInteraction:interactiveBehavior:context:completion:")]
        public void ConfigureView(
            NSSet<INParameter> parameters,
            INInteraction interaction,
            INUIInteractiveBehavior interactiveBehavior,
            INUIHostedViewContext context,
            INUIHostedViewControllingConfigureViewHandler completion)
        {
                HDLRunSceneIntentResponse rsp = interaction.IntentResponse as HDLRunSceneIntentResponse;
            this.lblMsg.Text = rsp.SuccessMessage;
            this.lblMsg.TextColor = UIColor.Black;
            this.lblMsg.Frame = new CGRect(0, 0, DesiredSize().Width, 100);
            CGSize size = new CGSize(DesiredSize().Width, 100);
            if (completion != null)
                completion(true, parameters, size);
            //var intent = interaction.Intent as OrderSoupIntent;
            //if (intent is null)
            //{
            //    completion(false, new NSSet<INParameter>(), CGSize.Empty);
            //}
            //var order = Order.FromOrderSoupIntent(intent);
            //foreach (var view in View.Subviews)
            //{
            //    view.RemoveFromSuperview();
            //}
            //// Different UIs can be displayed depending if the intent is in the
            //// confirmation phase or the handle phase.
            //var desiredSize = CGSize.Empty;
            //if (interaction.IntentHandlingStatus == INIntentHandlingStatus.Ready)
            //{
            //    desiredSize = DisplayInvoice(order, intent);
            //}
            //else if (interaction.IntentHandlingStatus == INIntentHandlingStatus.Success)
            //{
            //    var response = interaction.IntentResponse as OrderSoupIntentResponse;
            //    if (!(response is null))
            //    {
            //        desiredSize = DisplayOrderConfirmation(order, intent, response);
            //    }
            //}
            //completion(true, parameters, desiredSize);
        }
    }
}
SiriIntentsUI/IntentViewController.designer.cs
New file
@@ -0,0 +1,27 @@
// WARNING
//
// This file has been generated automatically by Visual Studio to store outlets and
// actions made in the UI designer. If it is removed, they will be lost.
// Manual changes to this file may not be handled correctly.
//
using Foundation;
using System.CodeDom.Compiler;
namespace SiriIntentsUI
{
    [Register ("IntentViewController")]
    partial class IntentViewController
    {
        [Outlet]
        [GeneratedCode("iOS Designer", "1.0")]
        UIKit.UILabel lblMsg { get; set; }
        void ReleaseDesignerOutlets ()
        {
            if (lblMsg != null) {
                lblMsg.Dispose ();
                lblMsg = null;
            }
        }
    }
}
SiriIntentsUI/MainInterface.storyboard
New file
@@ -0,0 +1,48 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="19162" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="ObA-dk-sSI">
    <device id="retina6_1" orientation="portrait" appearance="light"/>
    <dependencies>
        <deployment identifier="iOS"/>
        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="19144"/>
        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
    </dependencies>
    <scenes>
        <!--Intent View Controller-->
        <scene sceneID="7MM-of-jgj">
            <objects>
                <viewController id="ObA-dk-sSI" customClass="IntentViewController" sceneMemberID="viewController">
                    <layoutGuides>
                        <viewControllerLayoutGuide type="top" id="qkL-Od-lgU"/>
                        <viewControllerLayoutGuide type="bottom" id="n38-gi-rB5"/>
                    </layoutGuides>
                    <view key="view" contentMode="scaleToFill" id="zMn-AG-sqS">
                        <rect key="frame" x="0.0" y="0.0" width="320" height="81"/>
                        <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
                        <subviews>
                            <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Label" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="IGu-QP-NsY">
                                <rect key="frame" x="0.0" y="0.0" width="320" height="81"/>
                                <fontDescription key="fontDescription" type="system" pointSize="17"/>
                                <nil key="textColor"/>
                                <nil key="highlightedColor"/>
                            </label>
                        </subviews>
                        <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                        <constraints>
                            <constraint firstItem="n38-gi-rB5" firstAttribute="top" secondItem="IGu-QP-NsY" secondAttribute="bottom" id="SeT-jr-PQR"/>
                            <constraint firstItem="IGu-QP-NsY" firstAttribute="top" secondItem="zMn-AG-sqS" secondAttribute="top" id="XNh-gA-gK1"/>
                            <constraint firstAttribute="trailing" secondItem="IGu-QP-NsY" secondAttribute="trailing" id="a0D-RT-Dwt"/>
                            <constraint firstItem="IGu-QP-NsY" firstAttribute="leading" secondItem="zMn-AG-sqS" secondAttribute="leading" id="dPA-2W-Z8X"/>
                        </constraints>
                    </view>
                    <freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
                    <size key="freeformSize" width="320" height="81"/>
                    <connections>
                        <outlet property="lblMsg" destination="IGu-QP-NsY" id="gfv-7M-crM"/>
                    </connections>
                </viewController>
                <placeholder placeholderIdentifier="IBFirstResponder" id="X47-rx-isc" userLabel="First Responder" sceneMemberID="firstResponder"/>
            </objects>
            <point key="canvasLocation" x="20" y="80"/>
        </scene>
    </scenes>
</document>
SiriIntentsUI/SiriIntentsUI.csproj
New file
@@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">iPhoneSimulator</Platform>
    <ProjectGuid>{ACC48A7F-250B-4915-A250-9BC399DBD6B3}</ProjectGuid>
    <ProjectTypeGuids>{EE2C853D-36AF-4FDB-B1AD-8E90477E2198};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
    <OutputType>Library</OutputType>
    <RootNamespace>SiriIntentsUI</RootNamespace>
    <AssemblyName>SiriIntentsUI</AssemblyName>
    <IPhoneResourcePrefix>Resources</IPhoneResourcePrefix>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhoneSimulator' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\iPhoneSimulator\Debug</OutputPath>
    <DefineConstants>DEBUG;</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <CodesignKey>iPhone Developer</CodesignKey>
    <MtouchDebug>true</MtouchDebug>
    <MtouchNoSymbolStrip>true</MtouchNoSymbolStrip>
    <MtouchFastDev>true</MtouchFastDev>
    <IOSDebuggerPort>51713</IOSDebuggerPort>
    <MtouchLink>None</MtouchLink>
    <MtouchArch>x86_64</MtouchArch>
    <MtouchHttpClientHandler>NSUrlSessionHandler</MtouchHttpClientHandler>
    <DeviceSpecificBuild>false</DeviceSpecificBuild>
    <MtouchVerbosity></MtouchVerbosity>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhone' ">
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\iPhone\Release</OutputPath>
    <DefineConstants></DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <CodesignKey>iPhone Developer</CodesignKey>
    <MtouchUseLlvm>true</MtouchUseLlvm>
    <MtouchFloat32>true</MtouchFloat32>
    <CodesignEntitlements>Entitlements.plist</CodesignEntitlements>
    <MtouchLink>SdkOnly</MtouchLink>
    <MtouchArch>ARM64</MtouchArch>
    <MtouchHttpClientHandler>NSUrlSessionHandler</MtouchHttpClientHandler>
    <MtouchVerbosity></MtouchVerbosity>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhoneSimulator' ">
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\iPhoneSimulator\Release</OutputPath>
    <DefineConstants></DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <CodesignKey>iPhone Developer</CodesignKey>
    <MtouchNoSymbolStrip>true</MtouchNoSymbolStrip>
    <MtouchLink>None</MtouchLink>
    <MtouchArch>x86_64</MtouchArch>
    <MtouchHttpClientHandler>NSUrlSessionHandler</MtouchHttpClientHandler>
    <MtouchVerbosity></MtouchVerbosity>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhone' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\iPhone\Debug</OutputPath>
    <DefineConstants>DEBUG;</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <CodesignKey>iPhone Developer</CodesignKey>
    <DeviceSpecificBuild>true</DeviceSpecificBuild>
    <MtouchDebug>true</MtouchDebug>
    <MtouchNoSymbolStrip>true</MtouchNoSymbolStrip>
    <MtouchFastDev>true</MtouchFastDev>
    <MtouchFloat32>true</MtouchFloat32>
    <CodesignEntitlements>Entitlements.plist</CodesignEntitlements>
    <IOSDebuggerPort>50971</IOSDebuggerPort>
    <MtouchLink>SdkOnly</MtouchLink>
    <MtouchArch>ARM64</MtouchArch>
    <MtouchHttpClientHandler>NSUrlSessionHandler</MtouchHttpClientHandler>
    <MtouchVerbosity></MtouchVerbosity>
    <CodesignProvision>OnProSiriUI211125-1-Dev</CodesignProvision>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="System" />
    <Reference Include="System.Xml" />
    <Reference Include="System.Core" />
    <Reference Include="Xamarin.iOS" />
    <Reference Include="Shared.IOS.HDLSceneSiri">
      <HintPath>..\DLL\IOS\Shared.IOS.HDLSceneSiri.dll</HintPath>
    </Reference>
  </ItemGroup>
  <ItemGroup>
    <Folder Include="Resources\" />
  </ItemGroup>
  <ItemGroup>
    <None Include="Info.plist" />
    <None Include="Entitlements.plist" />
  </ItemGroup>
  <ItemGroup>
    <InterfaceDefinition Include="MainInterface.storyboard" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="IntentViewController.cs" />
    <Compile Include="IntentViewController.designer.cs">
      <DependentUpon>IntentViewController.cs</DependentUpon>
    </Compile>
  </ItemGroup>
  <ItemGroup>
    <ProjectReference Include="..\SiriKit\SiriKit.csproj">
      <Project>{8B1652FA-5158-4D57-B90D-07BB91766625}</Project>
      <Name>SiriKit</Name>
    </ProjectReference>
  </ItemGroup>
  <Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.AppExtension.CSharp.targets" />
</Project>
SiriKit/Base.lproj/Intents.intentdefinition
New file
@@ -0,0 +1,265 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>INEnums</key>
    <array/>
    <key>INIntentDefinitionModelVersion</key>
    <string>1.2</string>
    <key>INIntentDefinitionNamespace</key>
    <string>8yVV3C</string>
    <key>INIntentDefinitionSystemVersion</key>
    <string>20G165</string>
    <key>INIntentDefinitionToolsBuildVersion</key>
    <string>13A233</string>
    <key>INIntentDefinitionToolsVersion</key>
    <string>13.0</string>
    <key>INIntents</key>
    <array>
        <dict>
            <key>INIntentCategory</key>
            <string>generic</string>
            <key>INIntentDescription</key>
            <string>Run Scene</string>
            <key>INIntentDescriptionID</key>
            <string>Pe02nj</string>
            <key>INIntentLastParameterTag</key>
            <integer>22</integer>
            <key>INIntentName</key>
            <string>HDLRunScene</string>
            <key>INIntentParameterCombinations</key>
            <dict>
                <key>controlName,controlId,controlType,controlJSONStr,actionName,homeId</key>
                <dict>
                    <key>INIntentParameterCombinationIsPrimary</key>
                    <true/>
                    <key>INIntentParameterCombinationSupportsBackgroundExecution</key>
                    <true/>
                    <key>INIntentParameterCombinationTitle</key>
                    <string>${actionName}“${controlName}”</string>
                    <key>INIntentParameterCombinationTitleID</key>
                    <string>3GPMaH</string>
                </dict>
            </dict>
            <key>INIntentParameters</key>
            <array>
                <dict>
                    <key>INIntentParameterDisplayName</key>
                    <string>Control Name</string>
                    <key>INIntentParameterDisplayNameID</key>
                    <string>wC0SgK</string>
                    <key>INIntentParameterDisplayPriority</key>
                    <integer>1</integer>
                    <key>INIntentParameterMetadata</key>
                    <dict>
                        <key>INIntentParameterMetadataCapitalization</key>
                        <string>Sentences</string>
                        <key>INIntentParameterMetadataDefaultValueID</key>
                        <string>xz2KkJ</string>
                    </dict>
                    <key>INIntentParameterName</key>
                    <string>controlName</string>
                    <key>INIntentParameterTag</key>
                    <integer>1</integer>
                    <key>INIntentParameterType</key>
                    <string>String</string>
                </dict>
                <dict>
                    <key>INIntentParameterDisplayName</key>
                    <string>Control Id</string>
                    <key>INIntentParameterDisplayNameID</key>
                    <string>MtgGtd</string>
                    <key>INIntentParameterDisplayPriority</key>
                    <integer>2</integer>
                    <key>INIntentParameterMetadata</key>
                    <dict>
                        <key>INIntentParameterMetadataCapitalization</key>
                        <string>Sentences</string>
                        <key>INIntentParameterMetadataDefaultValueID</key>
                        <string>hQHCm1</string>
                    </dict>
                    <key>INIntentParameterName</key>
                    <string>controlId</string>
                    <key>INIntentParameterTag</key>
                    <integer>2</integer>
                    <key>INIntentParameterType</key>
                    <string>String</string>
                </dict>
                <dict>
                    <key>INIntentParameterDisplayName</key>
                    <string>Home Id</string>
                    <key>INIntentParameterDisplayNameID</key>
                    <string>Re9KKp</string>
                    <key>INIntentParameterDisplayPriority</key>
                    <integer>3</integer>
                    <key>INIntentParameterMetadata</key>
                    <dict>
                        <key>INIntentParameterMetadataCapitalization</key>
                        <string>Sentences</string>
                        <key>INIntentParameterMetadataDefaultValueID</key>
                        <string>mQMSns</string>
                    </dict>
                    <key>INIntentParameterName</key>
                    <string>homeId</string>
                    <key>INIntentParameterTag</key>
                    <integer>12</integer>
                    <key>INIntentParameterType</key>
                    <string>String</string>
                </dict>
                <dict>
                    <key>INIntentParameterDisplayName</key>
                    <string>Control Type</string>
                    <key>INIntentParameterDisplayNameID</key>
                    <string>TBoK4E</string>
                    <key>INIntentParameterDisplayPriority</key>
                    <integer>4</integer>
                    <key>INIntentParameterMetadata</key>
                    <dict>
                        <key>INIntentParameterMetadataCapitalization</key>
                        <string>Sentences</string>
                        <key>INIntentParameterMetadataDefaultValueID</key>
                        <string>Yg2EJK</string>
                    </dict>
                    <key>INIntentParameterName</key>
                    <string>controlType</string>
                    <key>INIntentParameterTag</key>
                    <integer>14</integer>
                    <key>INIntentParameterType</key>
                    <string>String</string>
                </dict>
                <dict>
                    <key>INIntentParameterDisplayName</key>
                    <string>Control JSON Str</string>
                    <key>INIntentParameterDisplayNameID</key>
                    <string>WYEDs9</string>
                    <key>INIntentParameterDisplayPriority</key>
                    <integer>5</integer>
                    <key>INIntentParameterMetadata</key>
                    <dict>
                        <key>INIntentParameterMetadataCapitalization</key>
                        <string>Sentences</string>
                        <key>INIntentParameterMetadataDefaultValueID</key>
                        <string>WXdhpn</string>
                    </dict>
                    <key>INIntentParameterName</key>
                    <string>controlJSONStr</string>
                    <key>INIntentParameterTag</key>
                    <integer>21</integer>
                    <key>INIntentParameterType</key>
                    <string>String</string>
                </dict>
                <dict>
                    <key>INIntentParameterDisplayName</key>
                    <string>Action Name</string>
                    <key>INIntentParameterDisplayNameID</key>
                    <string>sB0JdL</string>
                    <key>INIntentParameterDisplayPriority</key>
                    <integer>6</integer>
                    <key>INIntentParameterMetadata</key>
                    <dict>
                        <key>INIntentParameterMetadataCapitalization</key>
                        <string>Sentences</string>
                        <key>INIntentParameterMetadataDefaultValueID</key>
                        <string>nGpmbm</string>
                    </dict>
                    <key>INIntentParameterName</key>
                    <string>actionName</string>
                    <key>INIntentParameterTag</key>
                    <integer>22</integer>
                    <key>INIntentParameterType</key>
                    <string>String</string>
                </dict>
            </array>
            <key>INIntentResponse</key>
            <dict>
                <key>INIntentResponseCodes</key>
                <array>
                    <dict>
                        <key>INIntentResponseCodeFormatString</key>
                        <string>${controlName}</string>
                        <key>INIntentResponseCodeFormatStringID</key>
                        <string>Pq8YBC</string>
                        <key>INIntentResponseCodeName</key>
                        <string>success</string>
                        <key>INIntentResponseCodeSuccess</key>
                        <true/>
                    </dict>
                    <dict>
                        <key>INIntentResponseCodeFormatString</key>
                        <string>${errorMessage}</string>
                        <key>INIntentResponseCodeFormatStringID</key>
                        <string>CX5DVI</string>
                        <key>INIntentResponseCodeName</key>
                        <string>failure</string>
                    </dict>
                    <dict>
                        <key>INIntentResponseCodeName</key>
                        <string>error</string>
                        <key>INIntentResponseCodeSuccess</key>
                        <true/>
                    </dict>
                </array>
                <key>INIntentResponseLastParameterTag</key>
                <integer>3</integer>
                <key>INIntentResponseParameters</key>
                <array>
                    <dict>
                        <key>INIntentResponseParameterDisplayName</key>
                        <string>Error Message</string>
                        <key>INIntentResponseParameterDisplayNameID</key>
                        <string>HxQb2M</string>
                        <key>INIntentResponseParameterDisplayPriority</key>
                        <integer>1</integer>
                        <key>INIntentResponseParameterName</key>
                        <string>errorMessage</string>
                        <key>INIntentResponseParameterTag</key>
                        <integer>1</integer>
                        <key>INIntentResponseParameterType</key>
                        <string>String</string>
                    </dict>
                    <dict>
                        <key>INIntentResponseParameterDisplayName</key>
                        <string>Success Message</string>
                        <key>INIntentResponseParameterDisplayNameID</key>
                        <string>BaAbSP</string>
                        <key>INIntentResponseParameterDisplayPriority</key>
                        <integer>2</integer>
                        <key>INIntentResponseParameterName</key>
                        <string>successMessage</string>
                        <key>INIntentResponseParameterTag</key>
                        <integer>2</integer>
                        <key>INIntentResponseParameterType</key>
                        <string>String</string>
                    </dict>
                    <dict>
                        <key>INIntentResponseParameterDisplayName</key>
                        <string>Control Name</string>
                        <key>INIntentResponseParameterDisplayNameID</key>
                        <string>pqg7cb</string>
                        <key>INIntentResponseParameterDisplayPriority</key>
                        <integer>3</integer>
                        <key>INIntentResponseParameterName</key>
                        <string>controlName</string>
                        <key>INIntentResponseParameterTag</key>
                        <integer>3</integer>
                        <key>INIntentResponseParameterType</key>
                        <string>String</string>
                    </dict>
                </array>
            </dict>
            <key>INIntentRestrictions</key>
            <integer>1</integer>
            <key>INIntentTitle</key>
            <string>Run Scene</string>
            <key>INIntentTitleID</key>
            <string>j3jRXP</string>
            <key>INIntentType</key>
            <string>Custom</string>
            <key>INIntentVerb</key>
            <string>Do</string>
        </dict>
    </array>
    <key>INTypes</key>
    <array/>
</dict>
</plist>
SiriKit/Data/DataManager.cs
New file
@@ -0,0 +1,188 @@
///*
//See LICENSE folder for this sample’s licensing information.
//Abstract:
//A data manager that manages data conforming to `Codable` and stores it in `UserDefaults`.
//*/
//using System;
//using Foundation;
//using CoreFoundation;
//namespace SiriKit
//{
//    public struct UserDefaultsStorageDescriptor
//    {
//        public string Key { get; set; }
//        public UserDefaultsStorageDescriptor(string key)
//        {
//            Key = key;
//        }
//    }
//    public static class NotificationKeys
//    {
//        // Clients of `DataManager` that want to know when the data changes can
//        // listen for this notification.
//        public const string DataChanged = "DataChangedNotification";
//    }
//    public class DataManager<ManagedDataType> : NSObject
//        where ManagedDataType : NSObject, INSCoding
//    {
//        // This sample uses App Groups to share a suite of data between the
//        // main app and the different extensions.
//        protected NSUserDefaults UserDefaults = NSUserDefaultsHelper.DataSuite;
//        // To prevent data races, all access to `UserDefaults` uses this queue.
//        protected DispatchQueue UserDefaultsAccessQueue = new DispatchQueue("User Defaults Access Queue");
//        // Storage and observation information.
//        protected UserDefaultsStorageDescriptor StorageDescriptor;
//        // A flag to avoid receiving notifications about data this instance just
//        // wrote to `UserDefaults`.
//        protected bool IgnoreLocalUserDefaultsChanges = false;
//        // The observer object handed back after registering to observe a
//        // property.
//        IDisposable UserDefaultsObserver;
//        // The data managed by this `DataManager`.
//        //此“DataManager”管理的数据。
//        protected ManagedDataType ManagedDataBackingInstance;
//        // Access to `managedDataBackingInstance` needs to occur on a dedicated
//        // queue to avoid data races.
//        protected DispatchQueue DataAccessQueue = new DispatchQueue("Data Access Queue");
//        // Public access to the managed data for clients of `DataManager`
//        public ManagedDataType ManagedData
//        {
//            get
//            {
//                ManagedDataType data = null;
//                DataAccessQueue.DispatchSync(() => data = ManagedDataBackingInstance);
//                return data;
//            }
//        }
//        // See note below about createInitialData and initialData
//        public DataManager(UserDefaultsStorageDescriptor storageDescriptor, ManagedDataType initialData)
//        {
//            StorageDescriptor = storageDescriptor;
//            LoadData();
//            if (ManagedDataBackingInstance is null)
//            {
//                ManagedDataBackingInstance = initialData;
//                WriteData();
//            }
//            ObserveChangesInUserDefaults();
//        }
//        // createInitialData
//        //
//        // The Swift version of this app has a createInitialData method.
//        // Each child class of the DataManager class overrides this method, and
//        // then the DataManager base class calls the derived versions to get
//        // the initial data. C# gives a compiler warning for this ("Virtual
//        // member call in constructor"). Since in C# the base class constructor
//        // is run before the child class constructor, having the base clas
//        // constructor call out to a method on the derived class is calling
//        // a method on an object that has not yet been fully constructed.
//        // The C# version of this sample works around this problem by passing
//        // in the initial data to the constructor.
//        void ObserveChangesInUserDefaults()
//        {
//            var weakThis = new WeakReference<DataManager<ManagedDataType>>(this);
//            Action<NSObservedChange> changeHandler = (change) =>
//            {
//                if (weakThis.TryGetTarget(out var dataManager))
//                {
//                    // Ignore any change notifications coming from data this
//                    // instance just saved to `NSUserDefaults`.
//                    if (dataManager is null || dataManager.IgnoreLocalUserDefaultsChanges)
//                    {
//                        return;
//                    }
//                    // The underlying data changed in `NSUserDefaults`, so
//                    // update this instance with the change and notify clients
//                    // of the change.
//                    dataManager.LoadData();
//                    dataManager.NotifyClientsDataChanged();
//                }
//            };
//            UserDefaultsObserver = UserDefaults.AddObserver(
//                StorageDescriptor.Key,
//                NSKeyValueObservingOptions.Initial | NSKeyValueObservingOptions.New,
//                changeHandler
//            );
//        }
//        // Notifies clients the data changed by posting an `NSNotification` with
//        // the key `NotificationKeys.DataChanged`
//        void NotifyClientsDataChanged()
//        {
//            var notification = NSNotification.FromName(NotificationKeys.DataChanged, this);
//            NSNotificationCenter.DefaultCenter.PostNotification(notification);
//        }
//        protected virtual void FinishUnarchiving(NSObject unarchivedData)
//        {
//            throw new NotImplementedException();
//        }
//        // Loads the data from `NSUserDefaults`.
//        void LoadData()
//        {
//            UserDefaultsAccessQueue.DispatchSync(() =>
//            {
//                NSData archivedData = UserDefaults.DataForKey(StorageDescriptor.Key);
//                try
//                {
//                    // Let the derived classes handle the specifics of
//                    // putting the unarchived data in the correct format.
//                    // This is necessary because the derived classes
//                    // (SoupMenuManager, SoupOrderMenuManager) are using
//                    // generic data formats (NSMutableSet<T> or NSMutableArray<T>)
//                    // and these types cannot be casted directly from the
//                    // deserialized data.
//                    NSObject unarchivedData = NSKeyedUnarchiver.UnarchiveObject(archivedData);
//                    FinishUnarchiving(unarchivedData);
//                }
//                catch (Exception e)
//                {
//                    if (!(e is null))
//                    {
//                        Console.WriteLine($"Error: {e.Message}");
//                    }
//                }
//            });
//        }
//        // Writes the data to `NSUserDefaults`
//        protected void WriteData()
//        {
//            UserDefaultsAccessQueue.DispatchAsync(() =>
//            {
//                try
//                {
//                    NSData encodedData = NSKeyedArchiver.ArchivedDataWithRootObject(ManagedDataBackingInstance);
//                    IgnoreLocalUserDefaultsChanges = true;
//                    UserDefaults.SetValueForKey(encodedData, (NSString)StorageDescriptor.Key);
//                    IgnoreLocalUserDefaultsChanges = false;
//                    NotifyClientsDataChanged();
//                }
//                catch (Exception e)
//                {
//                    throw new Exception($"Could not save data. Reason: {e.Message}");
//                }
//            });
//        }
//    }
//}
SiriKit/Data/NSUserDefaultsHelper.cs
New file
@@ -0,0 +1,40 @@
using System;
using Foundation;
namespace SiriKit
{
    public static class NSUserDefaultsHelper
    {
        private const string AppGroup = "group.com.hdl.onpro";
        public static class StorageKeys
        {
            public const string APP_KEY = "HDL-HOME-APP-TEST";
            public const string SECRET_KEY = "WeJ8TY88vbakCcnvH8G1tDUqzLWY8yss";
            public const string GLOBAL_GIsLogin = "IsLogin";
            public const string GLOBAL_GAccessToken = "AccessToken";
            public const string GLOBAL_GRefreshToken = "RefreshToken";
            public const string GLOBAL_GRegionUrl = "RegionUrl";
            public const string GLOBAL_GHomeId = "HomeId";
        }
        public static NSUserDefaults DataSuite {
            get {
                var dataSuite = new NSUserDefaults(AppGroup, NSUserDefaultsType.SuiteName);
                if( dataSuite is null )
                {
                    throw new Exception($"Could not load UserDefaults for app group {AppGroup}");
                }
                return dataSuite;
            }
        }
    }
}
SiriKit/Data/SceneDateManager.cs
New file
@@ -0,0 +1,104 @@
using Foundation;
using Intents;
using System;
using System.Linq;
namespace SiriKit
{
    public class SceneDateManager //: DataManager<NSMutableArray<HDLSceneSiri.HDLSiriSceneModel>>
    {
        public SceneDateManager() { }//: base(new UserDefaultsStorageDescriptor(NSUserDefaultsHelper.StorageKeys.OrderHistory), new NSMutableArray<HDLSceneSiri.HDLSiriSceneModel>()) { }
        protected NSUserDefaults UserDefaults = NSUserDefaultsHelper.DataSuite;
        //#region Public API for clients of `SoupOrderDataManager`
        //// Convenience method to access the data with a property name that makes
        //// sense in the caller's context.
        //public NSMutableArray<HDLSceneSiri.HDLSiriSceneModel> OrderHistory
        //{
        //    get
        //    {
        //        return ManagedData as NSMutableArray<HDLSceneSiri.HDLSiriSceneModel>;
        //    }
        //}
        //#endregion
        //#region Support methods for unarchiving saved data
        //override protected void FinishUnarchiving(NSObject unarchivedData)
        //{
        //    var array = (NSArray)unarchivedData;
        //    HDLSceneSiri.HDLSiriSceneModel[] orders = NSArray.FromArray<HDLSceneSiri.HDLSiriSceneModel>(array);
        //    ManagedDataBackingInstance = new NSMutableArray<HDLSceneSiri.HDLSiriSceneModel>(orders);
        //}
        //#endregion
        public bool IsLgoin
        {
            get
            {
                var d = UserDefaults.BoolForKey(NSUserDefaultsHelper.StorageKeys.GLOBAL_GIsLogin);
                return d;
            }
            set
            {
                UserDefaults.SetBool(value, NSUserDefaultsHelper.StorageKeys.GLOBAL_GIsLogin);
            }
        }
        public string AccessToken
        {
            get
            {
                var d = UserDefaults.StringForKey(NSUserDefaultsHelper.StorageKeys.GLOBAL_GAccessToken);
                return d;
            }
            set
            {
                UserDefaults.SetString(value, NSUserDefaultsHelper.StorageKeys.GLOBAL_GAccessToken);
            }
        }
        public string RefreshToken
        {
            get
            {
                var d = UserDefaults.StringForKey(NSUserDefaultsHelper.StorageKeys.GLOBAL_GRefreshToken);
                return d;
            }
            set
            {
                UserDefaults.SetString(value, NSUserDefaultsHelper.StorageKeys.GLOBAL_GRefreshToken);
            }
        }
        public string RegionUrl
        {
            get
            {
                var d = UserDefaults.StringForKey(NSUserDefaultsHelper.StorageKeys.GLOBAL_GRegionUrl);
                return d;
            }
            set
            {
                UserDefaults.SetString(value, NSUserDefaultsHelper.StorageKeys.GLOBAL_GRegionUrl);
            }
        }
        public string HomeId
        {
            get
            {
                var d = UserDefaults.StringForKey(NSUserDefaultsHelper.StorageKeys.GLOBAL_GHomeId);
                return d;
            }
            set
            {
                UserDefaults.SetString(value, NSUserDefaultsHelper.StorageKeys.GLOBAL_GHomeId);
            }
        }
    }
}
SiriKit/Properties/AssemblyInfo.cs
New file
@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("SiriKit")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("SiriKit")]
[assembly: AssemblyCopyright("Copyright ©  2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components.  If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("50c7b8c9-e664-45af-b88e-0c9b8b9c1be1")]
// Version information for an assembly consists of the following four values:
//
//      Major Version
//      Minor Version
//      Build Number
//      Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
SiriKit/SiriKit.csproj
New file
@@ -0,0 +1,60 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProductVersion>8.0.30703</ProductVersion>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectGuid>{8B1652FA-5158-4D57-B90D-07BB91766625}</ProjectGuid>
    <ProjectTypeGuids>{FEACFBD2-3405-455C-9665-78FE426C6842};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
    <TemplateGuid>{a52b8a63-bc84-4b47-910d-692533484892}</TemplateGuid>
    <OutputType>Library</OutputType>
    <RootNamespace>SiriKit</RootNamespace>
    <IPhoneResourcePrefix>Resources</IPhoneResourcePrefix>
    <AssemblyName>SiriKit</AssemblyName>
    <RestoreProjectStyle>PackageReference</RestoreProjectStyle>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>portable</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\Debug</OutputPath>
    <DefineConstants>DEBUG;</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <DebugType>portable</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\Release</OutputPath>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="System" />
    <Reference Include="System.Xml" />
    <Reference Include="System.Core" />
    <Reference Include="Xamarin.iOS" />
    <Reference Include="Shared.IOS.HDLSceneSiri">
      <HintPath>..\DLL\IOS\Shared.IOS.HDLSceneSiri.dll</HintPath>
    </Reference>
  </ItemGroup>
  <ItemGroup>
    <Folder Include="Resources\" />
    <Folder Include="Data\" />
    <Folder Include="Support\" />
    <Folder Include="Base.lproj\" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="Properties\AssemblyInfo.cs" />
    <Compile Include="Data\DataManager.cs" />
    <Compile Include="Data\SceneDateManager.cs" />
    <Compile Include="Data\NSUserDefaultsHelper.cs" />
  </ItemGroup>
  <ItemGroup>
    <Content Include="Base.lproj\Intents.intentdefinition" />
  </ItemGroup>
  <Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.CSharp.targets" />
</Project>
ThirdPartyIntegration/siri/libOnProSiriIntents.a
Binary files differ