From 52005ed57f3f7bc796fdd1a878e4f298a126f1e8 Mon Sep 17 00:00:00 2001
From: gxc <guoxuecheng@guoxuechengdeMacBook-Pro.local>
Date: 星期二, 29 十月 2019 16:48:47 +0800
Subject: [PATCH] 2019.10.29-3
---
ZigbeeApp/Shared/Common/DeviceUI.cs | 23 +++++++++++++++++++++++
1 files changed, 23 insertions(+), 0 deletions(-)
diff --git a/ZigbeeApp/Shared/Common/DeviceUI.cs b/ZigbeeApp/Shared/Common/DeviceUI.cs
old mode 100755
new mode 100644
index c91f9ec..78b9db5
--- a/ZigbeeApp/Shared/Common/DeviceUI.cs
+++ b/ZigbeeApp/Shared/Common/DeviceUI.cs
@@ -312,5 +312,28 @@
}
#endregion
+
+ #region 鈼� 閫氳繃id鑾峰彇璁惧鍖哄煙_____________
+
+ /// <summary>
+ /// GetZone
+ /// </summary>
+ /// <returns></returns>
+ public string GetZone()
+ {
+ var room = Room.CurrentRoom.GetRoomByDevice(CommonDevice);
+ if (room == null)
+ {
+ return Language.StringByID(R.MyInternationalizationString.UnallocatedArea);
+ }
+ var floorName = Config.Instance.Home.GetFloorNameById(room.FloorId);
+ if (floorName == null)
+ {
+ return room.Name;
+ }
+ return $"{floorName},{room.Name}";
+ }
+
+ #endregion
}
}
--
Gitblit v1.8.0