From b8e94316e41eba72d927d5ca7d931b26139ee8ff Mon Sep 17 00:00:00 2001 From: wxr <464027401@qq.com> Date: 星期一, 15 六月 2020 09:12:53 +0800 Subject: [PATCH] 20200612 --- HDL_ON/Entity/DB_ResidenceData.cs | 36 +++++++++++++++++++++++++----------- 1 files changed, 25 insertions(+), 11 deletions(-) diff --git a/HDL_ON/Entity/DB_ResidenceData.cs b/HDL_ON/Entity/DB_ResidenceData.cs index 09efd12..c45cc6d 100644 --- a/HDL_ON/Entity/DB_ResidenceData.cs +++ b/HDL_ON/Entity/DB_ResidenceData.cs @@ -11,24 +11,33 @@ } /// <summary> - /// 褰撳墠閫夋嫨鐨勪綇瀹呯储寮� + /// 0:A鍗忚缃戝叧 + /// 1:bus缃戝叧 + /// 2:knx缃戝叧 /// </summary> - public int CurReginIndex = 0; + public int GatewayType = 0; /// <summary> /// 浣忓畢鍩虹淇℃伅 /// </summary> - public RegionInfoRes residecenInfo { + public RegionInfoRes residecenInfo + { get { - return MainPage.LoginUser.regionList[CurReginIndex]; + return MainPage.LoginUser.regionList.Find((obj) => obj.RegionID == CurReginID); } } /// <summary> + /// 褰撳墠閫夋嫨鐨勪綇瀹呯储寮� + /// </summary> + public string CurReginID = ""; + + + /// <summary> /// 妤煎眰鍒楄〃 /// </summary> - public List<string> floors = new List<string>(); + public List<Floor> floors = new List<Floor>(); /// <summary> /// 鎴块棿鍒楄〃 @@ -132,9 +141,9 @@ if (instance.rooms.Count == 0) { //-------------------- - var r111 = new Room() { sid = "0001", name = "Room-1", floorIndex = 0, backgroundImage = "Classification/Room/Roombg.png" }; + var r111 = new Room() { sid = "0001", name = "Room-1", floorId = "", backgroundImage = "Classification/Room/Roombg.png" }; instance.rooms.Add(r111); - instance.floors.Add("1 F"); + instance.floors.Add(new Floor() { sid = "", name = "1 F" }); instance.functionList.aCs.Add(new AC() { sid = "12341212345678901234560604010001ABCD", @@ -217,8 +226,8 @@ bus_Data = new BusData { SubnetID = 42, - DeviceID = 7, - LoopID = 12, + DeviceID = 17, + LoopID = 1, }, }); instance.functionList.floorHeatings.Add(new FloorHeating() @@ -473,8 +482,13 @@ return instance; } } - - + /// <summary> + /// 閫�鍑鸿处鍙锋竻绌烘暟鎹� + /// </summary> + public void EixtAccount() + { + instance = null; + } /// <summary> /// 浣忓畢鍥剧墖 -- Gitblit v1.8.0