wei
2021-04-20 9189e6c3fa549717e95a4d29de890941197eee03
增加二次调试开关
30个文件已修改
1 文件已重命名
605 ■■■■■ 已修改文件
.vs/HDL_APP_Project/xs/UserPrefs.xml 52 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_Android/Properties/AndroidManifest.xml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL-ON_iOS/Info.plist 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Common/ApiUtlis.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Common/FileUtlis.cs 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Mqtt/MqttClient.cs 30 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/HttpServerRequest.cs 176 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/HttpUtil.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/NewAPI.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Entity/DB_ResidenceData.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Entity/Function/SecurityAlarm.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Entity/FunctionList.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Entity/ResponseEntity/RegionInfoRes.cs 112 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/Entity/Room.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/HDL_ON.projitems 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/MainPage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI0-Stan/Logic/HdlCloudReceiveLogic.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI1-Login/LoginPage.cs 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/1-HomePage/HomePage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/AddDevice/AddMiniRemoteControlDirection4Page.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/MemberManagement/MemberFunctionPermissionPageBLL.cs 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/MemberManagement/MemberPermissionPageBLL.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/MyQRCodePage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPageBLL.cs 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/AddRoom/RoomBinglingFloorPage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/FloorsManagementPage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/ResidentialManagePage.cs 136 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/ResidentialManagePageBLL.cs 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
.vs/HDL_APP_Project/xs/UserPrefs.xml
@@ -1,48 +1,18 @@
<Properties StartupConfiguration="{09712674-2A38-407B-B1E2-560B2C352F9A}|Default">
  <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS automaticSigning="False" PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneSimulatorTarget.26569F89-0BA9-4C06-81F2-764A3AF2E1B7" />
  <MonoDevelop.Ide.Workbench ActiveDocument="HDL_ON/UI/UI2/1-HomePage/MessageCenterPage.cs">
<Properties StartupConfiguration="{D998E133-F0DD-4760-BE3C-461632F54DA4}|Default">
  <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS automaticSigning="False" PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneDeviceTarget.00008020-000404163432002E" />
  <MonoDevelop.Ide.Workbench ActiveDocument="HDL_ON/UI/UI2/1-HomePage/HomePage.cs">
    <Files>
      <File FileName="HDL_ON/UI/UI2/FuntionControlView/ArmCenter/ArmCenterPage.cs" Line="66" Column="1" />
      <File FileName="HDL_ON/Common/ApiUtlis.cs" Line="367" Column="38" />
      <File FileName="HDL_ON/Entity/FunctionList.cs" Line="143" Column="31" />
      <File FileName="HDL_ON/UI/UI2/2-Classification/ClassificationPage.cs" Line="565" Column="50" />
      <File FileName="HDL_ON/Entity/Enumerative/MyEnum.cs" Line="171" Column="9" />
      <File FileName="HDL_ON/Entity/Room.cs" Line="58" Column="23" />
      <File FileName="HDL_ON/UI/BindingResidence/BindingResidencePage.cs" Line="1" Column="1" />
      <File FileName="HDL_ON/UI/UI2/1-HomePage/MessageCenterPage.cs" Line="1" Column="1" />
      <File FileName="HDL_ON/Entity/ResponseEntity/RegionInfoRes.cs" Line="66" Column="22" />
      <File FileName="HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPageBLL.cs" Line="203" Column="92" />
      <File FileName="HDL_ON/UI/UI2/1-HomePage/HomePage.cs" Line="165" Column="14" />
      <File FileName="HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/ResidentialManagePageBLL.cs" Line="145" Column="60" />
      <File FileName="HDL_ON/Entity/DB_ResidenceData.cs" Line="29" Column="16" />
    </Files>
    <Pads>
      <Pad Id="ProjectPad">
        <State name="__root__">
          <Node name="HDL_APP_Project" expanded="True">
            <Node name="HDL_ON" expanded="True">
              <Node name="Common" expanded="True" />
              <Node name="DAL" expanded="True">
                <Node name="Server" expanded="True" />
              </Node>
              <Node name="Entity" expanded="True">
                <Node name="Enumerative" expanded="True" />
                <Node name="Function" expanded="True" />
              </Node>
              <Node name="UI" expanded="True">
                <Node name="BindingResidence" expanded="True" />
                <Node name="UI2" expanded="True">
                  <Node name="1-HomePage" expanded="True">
                    <Node name="MessageCenterPage.cs" selected="True" />
                  </Node>
                  <Node name="FuntionControlView" expanded="True">
                    <Node name="ArmCenter" expanded="True" />
                  </Node>
                </Node>
              </Node>
            </Node>
            <Node name="HDL-ON_Android" expanded="True">
              <Node name="Assets" expanded="True" />
            </Node>
            <Node name="HDL-ON_iOS" expanded="True">
              <Node name="Other" expanded="True" />
              <Node name="Resources" expanded="True" />
            </Node>
            <Node name="HDL-ON_iOS" expanded="True" selected="True" />
          </Node>
        </State>
      </Pad>
@@ -54,8 +24,8 @@
    <String>Shared.Droid.TouchID/Shared.Droid.TouchID.csproj</String>
    <String>Shared.IOS/Shared.IOS.csproj</String>
  </DisabledProjects>
  <MonoDevelop.Ide.Workspace ActiveConfiguration="Debug" />
  <MonoDevelop.Ide.ItemProperties.HDL-ON__Android PreferredExecutionTarget="Android.364c4b3158493098" />
  <MonoDevelop.Ide.Workspace ActiveConfiguration="Release|iPhone" />
  <MonoDevelop.Ide.ItemProperties.HDL-ON__Android PreferredExecutionTarget="Android.SelectDevice" />
  <MonoDevelop.Ide.DebuggingService.Breakpoints>
    <BreakpointStore>
      <Breakpoint file="/Users/kaede/Desktop/HDL_APP_Project/HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/Method.cs" relfile="HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/Method.cs" line="34" column="1" />
HDL-ON_Android/Properties/AndroidManifest.xml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="202104131" android:versionName="1.2.202104131" package="com.hdl.onpro">
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="202104191" android:versionName="1.2.202104191" package="com.hdl.onpro">
    <uses-sdk android:minSdkVersion="26" android:targetSdkVersion="26" />
    <!--  可视对讲权限-->
    <uses-permission android:name="android.permission.CAMERA" />
HDL-ON_iOS/Info.plist
@@ -104,9 +104,9 @@
    <key>UIStatusBarStyle</key>
    <string>UIStatusBarStyleLightContent</string>
    <key>CFBundleShortVersionString</key>
    <string>1.2.202104131</string>
    <string>1.2.202104201</string>
    <key>CFBundleVersion</key>
    <string>202104131</string>
    <string>202104201</string>
    <key>NSLocationWhenInUseUsageDescription</key>
    <string>Use geographic location to provide services such as weather</string>
    <key>NSAppleMusicUsageDescription</key>
