schangxiang@126.com
5 天以前 1b27eddeb3e4c2fd3f59a567b2972aadd6310dc1
Weben_CMSרÓôúÂëÉú³ÉÆ÷/queryExtensions/CmsQueryExtensions/Utils/GetEnumDescriptionUtil.cs
@@ -18,7 +18,7 @@
        public static string GetEnumDescription(Enum enumValue)
        {
            string value = enumValue.ToString();
            if (string.IsNullOrWhiteSpace(value) || value == "0") return "";
            if (string.IsNullOrEmpty(value) || value == "0") return "";
            FieldInfo field = enumValue.GetType().GetField(value);
            object[] objs = field.GetCustomAttributes(typeof(DescriptionAttribute), false);  //获取描述属性
            if (objs == null || objs.Length == 0)  //当描述属性没有时,直接返回名称