using System;

namespace TsSFCDeivceClient.Model.Common
{
    /// <summary>
    /// 下拉框通用对象
    /// </summary>
    public class LookUpItemModel
    {
        public string DisplayMember { get; set; }

        public object ValueMember { get; set; }

        /// <summary>
        /// 整数值
        /// </summary>
        /// <returns></returns>
        public int ValueToInt()
        {
            return Convert.ToInt32(ValueMember);
        }

        /// <summary>
        /// 字符值
        /// </summary>
        /// <returns></returns>
        public string ValueToString()
        {
            return ValueMember.ToString();
        }
    }
}
