JLChen
2020-12-09 e87985ec1dcb69beedaf9f95e8e7aba14b7c08d6
HDL_ON/UI/UI2/4-PersonalCenter/RoomListManage/RoomEditFunctionPage.cs
@@ -52,6 +52,10 @@
        string showedFunctionRoomId = "0";
        List<Function> unallocatedList = new List<Function>();
        List<Function> allocatedList = new List<Function>();
        /// <summary>
        /// 被修改数据的功能列表,在需要保存的时候再保存数据
        /// </summary>
        List<Function> changeList = new List<Function>();
        #endregion
        public RoomEditFunctionPage(Room r)
@@ -142,8 +146,8 @@
            foreach (var function in DB_ResidenceData.functionList.GetAllFunction())
            {
                function.roomIdList.Remove(null);
                if (function.roomIdList.Count > 0 )
                function.roomIds.Remove(null);
                if (function.roomIds.Count > 0 )
                {
                    allocatedList.Add(function);
                }
@@ -161,8 +165,8 @@
                Gravity = Gravity.CenterHorizontal,
                Y = Application.GetRealHeight(582),
                Width = Application.GetRealWidth(220),
                Height = Application.GetRealHeight(44),
                Radius = (uint)Application.GetRealHeight(22),
                Height = Application.GetRealWidth(44),
                Radius = (uint)Application.GetRealWidth(22),
                BackgroundColor = CSS_Color.MainColor,
                TextColor = CSS_Color.MainBackgroundColor,
                TextSize = CSS_FontSize.SubheadingFontSize,
@@ -174,7 +178,6 @@
            LoadEventList();
        }
        /// <summary>
        /// 显示功能Row
@@ -306,7 +309,7 @@
                    var btnFunctionFloorName = new Button()
                    {
                        X = btnFunctionIcon.Right + Application.GetRealWidth(12),
                        Y = Application.GetRealHeight(50),
                        Y = Application.GetRealHeight(30),
                        Width = Application.GetRealWidth(200),
                        Height = Application.GetRealHeight(20),
                        Text = function.GetRoomListName(),
@@ -325,7 +328,7 @@
                    Height = Application.GetRealWidth(28),
                    UnSelectedImagePath = "Public/ChooseIcon.png",
                    SelectedImagePath = "Public/ChooseOnIcon.png",
                    IsSelected = function.roomIdList.Contains(room.sid)
                    IsSelected = function.roomIds.Contains(room.roomId)
                };
                functionRow.AddChidren(btnChooseIcon);
                LoadEvent_ChangeRoomFunctionList(functionRow, btnChooseIcon, function);
@@ -399,7 +402,7 @@
                Height = Application.GetRealWidth(1),
                BackgroundColor = CSS_Color.DividingLineColor,
            });
            foreach (var tempRoom in DB_ResidenceData.rooms)
            foreach (var tempRoom in DB_ResidenceData.residenceData.Rooms)
            {
                Button btnRoom = new Button()
@@ -407,16 +410,16 @@
                    X = Application.GetRealWidth(16),
                    Width = Application.GetRealWidth(128),
                    Height = Application.GetRealHeight(50),
                    Text = tempRoom.name,
                    Text = tempRoom.roomName,
                    TextColor = CSS_Color.FirstLevelTitleColor,
                    SelectedTextColor = CSS_Color.MainColor,
                    TextSize = CSS_FontSize.SubheadingFontSize,
                    TextAlignment = TextAlignment.CenterLeft,
                    IsSelected = showedFunctionRoomId == tempRoom.sid,
                    Tag = tempRoom.sid,
                    IsSelected = showedFunctionRoomId == tempRoom.roomId,
                    Tag = tempRoom.roomId,
                };
                roomListView.AddChidren(btnRoom);
                LoadEvent_ChangeShowedFunctionList(btnRoom, dialog, tempRoom.name);
                LoadEvent_ChangeShowedFunctionList(btnRoom, dialog, tempRoom.roomName);
                roomListView.AddChidren(new Button()
                {