HDL_ON/Common/ApiUtlis.cs
@@ -362,14 +362,14 @@
            var pack = Ins.HttpRequest.GetSecurityList();
            if (pack.Code == StateCode.SUCCESS)
            {
                var packList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Security>>(pack.Data.ToString());
                var packList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<SecurityAlarm>>(pack.Data.ToString());
                var sidList = new List<string>();
                foreach (var function in packList)
                {
                    sidList.Add(function.sid);
                }
                var infoListPack = Ins.httpRequest.GetSecurityInfo(sidList, new List<string>());
                var infoList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Security>>(infoListPack.Data.ToString());
                var infoList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<SecurityAlarm>>(infoListPack.Data.ToString());
                foreach (var function in infoList)
                {
                    function.SaveFile();
HDL_ON/Common/FileUtlis.cs
@@ -49,13 +49,13 @@
        {
            get
            {
                if (DB_ResidenceData.Instance.CurrentRegion == null || DB_ResidenceData.Instance.CurrentRegion.RegionID == null)
                if (DB_ResidenceData.Instance.CurrentRegion == null || DB_ResidenceData.Instance.CurrentRegion.id == null)
                {
                    return AccountPath;
                }
                if (string.IsNullOrEmpty(regionPath) || !regionPath.Contains(DB_ResidenceData.Instance.CurrentRegion.RegionID))
                if (string.IsNullOrEmpty(regionPath) || !regionPath.Contains(DB_ResidenceData.Instance.CurrentRegion.id))
                {
                    regionPath = Path.Combine(AccountPath, DB_ResidenceData.Instance.CurrentRegion.RegionID);
                    regionPath = Path.Combine(AccountPath, DB_ResidenceData.Instance.CurrentRegion.id);
                    if (!Directory.Exists(regionPath))
                    {
                        Directory.CreateDirectory(regionPath);
HDL_ON/DAL/Mqtt/MqttClient.cs
@@ -189,38 +189,38 @@
                    };
                    var topicAlinkStatus = new MqttTopicFilter()
                    {
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/property/send",
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/property/send",
                        QualityOfServiceLevel = MQTTnet.Protocol.MqttQualityOfServiceLevel.AtMostOnce
                    };
                    //App订阅红外宝 / 网关遥控器添加成功通知
                    var pirStatus = new MqttTopicFilter()
                    {
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/topo/found",
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/topo/found",
                        QualityOfServiceLevel = MQTTnet.Protocol.MqttQualityOfServiceLevel.AtMostOnce
                    };
                    //App订阅遥控器自学按键学习成功通知
                    var pirStudy = new MqttTopicFilter()
                    {
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/event/irCodeStudyDone/up",
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/irCodeStudyDone/up",
                        QualityOfServiceLevel = MQTTnet.Protocol.MqttQualityOfServiceLevel.AtMostOnce
                    };
                    #region 数据更新推送主题
                    //appHomeRefresh:住宅数据刷新通知
                    var appHomeRefresh = new MqttTopicFilter()
                    {
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/event/appHomeRefresh/up",
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/appHomeRefresh/up",
                        QualityOfServiceLevel = MQTTnet.Protocol.MqttQualityOfServiceLevel.AtMostOnce
                    };
                    //appRoomRefresh:房间数据刷新通知
                    var appRoomRefresh = new MqttTopicFilter()
                    {
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/event/appRoomRefresh/up",
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/appRoomRefresh/up",
                        QualityOfServiceLevel = MQTTnet.Protocol.MqttQualityOfServiceLevel.AtMostOnce
                    };
                    //appDeviceRefresh:设备数据刷新通知
                    var appDeviceRefresh = new MqttTopicFilter()
                    {
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/event/appDeviceRefresh/up",
                        Topic = $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/appDeviceRefresh/up",
                        QualityOfServiceLevel = MQTTnet.Protocol.MqttQualityOfServiceLevel.AtMostOnce
                    };
                    #endregion
@@ -258,7 +258,7 @@
            {
                return;
            }
            if (DB_ResidenceData.Instance.CurrentRegion == null || DB_ResidenceData.Instance.CurrentRegion.RegionID == null)
            if (DB_ResidenceData.Instance.CurrentRegion == null || DB_ResidenceData.Instance.CurrentRegion.id == null)
            {
                return;
            }
@@ -326,14 +326,14 @@
                                    ReceiveNotifySqueezeAsync(mMes);
                                }
                                //App订阅红外宝/网关遥控器添加成功通知
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/topo/found")
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/topo/found")
                                {
                                    var bytes = Securitys.EncryptionService.AesDecryptPayload(e.ApplicationMessage.Payload, tuyaEncryptKey);
                                    var revString = Encoding.UTF8.GetString(bytes);
                                    HDL_ON.UI.UI2.PersonalCenter.PirDevice.Method.controldata = revString;
                                }
                                //App订阅遥控器自学按键学习成功通知
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/event/irCodeStudyDone/up")
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/irCodeStudyDone/up")
                                {
                                    var bytes = Securitys.EncryptionService.AesDecryptPayload(e.ApplicationMessage.Payload, tuyaEncryptKey);
                                    var revString = Encoding.UTF8.GetString(bytes);
@@ -341,13 +341,13 @@
                                }
                                #region 数据更新推送主题
                                //appHomeRefresh:住宅数据刷新通知
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/event/appHomeRefresh/up")
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/appHomeRefresh/up")
                                {
                                    MainPage.Log("住宅数据刷新通知");
                                    new HttpServerRequest().GetHomePager();
                                }
                                //appRoomRefresh:房间数据刷新通知
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/event/appRoomRefresh/up")
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/appRoomRefresh/up")
                                {
                                    MainPage.Log("房间数据刷新通知");
                                    var roomResult = new HttpServerRequest().GetRoomList();
@@ -369,7 +369,7 @@
                                    }
                                }
                                //appDeviceRefresh:设备数据刷新通知
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/event/appDeviceRefresh/up")
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/appDeviceRefresh/up")
                                {
                                    MainPage.Log("设备数据刷新通知");
                                    var deviceResult = new HttpServerRequest().GetDeviceList();
@@ -417,7 +417,7 @@
                                }
                                #endregion
                                //A网关设备状态-包含涂鸦设备
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/property/send")
                                else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/property/send")
                                {
                                    var bytes = Securitys.EncryptionService.AesDecryptPayload(e.ApplicationMessage.Payload, tuyaEncryptKey);
                                    var revString = Encoding.UTF8.GetString(bytes);
@@ -585,9 +585,9 @@
                    mqttEncryptKey = MqttInfoConfig.Current.HomeGatewayInfo.aesKey;
                    //解密密钥规则:已现有的住宅ID为基准,从右边一一获取值,最后如果不够16位,则往右补零
                    string aesKey = string.Empty;
                    for (int i = DB_ResidenceData.Instance.CurrentRegion.RegionID.Length - 1; i >= 0; i--)
                    for (int i = DB_ResidenceData.Instance.CurrentRegion.id.Length - 1; i >= 0; i--)
                    {
                        aesKey += DB_ResidenceData.Instance.CurrentRegion.RegionID[i].ToString();
                        aesKey += DB_ResidenceData.Instance.CurrentRegion.id[i].ToString();
                        if (aesKey.Length == 16) { break; }
                    }
                    aesKey = aesKey.PadRight(16, '0');
HDL_ON/DAL/Server/HttpServerRequest.cs
@@ -49,7 +49,7 @@
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("type", qType);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId", new List<string>() { deviceId });
            d.Add("key", new List<string>() { deviceKey });
@@ -66,7 +66,7 @@
        public ResponsePackNew GetArmSensorHistory( string deviceId,string pageSize, string pageNo)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId", deviceId);
            d.Add("pageSize", pageSize);
            d.Add("pageNo", pageNo);
@@ -465,33 +465,33 @@
            if (resultObj.Code == StateCode.SUCCESS)
            {
                UserInfo.Current.regionList = new List<RegionInfoRes>();
                var homeList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<RegionInfoResNew>>(resultObj.Data.ToString());
                var homeList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<RegionInfoRes>>(resultObj.Data.ToString());
                if (homeList == null || homeList.Count == 0)
                {
                }
                else
                {
                    foreach (var mHome in homeList)
                    foreach (var home in homeList)
                    {
                        var home = new RegionInfoRes()
                        {
                            RegionID = mHome.Id,
                            Name = mHome.homeName,
                            IsOthreShare = mHome.IsOtherShare,
                            accountType = mHome.accountType,
                            isRemoteControl = mHome.isRemoteControl,
                            isBindGateway = mHome.isBindGateway,
                            longitude = mHome.longitude,
                            latitude = mHome.latitude,
                            deliverstatus = mHome.deliverstatus,
                            homeType = mHome.homeType,
                            regionUrl = mHome.regionUrl,
                            emqUrl = mHome.emqUrl,
                            homeRegionName = mHome.homeRegionName,
                            homeRegionId = mHome.homeRegionId,
                            Address = mHome.homeAddress,
                            isAllowCreateScene = mHome.isAllowCreateScene,
                        };
                        //var home = new RegionInfoRes()
                        //{
                        //    RegionID = mHome.Id,
                        //    Name = mHome.homeName,
                        //    IsOthreShare = mHome.IsOtherShare,
                        //    accountType = mHome.accountType,
                        //    isRemoteControl = mHome.isRemoteControl,
                        //    isBindGateway = mHome.isBindGateway,
                        //    longitude = mHome.longitude,
                        //    latitude = mHome.latitude,
                        //    deliverstatus = mHome.deliverstatus,
                        //    homeType = mHome.homeType,
                        //    regionUrl = mHome.regionUrl,
                        //    emqUrl = mHome.emqUrl,
                        //    homeRegionName = mHome.homeRegionName,
                        //    homeRegionId = mHome.homeRegionId,
                        //    Address = mHome.homeAddress,
                        //    isAllowCreateScene = mHome.isAllowCreateScene,
                        //};
                        if (home.isBindGateway)
                        {
                            UserInfo.Current.regionList.Add(home);
@@ -502,7 +502,7 @@
                        return "null";
                    }
                    //-------如果账号是首次登录
                    if (DB_ResidenceData.Instance.CurrentRegion == null || string.IsNullOrEmpty(DB_ResidenceData.Instance.CurrentRegion.RegionID))
                    if (DB_ResidenceData.Instance.CurrentRegion == null || string.IsNullOrEmpty(DB_ResidenceData.Instance.CurrentRegion.id))
                    {
                        //刷新当前住宅
                        DB_ResidenceData.Instance.CurrentRegion = UserInfo.Current.regionList[0];
@@ -514,7 +514,7 @@
                    else
                    {
                        //住宅被删除
                        var findHome = UserInfo.Current.regionList.Find((obj) => obj.RegionID == DB_ResidenceData.Instance.CurrentRegion.RegionID);
                        var findHome = UserInfo.Current.regionList.Find((obj) => obj.id == DB_ResidenceData.Instance.CurrentRegion.id);
                        if (findHome == null)
                        {
                            Shared.Application.RunOnMainThread(() =>
@@ -556,7 +556,7 @@
        {
            var requestObj = new AddOrUpdateHomeObj()
            {
                homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                homeId = DB_ResidenceData.Instance.CurrentRegion.id,
            };
            if (editId == 0)
@@ -579,14 +579,14 @@
        {
            try
            {
                if (string.IsNullOrEmpty(DB_ResidenceData.Instance.CurrentRegion.RegionID)) return "";
                var nowhomeId = DB_ResidenceData.Instance.CurrentRegion.RegionID;
                if (string.IsNullOrEmpty(DB_ResidenceData.Instance.CurrentRegion.id)) return "";
                var nowhomeId = DB_ResidenceData.Instance.CurrentRegion.id;
                var requestJson = HttpUtil.GetSignRequestJson(new HomeIdObj() { homeId = nowhomeId });
                var revertObj = HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_GetGatewayList, requestJson);
                if (revertObj.Code == StateCode.SUCCESS)
                {
                    var mHomeGatewayRes = Newtonsoft.Json.JsonConvert.DeserializeObject<List<HomeGatewayInfo>>(revertObj.Data.ToString());
                    if (nowhomeId == DB_ResidenceData.Instance.CurrentRegion.RegionID)
                    if (nowhomeId == DB_ResidenceData.Instance.CurrentRegion.id)
                    {
                        if (mHomeGatewayRes != null)
                        {
@@ -622,7 +622,7 @@
            if (DB_ResidenceData.Instance.HomeGateway == null)
                return StateCode.NETWORK_ERROR;
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway.gatewayId);
            var jsonString = HttpUtil.GetSignRequestJson(d);
            var revertObj = HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetGatewayInfo, jsonString);
@@ -643,7 +643,7 @@
        /// <returns></returns>
        public ResponsePackNew GetResidenceMemberAccount()
        {
            var requestJson = HttpUtil.GetSignRequestJson(new HomeIdObj() { homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID });
            var requestJson = HttpUtil.GetSignRequestJson(new HomeIdObj() { homeId = DB_ResidenceData.Instance.CurrentRegion.id });
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_Child_FindAll, requestJson);
        }
@@ -672,7 +672,7 @@
        {
            var requestJson = HttpUtil.GetSignRequestJson(new UpdateChildNickNameObj()
            {
                homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                homeId = DB_ResidenceData.Instance.CurrentRegion.id,
                childAccountId = childAccountId,
                nickName = nickName,
            });
@@ -689,7 +689,7 @@
        {
            var requestJson = HttpUtil.GetSignRequestJson(new UpdateChildAllowCreateSceneObj()
            {
                homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                homeId = DB_ResidenceData.Instance.CurrentRegion.id,
                childAccountId = childAccountId,
                isAllowCreateScene = isAllow,
            });
@@ -730,12 +730,13 @@
        {
            var requestJson = HttpUtil.GetSignRequestJson(new GetShareObj()
            {
                homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                homeId = DB_ResidenceData.Instance.CurrentRegion.id,
                childAccountId = childAccountId,
            });
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_Share_GetList, requestJson);
        }
        #endregion
        ///// <summary>
@@ -869,26 +870,27 @@
        public ResponsePackNew BindResidenceMemberAccount(string subAccount, string nickName)
        {
            //添加子账号
            var requestObj = new ChildAddObj() { homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID, account = subAccount, nickName = nickName };
            var requestObj = new ChildAddObj() { homeId = DB_ResidenceData.Instance.CurrentRegion.id, account = subAccount, nickName = nickName };
            var requestJson = HttpUtil.GetSignRequestJson(requestObj);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_Child_Add, requestJson);
        }
        ///// <summary>
        ///// 获取住宅下的成员账号信息
        ///// </summary>
        ///// <returns></returns>
        //public ResponsePack GetResidenceMemberAccountInfo(string account)
        //{
        //    Dictionary<string, object> d = new Dictionary<string, object>();
        //    d.Add("Account", account);
        //    string jsonString = Newtonsoft.Json.JsonConvert.SerializeObject(d);
        //    return RequestHttps($"{severAddress}/ZigbeeUsers/GetSubAccountInfo", jsonString, true);
        //}
        /// <summary>
        /// 修改住宅调试权限
        /// </summary>
        /// <returns></returns>
        public ResponsePackNew ChangeResidenceDebugPerm(bool debugPerm)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("debugPerm", debugPerm);
            string jsonString = Newtonsoft.Json.JsonConvert.SerializeObject(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_Post_Home_UpdateDebugPerm, jsonString);
        }
        #endregion
        /// <summary>
@@ -1778,7 +1780,7 @@
        public ResponsePackNew GetDeviceList()
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            //d.Add("gatewayId", DB_ResidenceData.residenceData.HomeGateway.gatewayId);
            //d.Add("roomId", DB_ResidenceData.residenceData.residecenInfo.RegionID);//可控参数,当需要分页获取,怎么知道分页总数
            //d.Add("searchType", DB_ResidenceData.residenceData.residecenInfo.RegionID);
@@ -1797,7 +1799,7 @@
        public ResponsePackNew Get3TyBrandBindDeviceList(string productPlatform, string productBrand)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("productPlatform", productPlatform);
            d.Add("productBrand", productBrand);
            d.Add("networkConfig", true);
@@ -1831,7 +1833,7 @@
        public ResponsePackNew GetDeviceInfo(string functionId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceIds", new List<string>() { functionId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -1845,7 +1847,7 @@
        public ResponsePackNew GetDeviceInfoList(List<string> functionIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceIds", functionIds);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -1858,7 +1860,7 @@
        public ResponsePackNew RefreshDeviceStatus(List<string> functionIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceIds", functionIds);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -1873,7 +1875,7 @@
        public ResponsePackNew ControlDevice(List<ApiAlinkControlActionObj> actionObjs)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway == null ? "0" : DB_ResidenceData.Instance.HomeGateway.gatewayId);//DriverLayer.Control.Ins.GatewayId);
            d.Add("actions", actionObjs);
@@ -1889,7 +1891,7 @@
        public ResponsePackNew UpdataDevcieInfo(Function function)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId", function.deviceId);
            d.Add("name", function.name);
            d.Add("collect", function.collect);
@@ -1905,7 +1907,7 @@
        public ResponsePackNew UpdataDevcieBindRoomInfo(Function function)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId", function.deviceId);
            d.Add("roomIds", function.roomIds);
@@ -1920,7 +1922,7 @@
        public ResponsePackNew BindDeviceToRoom(List<string> deviceIds,List<string> roomIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceIds", deviceIds);
            d.Add("roomIds", roomIds);
@@ -1933,7 +1935,7 @@
        public string UnbindDeviceToRoom(string deviceId, string roomId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceIds", new List<string>() { deviceId });
            d.Add("roomIds", new List<string>() { roomId });
@@ -1946,7 +1948,7 @@
        public string EditDeviceName(string deviceId, string deviceName)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId", deviceId);
            d.Add("name", deviceName);
@@ -1959,7 +1961,7 @@
        public ResponsePackNew CollectDevice(string deviceId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceIds",new List<string>() { deviceId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -1971,7 +1973,7 @@
        public ResponsePackNew CancelCollectDevice(string deviceId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceIds", new List<string>() { deviceId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -1990,7 +1992,7 @@
        public ResponsePackNew GetSceneList(string roomId = null)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            if (roomId != null)
            {
                d.Add("roomId", roomId);
@@ -2034,7 +2036,7 @@
        public ResponsePackNew AddScene(Scene scene)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("scenes", new List<Scene>() { scene });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2052,7 +2054,7 @@
        public ResponsePackNew EditScene(Scene scene)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("scenes", new List<Scene>() { scene });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2065,7 +2067,7 @@
        public string DeleteScene(string userSceneId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("userSceneIds", new List<string>() { userSceneId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2078,7 +2080,7 @@
        public string ExecuteScene(string userSceneId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("userSceneIds", new List<string>() { userSceneId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2092,7 +2094,7 @@
        public string CollectScene(string userSceneId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("userSceneIds", new List<string>() { userSceneId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2106,7 +2108,7 @@
        public string CancelCollectScene(string userSceneId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("userSceneIds", new List<string>() { userSceneId });
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2123,7 +2125,7 @@
        public ResponsePackNew GetRoomList(string GetType = "All")
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            if (GetType != "All")
            {
                d.Add("roomType", GetType);
@@ -2142,7 +2144,7 @@
        public ResponsePackNew AddRoom(List<SpatialInfo> rooms)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("rooms", rooms);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2161,7 +2163,7 @@
        public ResponsePackNew UpdateRoom(List<SpatialInfo> rooms)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("rooms", rooms);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2181,7 +2183,7 @@
        public ResponsePackNew DeleteRoom(List<string> roomIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("ids", roomIds);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2199,7 +2201,7 @@
        public ResponsePackNew GetSecurityList()
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway.gatewayId);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_Security_List, requestJson);
@@ -2214,7 +2216,7 @@
        public ResponsePackNew GetSecurityInfo(List<string> sidList, List<string> userSecurityIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway.gatewayId);
            //sids userSecurityIds 不能同时为空
            d.Add("sids", sidList);
@@ -2226,10 +2228,10 @@
        /// <summary>
        /// 添加安防
        /// </summary>
        public ResponsePackNew AddSecurity(List<Security> securities)
        public ResponsePackNew AddSecurity(List<SecurityAlarm> securities)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway.gatewayId);
            d.Add("securitys", securities);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2239,10 +2241,10 @@
        /// <summary>
        /// 编辑安防
        /// </summary>
        public ResponsePackNew EditSecurity(List<Security> securities)
        public ResponsePackNew EditSecurity(List<SecurityAlarm> securities)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway.gatewayId);
            d.Add("securitys", securities);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2258,7 +2260,7 @@
        public ResponsePackNew DeleteSecurity(List<string> sidList, List<string> userSecurityIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway.gatewayId);
            //sids userSecurityIds 不能同时为空
            d.Add("sids", sidList);
@@ -2276,7 +2278,7 @@
        public ResponsePackNew ReadSecurityStatus(List<string> sidList, List<string> userSecurityIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway.gatewayId);
            //sids userSecurityIds 不能同时为空
            d.Add("sids", sidList);
@@ -2291,7 +2293,7 @@
        public ResponsePackNew SetSecurityStatus(List<SecurityState> securityStates)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("securitys", securityStates);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_Security_StatusSet, requestJson);
@@ -2304,7 +2306,7 @@
        public ResponsePackNew SetSecurityBypass(List<SecurityBypass> securityBypassStates)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("securitys", securityBypassStates);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_Security_BypassSet, requestJson);
@@ -2319,7 +2321,7 @@
        public ResponsePackNew ReadSecurityBypass(List<string> sidList, List<string> userSecurityIds)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("gatewayId", DB_ResidenceData.Instance.HomeGateway.gatewayId);
            //sids userSecurityIds 不能同时为空
            d.Add("sids", sidList);
@@ -2334,7 +2336,7 @@
        public ResponsePackNew GetSecurityLogList(string pageSize,string pageNo)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("pageSize", pageSize);
            d.Add("pageNo", pageNo);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2347,7 +2349,7 @@
        public ResponsePackNew GetSecurityAlarmLogList(string pageSize, string pageNo)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("pageSize", pageSize);
            d.Add("pageNo", pageNo);
            var requestJson = HttpUtil.GetSignRequestJson(d);
@@ -2376,7 +2378,7 @@
        public ResponsePackNew Get3tyBindBrandList()
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetBindBrandList, requestJson);
@@ -2406,7 +2408,7 @@
        public ResponsePackNew CheckFlVideo()
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.RegionID);
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome( NewAPI.API_POST_FL_Check, requestJson);
            return pack;
HDL_ON/DAL/Server/HttpUtil.cs
@@ -17,8 +17,8 @@
        /// 固定域名,正式环境
        /// 公共域名就近解析
        /// </summary>
        //public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com";
        public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";
        public const string GlobalRequestHttpsHost = "https://nearest.hdlcontrol.com";
        //public const string GlobalRequestHttpsHost = "https://test-gz.hdlcontrol.com";
        /// <summary>
        /// RegionMark
        /// </summary>
HDL_ON/DAL/Server/NewAPI.cs
@@ -103,6 +103,10 @@
        /// 住宅迁移
        /// </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";
        #endregion
        #region ■ 子账号 -- 添加住宅成员___________________________
HDL_ON/Entity/DB_ResidenceData.cs
@@ -30,7 +30,7 @@
            {
                if (MainPage.NoLoginMode)
                {
                    return new RegionInfoRes() { Name = "本地模式" };
                    return new RegionInfoRes() { homeName = "本地模式" };
                }
                else
                {
HDL_ON/Entity/Function/SecurityAlarm.cs
File was renamed from HDL_ON/Entity/Function/Security.cs
@@ -4,7 +4,7 @@
namespace HDL_ON.Entity
{
    public class Security
    public class SecurityAlarm
    {
        /// <summary>
        /// 安防sid
HDL_ON/Entity/FunctionList.cs
@@ -140,7 +140,7 @@
        /// <summary>
        /// 安防列表
        /// </summary>
        public List<Security> securities = new List<Security>();
        public List<SecurityAlarm> securities = new List<SecurityAlarm>();
        /// <summary>
        /// 加载功能列表
@@ -191,7 +191,7 @@
            {
                var dataBytes = FileUtlis.Files.ReadFile(filePath);
                var dataString = System.Text.Encoding.UTF8.GetString(dataBytes);
                var temp = Newtonsoft.Json.JsonConvert.DeserializeObject<Security>(dataString);
                var temp = Newtonsoft.Json.JsonConvert.DeserializeObject<SecurityAlarm>(dataString);
                if (temp == null)
                {
                    MainPage.Log("null");
HDL_ON/Entity/ResponseEntity/RegionInfoRes.cs
@@ -54,23 +54,19 @@
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string RegionID { get; set; }
        public string id { get; set; }
        /// <summary>
        /// 住宅名称
        /// </summary>
        public string Name { get; set; }
        public string homeName { get; set; }
        /// <summary>
        /// 住宅地址
        /// </summary>
        public string Address { get; set; }
        public string homeAddress { get; set; }
        /// <summary>
        /// 是否为其他主用户分享过来的住宅
        /// </summary>
        public bool IsOthreShare = false;
        /// <summary>
        ///
        /// </summary>
        public List<HomeGateways> homeGateways = new List<HomeGateways>();
        //2020-11-13 新增
        /// <summary>
@@ -81,7 +77,7 @@
        /// <summary>
        /// 是否支持远程
        /// </summary>
        public bool isRemoteControl;
        public bool isRemoteControl;//??
        /// <summary>
        /// 经度
        /// </summary>
@@ -99,15 +95,11 @@
        /// </summary>
        public string homeType;
        /// <summary>
        ///
        /// </summary>
        public string createonutc;
        /// <summary>
        /// 区域服务器
        /// </summary>
        public string regionUrl;
        /// <summary>
        /// 区域服务器
        /// emq服务器
        /// </summary>
        public string emqUrl;
        /// <summary>
@@ -115,97 +107,21 @@
        /// </summary>
        public string homeRegionId;
        /// <summary>
        /// 住宅区域名字
        /// </summary>
        public string homeRegionName;
        /// <summary>
        /// 是否允许创建场景
        /// </summary>
        public bool isAllowCreateScene;
        public bool isAllowCreateScene;//??
        /// <summary>
        /// 是否绑定网关
        /// </summary>
        public bool isBindGateway;
        /// <summary>
        /// 调试人员ID
        /// </summary>
        public string debugStaffUserId;
        /// <summary>
        /// 调试权限是否打开
        /// </summary>
        public bool debugPerm;
    }
    /// <summary>
    /// 新云端住宅列表返回字段
    /// </summary>
    [Serializable]
    public class RegionInfoResNew
    {
        /// <summary>
        /// 住宅ID
        /// </summary>
        public string Id;
        /// <summary>
        /// 住宅名字
        /// </summary>
        public string homeName;
        /// <summary>
        /// 是否为其他主用户分享过来的住宅
        /// </summary>
        public bool IsOtherShare;
        /// <summary>
        /// 仅子账号登陆的时候使用,当【IsOthreShare】为"true",
        /// 子账户类型 1.ORDINARY 2.DEBUG 3.ADMIN
        /// </summary>
        public string accountType;
        /// <summary>
        /// 是否支持远程
        /// </summary>
        public bool isRemoteControl;
        /// <summary>
        /// 住宅空间结构Id
        /// </summary>
        public string structId;
        /// <summary>
        /// 经度
        /// </summary>
        public double longitude;
        /// <summary>
        /// 纬度
        /// </summary>
        public double latitude;
        /// <summary>
        /// 交付状态
        /// </summary>
        public string deliverstatus;
        /// <summary>
        /// 住宅类型 Zigbee, Buspro, A
        /// </summary>
        public string homeType;
        /// <summary>
        ///
        /// </summary>
        public string createonutc;
        /// <summary>
        /// 区域服务器
        /// </summary>
        public string regionUrl;
        /// <summary>
        /// 区域服务器
        /// </summary>
        public string emqUrl;
        /// <summary>
        /// 住宅区域Id
        /// </summary>
        public string homeRegionId;
        /// <summary>
        /// 住宅区域名字
        /// </summary>
        public string homeRegionName;
        /// <summary>
        /// 是否绑定网关
        /// </summary>
        public bool isBindGateway;
        /// <summary>
        /// 住宅地址
        /// </summary>
        public string homeAddress;
        /// <summary>
        /// 是否允许创建场景
        /// </summary>
        public bool isAllowCreateScene;
    }
}
HDL_ON/Entity/Room.cs
@@ -46,7 +46,7 @@
        public SpatialInfo(string spatialType)
        {
            roomType = "FLOOR";
            parentId = DB_ResidenceData.Instance.CurrentRegion.RegionID;
            parentId = DB_ResidenceData.Instance.CurrentRegion.id;
        }
        public string roomId = "";
HDL_ON/HDL_ON.projitems
@@ -400,7 +400,7 @@
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\3-Intelligence\Automation\InputPushText.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\3-Intelligence\Automation\AirQuality.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\ArmCenter\ArmCenterPage.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)Entity\Function\Security.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)Entity\Function\SecurityAlarm.cs" />
  </ItemGroup>
  <ItemGroup>
    <Folder Include="$(MSBuildThisFileDirectory)DAL\" />
HDL_ON/UI/MainPage.cs
@@ -20,7 +20,7 @@
        /// <summary>
        /// 版本号
        /// </summary>
        public static string VersionString = "1.2.0413";
        public static string VersionString = "1.2.0420";
        ///// <summary>
        ///// 客户端类型
        ///// </summary>
HDL_ON/UI/UI0-Stan/Logic/HdlCloudReceiveLogic.cs
@@ -59,7 +59,7 @@
        public bool CloudOverallMsgReceiveEx(string topic, byte[] byteData, string mqttEncryptKey, string homeIdEncryptKey)
        {
            //设备入网上报主题
            if (topic == $"/user/{Entity.DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/topo/found")
            if (topic == $"/user/{Entity.DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/topo/found")
            {
                if (string.IsNullOrEmpty(homeIdEncryptKey) == false)
                {
@@ -84,7 +84,7 @@
            if (ListCloudEvent.Count == 0) { return false; }
            //设备入网上报主题(目前只有红外宝)
            if (topic == $"/user/{Entity.DB_ResidenceData.Instance.CurrentRegion.RegionID}/app/thing/topo/found")
            if (topic == $"/user/{Entity.DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/topo/found")
            {
                for (int i = 0; i < this.ListCloudEvent.Count; i++)
                {
HDL_ON/UI/UI1-Login/LoginPage.cs
@@ -199,15 +199,16 @@
                //return;
                if (b)
                {
                    etAccount.Text = "18316672920";//"18316120654";//lcg "18316672920";//hzx;// "13415629083"//cf;//tujie"18316120654";
                    etAccount.Text = "13226233133";//豆豆
                    //etAccount.Text = "18316672920";//"18316120654";//lcg "18316672920";//hzx;// "13415629083"//cf;//tujie"18316120654";
                    // "15622703419"lwn;// "18824864143";//"464027401@qq.com"; //"2791308028@qq.com";//13697499568 
                }
                else
                {
                    //etAccount.Text = "BB01010101@evoyo.com";//可视对讲
                    //etAccount.Text = "13168123446";
                    //etAccount.Text = "13602944661";//kx
                    etAccount.Text = "18316120654";//凉霸"18666455392";//13375012446//13602944661//tzy 18778381374
                    etAccount.Text = "13602944661";//kx
                    //etAccount.Text = "18316120654";//凉霸"18666455392";//13375012446//13602944661//tzy 18778381374
                    //etAccount.Text = "15971583093";// gs//tzy 274116637@qq.com//Sumant.Bhatia@havells.com 国外服务器测试
                }
                b = !b;
HDL_ON/UI/UI2/1-HomePage/HomePage.cs
@@ -164,7 +164,7 @@
                    TextColor = CSS_Color.MainBackgroundColor,
                    TextSize = CSS_FontSize.EmphasisFontSize_FirstLevel,
                    TextAlignment = TextAlignment.CenterLeft,
                    Text = DB_ResidenceData.Instance.CurrentRegion.Name,
                    Text = DB_ResidenceData.Instance.CurrentRegion.homeName,
                    IsBold = true
                };
                topView.AddChidren(btnResidenceName);
HDL_ON/UI/UI2/3-Intelligence/Automation/LogicMethod.cs
@@ -519,7 +519,7 @@
        {
            get
            {
                return Entity.DB_ResidenceData.Instance.CurrentRegion.RegionID;
                return Entity.DB_ResidenceData.Instance.CurrentRegion.id;
            }
        }
        /// <summary>
HDL_ON/UI/UI2/4-PersonalCenter/AddDevice/AddMiniRemoteControlDirection4Page.cs
@@ -350,7 +350,7 @@
        private void RefreshMiniRemoteControlInfo(Action<Entity.Function> successEvent)
        {
            var pra = new Dictionary<string, object>();
            pra.Add("homeId", Entity.DB_ResidenceData.Instance.CurrentRegion.RegionID);
            pra.Add("homeId", Entity.DB_ResidenceData.Instance.CurrentRegion.id);
            pra.Add("spk", Entity.SPK.IrModule);
            var requestJson = DAL.Server.HttpUtil.GetSignRequestJson(pra);
HDL_ON/UI/UI2/4-PersonalCenter/MemberManagement/MemberFunctionPermissionPageBLL.cs
@@ -79,7 +79,7 @@
                    var deleteShareObj = new DeleteShareObj()
                    {
                        shareDatas = funs_Del,
                        homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                        homeId = DB_ResidenceData.Instance.CurrentRegion.id,
                    };
                    LoadMethod_DelSharedData(deleteShareObj);
@@ -101,7 +101,7 @@
                    {
                        shareDatas = funs_NeedAdd,
                        childAccountIds = childAccountIds,
                        homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                        homeId = DB_ResidenceData.Instance.CurrentRegion.id,
                    };
                    result = LoadMethod_AddShareData(addShareObj);
@@ -247,7 +247,7 @@
            var addShareObj = new AddShareObj()
            {
                childAccountIds = childAccountIds,
                homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                homeId = DB_ResidenceData.Instance.CurrentRegion.id,
                shareDatas = roomList
            };
            var responePack = new HttpServerRequest().AddShareData(addShareObj);
@@ -277,7 +277,7 @@
            var deleteShareObj = new DeleteShareObj()
            {
                shareDatas = roomList,
                homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                homeId = DB_ResidenceData.Instance.CurrentRegion.id,
            };
            var responePack = new HttpServerRequest().DeleteShareData(deleteShareObj);
            if (responePack.Code != StateCode.SUCCESS)
HDL_ON/UI/UI2/4-PersonalCenter/MemberManagement/MemberPermissionPageBLL.cs
@@ -176,7 +176,7 @@
                    var deleteShareObj = new DeleteShareObj()
                    {
                        shareDatas = funs_Del,
                        homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                        homeId = DB_ResidenceData.Instance.CurrentRegion.id,
                    };
                    result = LoadMethod_DelSharedData(deleteShareObj);
@@ -251,7 +251,7 @@
            var deleteShareObj = new DeleteShareObj()
            {
                shareDatas = roomList,
                homeId = DB_ResidenceData.Instance.CurrentRegion.RegionID,
                homeId = DB_ResidenceData.Instance.CurrentRegion.id,
            };
            var responePack = new HttpServerRequest().DeleteShareData(deleteShareObj);
            if (responePack.Code != StateCode.SUCCESS)
HDL_ON/UI/UI2/4-PersonalCenter/MyQRCodePage.cs
@@ -144,7 +144,7 @@
                    var resultObj = DAL.Server.HttpUtil.RequestHttpsPost(DAL.Server.NewAPI.API_POST_Gethomepager, requestJson);
                    if (resultObj.Code == DAL.Server.StateCode.SUCCESS)
                    {
                        var homeList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<RegionInfoResNew>>(resultObj.Data.ToString());
                        var homeList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<RegionInfoRes>>(resultObj.Data.ToString());
                        if (homeList == null || homeList.Count == 0)
                        {
                            //如果还没有住宅的话,继续下一次检测
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs
@@ -294,7 +294,7 @@
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.FirstLevelTitleColor,
                TextSize = CSS_FontSize.EmphasisFontSize_FirstLevel,
                Text = DB_ResidenceData.Instance.CurrentRegion.Name,
                Text = DB_ResidenceData.Instance.CurrentRegion.homeName,
                IsBold = true
            };
            residenceInfoView.AddChidren(btnCurResidenceName);
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPageBLL.cs
@@ -139,11 +139,11 @@
                        TextAlignment = TextAlignment.CenterLeft,
                        TextColor = CSS.CSS_Color.FirstLevelTitleColor,
                        SelectedTextColor = CSS.CSS_Color.MainColor,
                        Text = home.Name,
                        TextSize = home.Name.Length > 14 ? CSS.CSS_FontSize.TextFontSize : CSS.CSS_FontSize.SubheadingFontSize,
                        IsSelected = DB_ResidenceData.Instance.CurrentRegion.RegionID == home.RegionID,
                        Text = home.homeName,
                        TextSize = home.homeName.Length > 14 ? CSS.CSS_FontSize.TextFontSize : CSS.CSS_FontSize.SubheadingFontSize,
                        IsSelected = DB_ResidenceData.Instance.CurrentRegion.id == home.id,
                        IsMoreLines = true,
                        Tag = home.RegionID
                        Tag = home.id
                    };
                    contentView.AddChidren(btnHomeName);
@@ -178,13 +178,13 @@
        /// <param name="homeTemp"></param>
        void LoadEvent_ChangeCurHome(RegionInfoRes homeTemp)
        {
            if (DB_ResidenceData.Instance.CurrentRegion.RegionID == homeTemp.RegionID)
            if (DB_ResidenceData.Instance.CurrentRegion.id == homeTemp.id)
            {
                return;
            }
            DB_ResidenceData.Instance.CurrentRegion = homeTemp;
            DB_ResidenceData.Instance.SaveResidenceData();
            btnCurResidenceName.Text = DB_ResidenceData.Instance.CurrentRegion.Name;
            btnCurResidenceName.Text = DB_ResidenceData.Instance.CurrentRegion.homeName;
            DB_ResidenceData.Instance.EixtAccount();
            //刷新住宅数据
            Common.ApiUtlis.Ins.DownloadData();
@@ -200,7 +200,7 @@
                {
                    Action updateResidenceName = () =>
                    {
                        btnCurResidenceName.Text = DB_ResidenceData.Instance.CurrentRegion.Name;
                        btnCurResidenceName.Text = DB_ResidenceData.Instance.CurrentRegion.homeName;
                    };
                    var residentialManagePage = new ResidentialManagePage(updateResidenceName);
                    MainPage.BasePageView.AddChidren(residentialManagePage);
HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs
@@ -33,7 +33,7 @@
        {
            get
            {
                return Entity.DB_ResidenceData.Instance.CurrentRegion.RegionID;
                return Entity.DB_ResidenceData.Instance.CurrentRegion.id;
            }
        }
        /// <summary>
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/AddRoom/RoomBinglingFloorPage.cs
@@ -96,7 +96,7 @@
            {
                try
                {
                    var f = new SpatialInfo("FLOOR") { roomName = floorName, parentId = DB_ResidenceData.Instance.CurrentRegion.RegionID };
                    var f = new SpatialInfo("FLOOR") { roomName = floorName, parentId = DB_ResidenceData.Instance.CurrentRegion.id };
                    var addResult = SpatialInfo.CurrentSpatial.AddFloor(f, out f);
                    if (addResult == DAL.Server.StateCode.SUCCESS)
                    {
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/FloorsManagementPage.cs
@@ -132,7 +132,7 @@
                {
                    try
                    {
                        var f = new SpatialInfo("FLOOR") { roomName = floorName, parentId = DB_ResidenceData.Instance.CurrentRegion.RegionID };
                        var f = new SpatialInfo("FLOOR") { roomName = floorName, parentId = DB_ResidenceData.Instance.CurrentRegion.id };
                        var addResult = SpatialInfo.CurrentSpatial.AddFloor(f, out f);
                        if (addResult == DAL.Server.StateCode.SUCCESS)
                        {
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/ResidentialManagePage.cs
@@ -52,12 +52,12 @@
        /// </summary>
        Button btnRoomManagementTitle;
        #region F3阶段
        /// <summary>
        /// 调试权限开关按钮
        /// </summary>
        //Button btnCommissioningAuthoritySwitchIcon;
        Button btnCommissioningAuthoritySwitchIcon;
        #region F3阶段
        #region 管理员权限迁移
        //FrameLayout administratorPermissionMigrationRow;
        //Button btnAdministratorPermissionMigrationTitle;
@@ -98,11 +98,17 @@
        public void LoadPage()
        {
            bodyView.BackgroundColor = CSS_Color.BackgroundColor;
            new TopViewDiv(bodyView, Language.StringByID(StringId.ResidenceManage)).LoadTopView();
            //new PublicAssmebly().LoadTopView(bodyView, Language.StringByID(StringId.ResidenceManage));
            VerticalScrolViewLayout contentView = new VerticalScrolViewLayout()
            {
                Y = Application.GetRealHeight(64),
                Height = Application.GetRealHeight(667 - 64),
                ScrollEnabled = false,
            };
            bodyView.AddChidren(contentView);
            #region 住宅名称
            FrameLayout residenceNameRow;
@@ -112,7 +118,7 @@
                Height = Application.GetRealHeight(50),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            bodyView.AddChidren(residenceNameRow);
            contentView.AddChidren(residenceNameRow);
            Button btnResidenceNameTitle = new Button()
            {
                X = Application.GetRealWidth(16),
@@ -128,7 +134,7 @@
            {
                X = Application.GetRealWidth(2) + btnResidenceNameTitle.Right,
                Width = Application.GetRealWidth(200),
                Text = DB_ResidenceData.Instance.CurrentRegion.Name,
                Text = DB_ResidenceData.Instance.CurrentRegion.homeName,
                TextSize = CSS_FontSize.TextFontSize,
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.TextualColor,
@@ -162,7 +168,7 @@
                            Height = Application.GetRealHeight(50),
                            BackgroundColor = CSS_Color.MainBackgroundColor,
                        };
                        bodyView.AddChidren(residenceAddressRow);
                        contentView.AddChidren(residenceAddressRow);
                        var btnResidenceAddressTitle = new Button()
                        {
@@ -189,7 +195,7 @@
                        {
                            X = Application.GetRealWidth(2) + btnResidenceNameTitle.Right,
                            Width = Application.GetRealWidth(200),
                            Text = DB_ResidenceData.Instance.CurrentRegion.Address,
                            Text = DB_ResidenceData.Instance.CurrentRegion.homeAddress,
                            TextSize = CSS_FontSize.TextFontSize,
                            TextAlignment = TextAlignment.CenterLeft,
                            TextColor = CSS_Color.TextualColor,
@@ -197,13 +203,14 @@
                        residenceAddressRow.AddChidren(btnResidenceAddress);
            #endregion
            #region 楼层管理
            contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8) });
            floorManagementRow = new FrameLayout()
            {
                Y = Application.GetRealHeight(8) + residenceNameRow.Bottom,// residenceAddressRow.Bottom,
                Height = Application.GetRealHeight(50),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            bodyView.AddChidren(floorManagementRow);
            contentView.AddChidren(floorManagementRow);
            btnFloorManagementTitle = new Button()
            {
@@ -244,7 +251,7 @@
                Height = Application.GetRealHeight(50),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            bodyView.AddChidren(roomManagementRow);
            contentView.AddChidren(roomManagementRow);
            btnRoomManagementTitle = new Button()
            {
@@ -271,13 +278,13 @@
            #region F3阶段
            #region 管理员权限迁移
            //contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8) });
            //administratorPermissionMigrationRow = new FrameLayout()
            //{
            //    Y = Application.GetRealHeight(8) + roomManagementRow.Bottom,
            //    Height = Application.GetRealHeight(65),
            //    BackgroundColor = CSS_Color.MainBackgroundColor,
            //};
            //bodyView.AddChidren(administratorPermissionMigrationRow);
            //contentView.AddChidren(administratorPermissionMigrationRow);
            //btnAdministratorPermissionMigrationTitle = new Button()
            //{
@@ -336,7 +343,7 @@
            //    Height = Application.GetRealHeight(65),
            //    BackgroundColor = CSS_Color.MainBackgroundColor,
            //};
            //bodyView.AddChidren(transferRow);
            //contentView.AddChidren(transferRow);
            //btnTransferTitle = new Button()
            //{
@@ -376,55 +383,66 @@
            #endregion
            #endregion
            #region F3阶段
            #region 调试权限
            //FrameLayout commissioningAuthorityRow;
            //commissioningAuthorityRow = new FrameLayout()
            //{
            //    Y = Application.GetRealHeight(8) + transferRow.Bottom,
            //    Height = Application.GetRealHeight(65),
            //    BackgroundColor = CSS_Color.MainBackgroundColor,
            //};
            //bodyView.AddChidren(commissioningAuthorityRow);
            contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8) });
            FrameLayout commissioningAuthorityRow;
            commissioningAuthorityRow = new FrameLayout()
            {
                Height = Application.GetRealHeight(65),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            contentView.AddChidren(commissioningAuthorityRow);
            //var btnCommissioningAuthorityTitle = new Button()
            //{
            //    X = Application.GetRealWidth(16),
            //    Y = Application.GetRealHeight(10),
            //    Width = Application.GetRealWidth(308),
            //    Height = Application.GetRealHeight(24),
            //    TextID = StringId.CommissioningAuthority,
            //    TextAlignment = TextAlignment.CenterLeft,
            //    TextSize = CSS_FontSize.SubheadingFontSize,
            //    TextColor = CSS_Color.FirstLevelTitleColor,
            //};
            //commissioningAuthorityRow.AddChidren(btnCommissioningAuthorityTitle);
            var btnCommissioningAuthorityTitle = new Button()
            {
                X = Application.GetRealWidth(16),
                Y = Application.GetRealHeight(10),
                Width = Application.GetRealWidth(308),
                Height = Application.GetRealHeight(24),
                TextID = StringId.CommissioningAuthority,
                TextAlignment = TextAlignment.CenterLeft,
                TextSize = CSS_FontSize.SubheadingFontSize,
                TextColor = CSS_Color.FirstLevelTitleColor,
            };
            commissioningAuthorityRow.AddChidren(btnCommissioningAuthorityTitle);
            //var btnCommissioningAuthorityExplan = new Button()
            //{
            //    X = Application.GetRealWidth(16),
            //    Y = btnCommissioningAuthorityTitle.Bottom,
            //    Width = Application.GetRealWidth(308),
            //    Height = Application.GetRealHeight(21),
            //    TextID = StringId.CommissioningAuthorityExPlan,
            //    TextAlignment = TextAlignment.CenterLeft,
            //    TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
            //    TextColor = CSS_Color.PromptingColor1,
            //};
            //commissioningAuthorityRow.AddChidren(btnCommissioningAuthorityExplan);
            var btnCommissioningAuthorityExplan = new Button()
            {
                X = Application.GetRealWidth(16),
                Y = btnCommissioningAuthorityTitle.Bottom,
                Width = Application.GetRealWidth(308),
                Height = Application.GetRealHeight(21),
                TextID = StringId.CommissioningAuthorityExPlan,
                TextAlignment = TextAlignment.CenterLeft,
                TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                TextColor = CSS_Color.PromptingColor1,
            };
            commissioningAuthorityRow.AddChidren(btnCommissioningAuthorityExplan);
            //btnCommissioningAuthoritySwitchIcon = new Button()
            //{
            //    X = Application.GetRealWidth(314),
            //    Gravity = Gravity.CenterVertical,
            //    Width = Application.GetMinRealAverage(48),
            //    Height = Application.GetMinRealAverage(36),
            //    UnSelectedImagePath = "Public/Switch.png",
            //    SelectedImagePath = "Public/SwitchOn.png",
            //};
            //commissioningAuthorityRow.AddChidren(btnCommissioningAuthoritySwitchIcon);
            #endregion
            btnCommissioningAuthoritySwitchIcon = new Button()
            {
                X = Application.GetRealWidth(314),
                Gravity = Gravity.CenterVertical,
                Width = Application.GetMinRealAverage(48),
                Height = Application.GetMinRealAverage(36),
                UnSelectedImagePath = "Public/Switch.png",
                SelectedImagePath = "Public/SwitchOn.png",
                IsSelected = DB_ResidenceData.Instance.CurrentRegion.debugPerm
            };
            commissioningAuthorityRow.AddChidren(btnCommissioningAuthoritySwitchIcon);
            btnCommissioningAuthoritySwitchIcon.MouseUpEventHandler = (sender, e) => {
                DB_ResidenceData.Instance.CurrentRegion.debugPerm = !DB_ResidenceData.Instance.CurrentRegion.debugPerm;
                btnCommissioningAuthoritySwitchIcon.IsSelected = DB_ResidenceData.Instance.CurrentRegion.debugPerm;
                new System.Threading.Thread(() =>
                {
                    new DAL.Server.HttpServerRequest().ChangeResidenceDebugPerm(DB_ResidenceData.Instance.CurrentRegion.debugPerm);
                })
                { IsBackground = true }.Start();
            };
            #endregion
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/ResidentialManagePageBLL.cs
@@ -56,7 +56,7 @@
                                    btnResidenceName.Text = str;
                                    upateResidenceName();
                                });
                                DB_ResidenceData.Instance.CurrentRegion.Name = str;
                                DB_ResidenceData.Instance.CurrentRegion.homeName = str;
                                DB_ResidenceData.Instance.SaveResidenceData();
                            }
                            else
@@ -83,7 +83,7 @@
                    })
                    { IsBackground = true }.Start();
                };
                new PublicAssmebly().LoadDialog_EditParater(StringId.ResidenceName, DB_ResidenceData.Instance.CurrentRegion.Name, callBack,StringId.HouseNameCannotBeEmpty,0,new List<string>());
                new PublicAssmebly().LoadDialog_EditParater(StringId.ResidenceName, DB_ResidenceData.Instance.CurrentRegion.homeName, callBack,StringId.HouseNameCannotBeEmpty,0,new List<string>());
            };
            btnResidenceName.MouseUpEventHandler = eventHandler;
            btnEditResidenceNameIcon.MouseUpEventHandler = eventHandler;
@@ -104,7 +104,7 @@
                    if (responsePack.Code.ToUpper() == StateCode.SUCCESS)
                    {
                        btnResidenceAddress.Text = str;
                        DB_ResidenceData.Instance.CurrentRegion.Address = str;
                        DB_ResidenceData.Instance.CurrentRegion.homeAddress = str;
                        DB_ResidenceData.Instance.SaveResidenceData();
                        //OnAppConfig.Instance.SaveUserConfig();
                    }
@@ -113,7 +113,7 @@
                        IMessageCommon.Current.ShowErrorInfoAlter(responsePack.Code);
                    }
                };
                new PublicAssmebly().LoadDialog_EditParater(StringId.ResidenceAddress, DB_ResidenceData.Instance.CurrentRegion.Name, callBack, StringId.HouseAddressCannotBeEmpty, 0, new List<string>());
                new PublicAssmebly().LoadDialog_EditParater(StringId.ResidenceAddress, DB_ResidenceData.Instance.CurrentRegion.homeName, callBack, StringId.HouseAddressCannotBeEmpty, 0, new List<string>());
            };
            btnResidenceAddress.MouseUpEventHandler = eventHandler;
            btnLocationAddressIcon.MouseUpEventHandler = eventHandler;