From d8545fbd1b36a6766c57c987e5d89862b470fed9 Mon Sep 17 00:00:00 2001 From: JLChen <551775569@qq.com> Date: 星期四, 03 九月 2020 09:46:29 +0800 Subject: [PATCH] 2020-09-03 1.修改风扇默认为关状态。2.Alexa添加设备时,去掉空调和通用开关选择添加支持。 3.场景增加通用开关添加和发送控制支持,Alexa 的场景同样增加通用开关的支持。 --- Crabtree/SmartHome/HDL/Operation/ResponseEntity/RegionInfoRes.cs | 100 +++++++++++++++++++++++++++++++++++++++++++++++--- 1 files changed, 94 insertions(+), 6 deletions(-) diff --git a/Crabtree/SmartHome/HDL/Operation/ResponseEntity/RegionInfoRes.cs b/Crabtree/SmartHome/HDL/Operation/ResponseEntity/RegionInfoRes.cs old mode 100755 new mode 100644 index 5005184..b31d6a1 --- a/Crabtree/SmartHome/HDL/Operation/ResponseEntity/RegionInfoRes.cs +++ b/Crabtree/SmartHome/HDL/Operation/ResponseEntity/RegionInfoRes.cs @@ -1,15 +1,103 @@ 锘縰sing System; - +using System.Collections.Generic; namespace Shared -{ +{ + [Serializable] + public class RegionInfoRes + { + /// <summary> + /// 淇鏃PP鏁版嵁涓㈠け 鍏煎鎭㈠ + /// </summary> + public int RegionID + { + set + { + if (value != 0) + Id = value.ToString(); + } + } + + public string RegionName + { + set + { + if (!string.IsNullOrEmpty(value)) + Name = value; + } + } + + public string MAC + { + set + { + if (!string.IsNullOrEmpty(value)) + { + if (HomeGateways != null && HomeGateways.Count > 0) + { + HomeGateways[0].GatewayUniqueId = value; + } + else + { + var mHomeGateways = new HomeGateways() { GatewayUniqueId = value }; + var mList = new List<HomeGateways>(); + mList.Add(mHomeGateways); + HomeGateways = mList; + } + } + } + } + + + public string Id { get; set; } + + public string Name { get; set; } + + //public string MAC { get; set; } + public List<HomeGateways> HomeGateways = new List<HomeGateways> (); + + /// <summary> + /// 鏄惁涓哄叾浠栦富鐢ㄦ埛鍒嗕韩杩囨潵鐨勪綇瀹� + /// </summary> + public bool IsOthreShare { get; set; } + /// <summary> + /// 褰撳墠浣忓畢鏄叾浠栦富甯愬彿鍒嗕韩杩囨潵鐨勪富甯愬彿鐨勫垎甯冨紡Id + /// </summary> + public string MainUserDistributedMark { get; set; } + /// <summary> + /// 浠呭瓙璐﹀彿鐧婚檰鐨勬椂鍊欎娇鐢�,褰撱�怚sOthreShare銆戜负"true"锛屽苟涓斻�怉ccountType銆戜负"1"鏃讹紝璇ヨ处鍙锋嫢鏈夌鐞嗗憳鏉冮檺 + /// </summary> + public int AccountType { get; set; } + /// <summary> + /// 缁忓害 + /// </summary> + public double Longitude = 0; + /// <summary> + /// 绾害 + /// </summary> + public double Latitude = 0; + + } + [Serializable] - public class RegionInfoRes + public class HomeGateways { + public string GatewayUniqueId { get; set; } + + } + + + [Serializable] + public class ResidenceRes { - public int RegionID { get; set; } + public int PageIndex; + public int PageSize; + public int TotalCount; + public int TotalPages; + public bool HasPreviousPage; + public bool HasNextPage; + public string RegionName; - public string RegionName { get; set; } + public List<RegionInfoRes> PageData = new List<RegionInfoRes> (); - public string MAC; } } -- Gitblit v1.8.0