wxr
2023-06-06 592974441a4df95fffd9167c90192da1a390b1c2
HDL_ON/DAL/Server/HttpServerRequest.cs
@@ -697,6 +697,34 @@
            }
        }
        /// <summary>
        /// 获取住宅交付链接
        /// </summary>
        /// <returns></returns>
        public ResponsePackNew GetHouseDeliveryUrl()
        {
            var d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            var jsonString = HttpUtil.GetSignRequestJson(d);
            var revertObj = HttpUtil.RequestHttpsPostFroHome(NewAPI.APi_Post_GetHoserDeliverUrl, jsonString);
            return revertObj;
        }
        /// <summary>
        /// 住宅交付回滚
        /// </summary>
        /// <returns></returns>
        public ResponsePackNew RollBack()
        {
            var d = new Dictionary<string, object>();
            d.Add("houseId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("communityId", DB_ResidenceData.Instance.CurrentRegion.communityId);
            d.Add("flowRecordContent", "onPro交付回滚");
            d.Add("projectFlowRecordActionEnum", "DELIVERY_ROLLBACK");
            var jsonString = HttpUtil.GetSignRequestJson(d);
            var revertObj = HttpUtil.RequestHttpsPostFroHome(NewAPI.APi_Post_UpdateProjectDebugStatus, jsonString);
            return revertObj;
        }
        /// <summary>
        /// 获取网关信息
        /// </summary>
        public string GetGatewayInfo()
@@ -1042,6 +1070,22 @@
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_Child_UpdateFace, requestJson);
        }
        /// <summary>
        /// 家庭成员绑定账号
        /// </summary>
        /// <param name="childId"></param>
        /// <param name="faceUrl"></param>
        /// <returns></returns>
        public ResponsePackNew SubChildBindAccount(string childId, string account)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("childId", childId);
            d.Add("account", account);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.API_POST_Child_BindAccount, requestJson);
        }
        /// <summary>
        /// 修改住宅调试权限
@@ -1465,6 +1509,8 @@
        /// </summary>
        public void GetCityWeatherInfo(string lon, string lat)
        {
            if (lon == "0" || lat == "0")
                return;
            MainPage.cityInfo.lon = lon;
            MainPage.cityInfo.lat = lat;
@@ -1510,6 +1556,7 @@
                            MainPage.cityInfo.lowestTemperature = jt.GetValue("lowestTemperature").ToString();
                            MainPage.cityInfo.highestTemperature = jt.GetValue("highestTemperature").ToString();
                            MainPage.CityWeatherAction?.Invoke();
                            HDL_ON.UI.HomePage.LoadEvent_RefreshAir();
                            break;
                        }
                        catch (Exception ex)
@@ -1517,16 +1564,8 @@
                            MainPage.Log($"get weather error : {ex.Message}");
                        }
                    }
                    System.Threading.Thread.Sleep(1000);
                    System.Threading.Thread.Sleep(5000);
                }
                Shared.Application.RunOnMainThread(() =>
                {
                    try
                    {
                        HDL_ON.UI.HomePage.LoadEvent_RefreshAir();
                    }
                    catch { }
                });
            });
        }
        ///// <summary>
@@ -3012,8 +3051,49 @@
            //IMessageCommon.Current.ShowErrorInfoAlter(responePack.Code);
            return listSortLog;
        }
        /// <summary>
        /// 获取门锁临时密码
        /// </summary>
        /// <param name="deviceId"></param>
        /// <returns></returns>
        public ResponsePackNew GetDoorTempPassword(string deviceId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId", deviceId);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetTempPasswrod, requestJson);
        }
        /// <summary>
        /// 创建门锁临时密码
        /// </summary>
        /// <param name="deviceId"></param>
        /// <returns></returns>
        public ResponsePackNew CreateDoorTempPassword(string deviceId,string beginTime,string endTime)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId", deviceId);
            d.Add("beginTime", beginTime);
            d.Add("endTime", endTime);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_CreateTempPasswrod, requestJson);
        }
        /// <summary>
        /// 删除门锁临时密码
        /// </summary>
        /// <returns></returns>
        public ResponsePackNew DelDoorTempPassword(string deviceId, string pwdId)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("homeId", DB_ResidenceData.Instance.CurrentRegion.id);
            d.Add("deviceId", deviceId);
            d.Add("pwdId", pwdId);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            return HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_DelTempPasswrod, requestJson);
        }
#endregion
        #endregion
        #region ■ 音箱语言控制相关_________________________
        /// <summary>