using System.ComponentModel;
using ChuPiao.Common.Enums;
using System;
namespace ChuPiao.Common.Models
{
    /// <summary>
    /// 彩种类别
    /// </summary>
    [Serializable]
    public class M_LotTypeEntity:IComparable
    {
        public M_LotTypeEntity()
        { }
        #region Model
        private int _l_lotid;
        private string _l_lotname = "";
        private string _l_lotshortname = "";
        private bool _l_enabled = true;
        private int _l_ordernum=0;

        /// <summary>
        /// 彩种ID
        /// </summary>
        public int L_LotId
        {
            set
            { 
                _l_lotid = value;
               
            }
            get { return _l_lotid; }
        }
        /// <summary>
        /// 彩种名称
        /// </summary>
        public string L_LotName
        {
            set 
            { 
                _l_lotname = value;
                
            }
            get { return _l_lotname; }
        }
        /// <summary>
        /// 彩种缩写
        /// </summary>
        public string L_LotShortName
        {
            get { return _l_lotshortname; }
            set { _l_lotshortname = value; }
        }

        /// <summary>
        /// 是否有效：1为有效，默认 0为无效
        /// </summary>
        public bool L_Enabled
        {
            get { return _l_enabled; }
            set { _l_enabled = value; }
        }
        /// <summary>
        /// 排序号
        /// </summary>
        public int L_OrderNum
        {
            get { return _l_ordernum; }
            set { _l_ordernum = value; }
        }

        #endregion Model

        #region ICloneable 成员

        public object Clone()
        {
            return this.MemberwiseClone();
        }

        #endregion

        #region 扩展属性
        /// <summary>
        /// 期号
        /// </summary>
        private string _expect;
        public string Expect
        {
            get
            {
                return _expect;
            }
            set
            {
                _expect = value;
            }
        }

        private DateTime _apiendtime;
        /// <summary>
        /// 出票截止时间
        /// </summary>
        public DateTime ApiEndTime
        {
            get { return _apiendtime; }
            set { _apiendtime = value; }
        }
       /// <summary>
       /// 未分配任务数
       /// </summary>
        private int _undivided;
        public int Undivided 
        {
            get 
            {
                return _undivided;
            }
            set 
            {
                _undivided = value;
            }
        }

        private int _unprint;
        /// <summary>
        /// 未出票
        /// </summary>
        public int Unprint
        {
            get { return _unprint; }
            set { _unprint = value; }
        }

        private int _Unnotity;
        /// <summary>
        /// 已出票未通知
        /// </summary>
        public int Unnotity
        {
            get { return _Unnotity; }
            set { _Unnotity = value; }
        }

        
        #endregion
        public override string ToString()
        {
            return L_LotName;
        }

        #region IComparable 成员

        public int CompareTo(object obj)
        {
            return -Undivided.CompareTo(((M_LotTypeEntity)obj).Undivided);
        }

        #endregion
    }
}
