wxr
2023-03-21 608b97795c1419b0411b6320126c9681dd4126da
组合调光
2个文件已添加
8个文件已修改
373 ■■■■■ 已修改文件
HDL-ON_Android/Properties/AndroidManifest.xml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/HttpServerRequest.cs 51 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/DAL/Server/NewAPI.cs 44 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/HDL_ON.projitems 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI1-Login/LoginPage.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/CombinedDimming/AddCombineDimmingPage.cs 127 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/CombinedDimming/CombinedDimmingListPage.cs 83 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/CombinedDimming/GroupControl.cs 45 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/ResidentialManagePage.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
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:versionName="1.7" package="com.hdl.onpro" xmlns:tools="http://schemas.android.com/tools" android:versionCode="202303171">
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionName="1.7" package="com.hdl.onpro" xmlns:tools="http://schemas.android.com/tools" android:versionCode="202303172">
    <uses-sdk android:minSdkVersion="26" android:targetSdkVersion="29" />
    <!--友盟-->
    <!--<uses-sdk android:minSdkVersion="8"></uses-sdk>-->
HDL_ON/DAL/Server/HttpServerRequest.cs
@@ -3133,7 +3133,7 @@
#region 光伏储能
        #region 光伏储能
        /// <summary>
        /// 获取住宅下逆变器列表
        /// </summary>
@@ -3158,7 +3158,54 @@
            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetInverter_StatisticsInfo, requestJson);
            return pack;
        }
#endregion
        #endregion
        #region 群控,组合调光
        /// <summary>
        /// 获取群控类型
        /// </summary>
        /// <param name="spk"></param>
        /// <returns></returns>
        public ResponsePackNew GetGroupControlTypes(string spk)
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            d.Add("spk", spk);
            var requestJson = HttpUtil.GetSignRequestJson(d);
            var pack = HttpUtil.RequestHttpsPostFroHome(NewAPI.Api_Post_GetGroupControlTypes, requestJson);
            return pack;
        }
        /// <summary>
        /// 获取群控列表
        /// </summary>
        /// <param name="spk"></param>
        /// <returns></returns>
        public ResponsePackNew GetGroupControlList()
        {
            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_GetGroupControlListByHome, requestJson);
            return pack;
        }
        /// <summary>
        /// 添加群控列表
        /// </summary>
        /// <param name="spk"></param>
        /// <returns></returns>
        public ResponsePackNew AddGroupControl()
        {
            Dictionary<string, object> d = new Dictionary<string, object>();
            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_GetGroupControlListByHome, requestJson);
            return pack;
        }
        #endregion
    }
}
HDL_ON/DAL/Server/NewAPI.cs
@@ -867,6 +867,50 @@
        public const string Api_Post_GetInverter_StatisticsInfo = "/home-wisdom/app/device/inverter/allInfo";
        #endregion
        #region 群控,组合调光
        /// <summary>
        /// 获取群控类型
        /// </summary>
        public const string Api_Post_GetGroupControlTypes = "/home-wisdom/app/device/groupcontrol/types";
        /// <summary>
        /// 获取群控列表
        /// </summary>
        public const string Api_Post_GetGroupControlListByHome = "/home-wisdom/app/device/groupcontrol/list";
        /// <summary>
        /// 获取群控详情
        /// </summary>
        public const string Api_Post_GetGroupControlInfos = "/home-wisdom/app/device/groupcontrol/infos";
        /// <summary>
        /// 添加群控
        /// </summary>
        public const string Api_Post_AddGroupControl = "/home-wisdom/app/device/groupcontrol/add";
        /// <summary>
        /// 更新群控
        /// </summary>
        public const string Api_Post_UpdateGroupControl = "/home-wisdom/app/device/groupcontrol/update";
        /// <summary>
        /// 删除群控
        /// </summary>
        public const string Api_Post_DeleteGroupControl = "/home-wisdom/app/device/groupcontrol/deleted";
        /// <summary>
        /// 收藏群控
        /// </summary>
        public const string Api_Post_CollectGroupControl = "/home-wisdom/app/device/groupcontrol/collect";
        /// <summary>
        /// 取消收藏群控
        /// </summary>
        public const string Api_Post_CancelCollectGroupControl = "/home-wisdom/app/device/groupcontrol/cancelCollect";
        /// <summary>
        /// 控制群控
        /// </summary>
        public const string Api_Post_ControlGroupControl = "/home-wisdom/app/device/groupcontrol/controlDown";
        /// <summary>
        /// 群控状态刷新
        /// </summary>
        public const string Api_Post_ReadGroupControlStatus = "/home-wisdom/app/device/groupcontrol/statusRefresh";
        #endregion
    }
    ///// <summary>
