wxr
2020-03-13 171bf03f3664226eeff2b20ee9bd2e914b63a17d
HDL_ON/Entity/Function/Curtain/Curtain.cs
@@ -3,14 +3,40 @@
{
    public class Curtain : Function
    {
        /*
        窗帘属性列表:trait: [switch,openLevel,lock]
        属性   描述
        switch   on/off/stop;
        openLevel   0-100;
        lock   boolean (Lock锁定控制)
        */
        public Curtain()
        {
            //functionType = "CurtainModule";
        }
        /// <summary>
        /// 窗帘状态
        /// 0停;1开;2关
        /// </summary>
        public byte state = 0;
        /// <summary>
        /// 获取功能类型
        /// </summary>
        /// <returns></returns>
        protected override string GetFunctionType()
        {
            string type = "Curtain";
            if (PropertyArray.Contains("curtaintype"))
            {
                type = "MotorCurtain";
                if (PropertyArray.Contains("rollingshutter"))
                {
                    type = "RollingShutter";
                }
            }
            return type;
        }
    }
}