gxc
2020-02-28 66a9965c44ecc32a6696abca876ab9d1cd091584
ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs
old mode 100755 new mode 100644
@@ -19,13 +19,15 @@
        /// <param name="flage">If set to <c>true</c> flage.</param>
        public static void DebugPrintLog(string msg, bool flage = true)
        {
#if DEBUG
            if (flage == true)
            {
                //if (msg.Contains("DeviceStatusReport") == false)
                //{
                System.Console.WriteLine(msg);
                //if (msg.Contains("DeviceStatusReport") == false)
                //{
                System.Console.WriteLine(msg + "  " + System.DateTime.Now.ToLongTimeString() + " " + System.DateTime.Now.Millisecond);
                //}
            }
#endif
        }
        /// <summary>
@@ -212,12 +214,12 @@
                else if (this.Type == DeviceType.ColorDimmableLight)
                {
                    //彩灯
                    IconPath = "Device/ColorDimmableLight.png";
                    IconPath = "Device/ColorLight.png";
                }
                else if (this.Type == DeviceType.DimmableLight)
                {
                    //调光器
                    IconPath = "Device/ColorDimmableLight.png";
                    IconPath = "Device/Light.png";
                }
                else if (this.Type == DeviceType.OnOffOutput)
                {
@@ -247,7 +249,7 @@
                    //其他的图标有点特殊
                    string unSelectPic = string.Empty;
                    string selectPic = string.Empty;
                    Shared.Common.LocalDevice.Current.GetDeviceBeloneIcon(new List<CommonDevice> { this }, ref unSelectPic, ref selectPic);
                    Shared.Common.LocalDevice.Current.GetDeviceObjectIcon(new List<CommonDevice> { this }, ref unSelectPic, ref selectPic);
                    IconPath = unSelectPic;
                }
                Shared.Common.Global.WriteFileByBytesByHomeId(FilePath, System.Text.Encoding.UTF8.GetBytes(Newtonsoft.Json.JsonConvert.SerializeObject(this)));
@@ -293,9 +295,9 @@
        /// </summary>
        public DeviceType Type = DeviceType.UnKown;
        /// <summary>
        /// 设备的功能类型(此类型目前只针对继电器回路有效,默认为灯光)
        /// 设备的功能类型(此类型目前只针对继电器回路有效,默认未指定)
        /// </summary>
        public DeviceFunctionType DfunctionType = DeviceFunctionType.A灯光;
        public DeviceFunctionType DfunctionType = DeviceFunctionType.A未定义;
        /// <summary>
        /// MAC地址
        /// </summary>
@@ -416,10 +418,6 @@
        /// 序列号
        /// </summary>
        public string SerialNumber = string.Empty;
        /// <summary>
        /// 整个设备所属的区域ID(因为设备也能够分配区域了)
        /// </summary>
        public string DeviceRoomId = string.Empty;
        /// <summary>
        /// 所有指定cluster是否都已经成功绑定协调器
        ///<para>0:未完全绑定</para>
@@ -1005,7 +1003,7 @@
            /// <summary>
            /// 设备所在网关的网关id
            /// </summary>
            public int GwId;
            public string GwId;
            /// <summary>
            /// 设备名
            /// </summary>