HDL_ON/HDL_ON.projitems
@@ -533,6 +533,8 @@
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\RoomListManage\DeliveryQrCodePage.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\MemberManagement\MemberFaceManagementPage.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\CombinedDimming\CombinedDimmingListPage.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\CombinedDimming\GroupControl.cs" />
    <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\CombinedDimming\AddCombineDimmingPage.cs" />
  </ItemGroup>
  <ItemGroup>
    <Folder Include="$(MSBuildThisFileDirectory)Entity\Device\" />
HDL_ON/UI/UI1-Login/LoginPage.cs
@@ -230,11 +230,11 @@
                    //etAccount.Text = "18244942707";
                    //etAccount.Text = "12345678904";
                    //etAccount.Text = "13418062953";
                    //etAccount.Text = "13138683659";
                    etAccount.Text = "13138683659";
                    //etAccount.Text = "15217626103";
                    //etAccount.Text = "18100573477";
                    //etAccount.Text = "18321091245";
                    etAccount.Text = "13751916353";
                    //etAccount.Text = "13751916353";
                }
                else
                {
HDL_ON/UI/UI2/4-PersonalCenter/CombinedDimming/AddCombineDimmingPage.cs
New file
@@ -0,0 +1,127 @@
using System;
using Shared;
using HDL_ON.Entity;
using HDL_ON.UI.CSS;
namespace HDL_ON.UI
{
    public class AddCombineDimmingPage : FrameLayout
    {
        FrameLayout bodyView;
        public AddCombineDimmingPage()
        {
            bodyView = this;
        }
        public void LoadPage()
        {
            new TopViewDiv(bodyView, Language.StringByID(StringId.CombinedDimming)).LoadTopView();
            var contentView = new FrameLayout()
            {
                Y = Application.GetRealHeight(64),
                BackgroundColor = CSS_Color.MainBackgroundColor,
                Height = Application.GetRealHeight(550),
            };
            bodyView.AddChidren(contentView);
            #region 住宅名称
            FrameLayout residenceNameRow;
            residenceNameRow = new FrameLayout()
            {
                Y = Application.GetRealHeight(72),
                Height = Application.GetRealHeight(50),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            contentView.AddChidren(residenceNameRow);
            Button btnResidenceNameTitle = new Button()
            {
                X = Application.GetRealWidth(16),
                Width = Application.GetRealWidth(78),
                TextID = StringId.ResidenceName,
                TextAlignment = TextAlignment.CenterLeft,
                TextSize = CSS_FontSize.SubheadingFontSize,
                TextColor = CSS_Color.FirstLevelTitleColor,
            };
            residenceNameRow.AddChidren(btnResidenceNameTitle);
            var btnResidenceName = new Button()
            {
                X = Application.GetRealWidth(2) + btnResidenceNameTitle.Right,
                Width = Application.GetRealWidth(200),
                Text = DB_ResidenceData.Instance.CurrentRegion.homeName,
                TextSize = CSS_FontSize.TextFontSize,
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.TextualColor,
            };
            residenceNameRow.AddChidren(btnResidenceName);
            var btnEditResidenceNameIcon = new Button()
            {
                X = Application.GetRealWidth(333),
                Gravity = Gravity.CenterVertical,
                Width = Application.GetMinRealAverage(28),
                Height = Application.GetMinRealAverage(28),
                UnSelectedImagePath = "Public/Edit.png",
            };
            residenceNameRow.AddChidren(btnEditResidenceNameIcon);
            #endregion
            residenceNameRow.AddChidren(
                new Button()
                {
                    Gravity = Gravity.CenterHorizontal,
                    Y = Application.GetRealHeight(49),
                    Height = Application.GetRealHeight(1),
                    Width = Application.GetRealWidth(343),
                    BackgroundColor = CSS_Color.DividingLineColor,
                });
            #region 住宅地址
            var residenceAddressRow = new FrameLayout()
            {
                Y = residenceNameRow.Bottom,
                Height = Application.GetRealHeight(50),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            contentView.AddChidren(residenceAddressRow);
            var btnResidenceAddressTitle = new Button()
            {
                X = Application.GetRealWidth(16),
                Width = Application.GetRealWidth(78),
                TextID = StringId.ResidenceAddress,
                TextAlignment = TextAlignment.CenterLeft,
                TextSize = CSS_FontSize.SubheadingFontSize,
                TextColor = CSS_Color.FirstLevelTitleColor,
            };
            residenceAddressRow.AddChidren(btnResidenceAddressTitle);
            var btnLocationAddressIcon = new Button()
            {
                X = Application.GetRealWidth(333),
                Gravity = Gravity.CenterVertical,
                Width = Application.GetMinRealAverage(28),
                Height = Application.GetMinRealAverage(28),
                //UnSelectedImagePath = "Public/LocationAddressIcon.png",
                UnSelectedImagePath = "Public/Edit.png",
            };
            residenceAddressRow.AddChidren(btnLocationAddressIcon);
            var btnResidenceAddress = new Button()
            {
                X = Application.GetRealWidth(2) + btnResidenceNameTitle.Right,
                Width = Application.GetRealWidth(200),
                Text = DB_ResidenceData.Instance.CurrentRegion.homeAddress,
                TextSize = CSS_FontSize.TextFontSize,
                TextAlignment = TextAlignment.CenterLeft,
                TextColor = CSS_Color.TextualColor,
            };
            residenceAddressRow.AddChidren(btnResidenceAddress);
            #endregion
            contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8) });
        }
    }
}
HDL_ON/UI/UI2/4-PersonalCenter/CombinedDimming/CombinedDimmingListPage.cs
@@ -1,4 +1,7 @@
using System;
using HDL_ON.DAL.Server;
using HDL_ON.Entity;
using HDL_ON.UI.CSS;
using Shared;
namespace HDL_ON.UI
@@ -15,11 +18,89 @@
        public void LoadPage()
        {
            new TopViewDiv(bodyView, Language.StringByID(StringId.MemberManagement)).LoadTopView_AddIcon("CombinedDimming",
            new TopViewDiv(bodyView, Language.StringByID(StringId.CombinedDimming)).LoadTopView_AddIcon("CombinedDimming",
                (s,c)=>{
                });
            var contentView = new VerticalScrolViewLayout()
            {
                Y = Application.GetRealHeight(64),
                Height = Application.GetRealHeight(550),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            bodyView.AddChidren(contentView);
            new System.Threading.Thread(() => {
                var http = new HttpServerRequest();
                var pack = http.GetGroupControlList();
                if(pack != null)
                {
                    if(pack.Code == StateCode.SUCCESS)
                    {
                        var data = Newtonsoft.Json.JsonConvert.DeserializeObject<GroupControl>(pack.Data.ToString());
                    }
                }
            }) { IsBackground = true }.Start();
            #region
            contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8) });
            var row = new FrameLayout()
            {
                Height = Application.GetRealHeight(65),
                BackgroundColor = CSS_Color.MainBackgroundColor,
            };
            var btnTitle = new Button()
            {
                X = Application.GetRealWidth(16),
                Y = Application.GetRealHeight(10),
                Width = Application.GetRealWidth(308),
                Height = Application.GetRealHeight(24),
                TextID = StringId.AdministratorPermissionMigration,
                TextAlignment = TextAlignment.CenterLeft,
                TextSize = CSS_FontSize.SubheadingFontSize,
                TextColor = CSS_Color.FirstLevelTitleColor,
            };
            row.AddChidren(btnTitle);
            var btnAdministratorPermissionMigrationExplan = new Button()
            {
                X = Application.GetRealWidth(16),
                Y = btnTitle.Bottom,
                Width = Application.GetRealWidth(308),
                Height = Application.GetRealHeight(21),
                TextID = StringId.AdministratorPermissionMigrationExPlan,
                TextAlignment = TextAlignment.CenterLeft,
                TextSize = CSS_FontSize.PromptFontSize_FirstLevel,
                TextColor = CSS_Color.PromptingColor1,
            };
            row.AddChidren(btnAdministratorPermissionMigrationExplan);
            var btnAdministratorPermissionMigrationSkinIcon = new Button()
            {
                X = Application.GetRealWidth(343),
                Gravity = Gravity.CenterVertical,
                Width = Application.GetMinRealAverage(16),
                Height = Application.GetMinRealAverage(16),
                UnSelectedImagePath = "Public/RightIcon.png",
            };
            row.AddChidren(btnAdministratorPermissionMigrationSkinIcon);
            row.AddChidren(
                new Button()
                {
                    Gravity = Gravity.CenterHorizontal,
                    Y = Application.GetRealHeight(64),
                    Height = Application.GetRealHeight(1),
                    Width = Application.GetRealWidth(343),
                    BackgroundColor = CSS_Color.DividingLineColor,
                });
            #endregion
        }
    }
}
HDL_ON/UI/UI2/4-PersonalCenter/CombinedDimming/GroupControl.cs
New file
@@ -0,0 +1,45 @@
using System;
using System.Collections.Generic;
namespace HDL_ON.Entity
{
    public class GroupControl
    {
        public GroupControl()
        {
        }
        /// <summary>
        /// 群控sid
        /// </summary>
        public string sid = string.Empty;
        /// <summary>
        /// 群控名称
        /// </summary>
        public string name = string.Empty;
        /// <summary>
        /// 群控类型
        /// </summary>
        public string type = string.Empty;
        /// <summary>
        /// 房间uid
        /// </summary>
        public List<String> uids = new List<string>();
        /// <summary>
        /// 群控功能sid配置
        /// </summary>
        public List<GroupControlFunction> sids = new List<GroupControlFunction>();
    }
    public class GroupControlFunction
    {
        /// <summary>
        /// 功能sid
        /// </summary>
        public string sid = string.Empty;
        /// <summary>
        /// 功能spk
        /// </summary>
        public string spk = string.Empty;
    }
}
HDL_ON/UI/UI2/4-PersonalCenter/PersonalCenterPage.cs
@@ -585,7 +585,7 @@
                    #endregion
                    residenceFunctionCount++;
                    #region ---人脸管理
                    #region ---组合调光
                    var faceManagementView = new FrameLayout()
                    {
                        X = Application.GetRealWidth(28 - 24),
@@ -608,7 +608,7 @@
                    {
                        Y = btnResidenceManageIcon.Bottom,
                        Height = Application.GetRealHeight(29),
                        TextID = StringId.FaceManagemant,
                        TextID = StringId.CombinedDimming,
                        TextAlignment = TextAlignment.Center,
                        TextColor = CSS_Color.FirstLevelTitleColor,
                        TextSize = CSS_FontSize.PromptFontSize_FirstLevel
@@ -617,9 +617,14 @@
                    #endregion
                    EventHandler<MouseEventArgs> eventHandler = (sender, e) => {
                        var page = new CombinedDimmingListPage();
                        MainPage.BasePageView.AddChidren(page);
                        page.LoadPage();
                        MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
                    };
                    faceManagementView.MouseUpEventHandler = eventHandler;
                    btnFaceManagementText.MouseUpEventHandler = eventHandler;
                    btnFaceManagementIcon.MouseUpEventHandler = eventHandler;
                }
            }
            else
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/ResidentialManagePage.cs
@@ -202,9 +202,9 @@
            };
            residenceAddressRow.AddChidren(btnResidenceAddress);
            #endregion
            #region 楼层管理
            contentView.AddChidren(new Button() { Height = Application.GetRealHeight(8) });
            #region 楼层管理
            floorManagementRow = new FrameLayout()
            {
                Height = Application.GetRealHeight(50),