using APT.BaseData.Domain.Entities.FM;
using APT.BaseData.Domain.Enums;
using APT.Infrastructure.Core;
using APT.MS.Domain.Enums;
using System;
using System.Collections.Generic;
using System.ComponentModel;

namespace APT.MS.Domain.Entities.OG
{
    /// <summary>
    /// 人员任命书
    /// </summary>
    [Description("人员任命书")]
    public class T_OG_POLICY_DOCUMENT : MesEntityBase
    {
        /// <summary>
        /// 文件编号
        /// </summary>
        [Description("文件编号")]
        public string CODE { get; set; }
        /// <summary>
        /// 文件名称
        /// </summary>
        [Description("文件名称")]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        public string NAME { get; set; }
        /// <summary>
        /// 人员任命书-人员类别
        /// </summary>
        [Description("人员任命书-人员类别")]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        [DataFieldForeignKey("Nav_AppointType")]
        public Guid? APPOINT_TYPE { get; set; }
        /// <summary>
        /// 导航:人员任命书-人员类别
        /// </summary>
        [Description("导航:人员任命书-人员类别")]
        public T_OG_PERSONNEL_TYPE_ENUM Nav_AppointType { get; set; }
        /// <summary>
        /// 版本号
        /// </summary>
        [Description("版本号")]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        public int VERSION { get; set; }
        /// <summary>
        /// 子表
        /// </summary>
        [Description("子表")]
        [FormFieldEdit]
        public List<T_OG_POLICY_DOCUMENT_DETAIL> Nav_Details { get; set; }
        /// <summary>
        /// 被任命人员
        /// </summary>
        [Description("被任命人员")]
        public List<T_OG_POLICY_DOCUMENT_DETAIL_APPOINT_USER> Nav_AppointUsers { get; set; }
        /// <summary>
        /// 编制单位
        /// </summary>
        [Description("编制单位")]
        [FormFieldEdit]
        [DataFieldForeignKey("Nav_Department")]
        public Guid DEPARTMENT_ID { get; set; }
        /// <summary>
        /// 编制单位
        /// </summary>
        [Description("编制单位")]
        public T_FM_DEPARTMENT Nav_Department { get; set; }
          /// <summary>
        /// 批准人员
        /// </summary>
        [Description("批准人员")]
        [FormFieldEdit]
        [DataFieldForeignKey("Nav_AppointAgreeUser")]
        public Guid? APPOINT_AGREEUSER_ID { get; set; }
        /// <summary>
        /// 导航属性: 批准人员
        /// </summary>
        [Description("导航属性: 批准人员")]
        public T_FM_USER Nav_AppointAgreeUser { get; set; }
        /// <summary>
        /// 颁布时间
        /// </summary>
        [Description("颁布时间")]
        [FormFieldEdit]
        public DateTime? PUBLISH_TIME { get; set; }
        /// <summary>
        /// 生效时间
        /// </summary>
        [Description("生效时间")]
        [FormFieldEdit]
        public DateTime? APPOINT_EFFECT_TIME { get; set; }
        /// <summary>
        /// 人员任命增加/删除原因
        /// </summary>
        [Description("人员任命增加/删除原因")]
        [EnumName("OGAppointmentAddDelReason")]
        [FormFieldEdit]
        public OGAppointmentAddDelReason APPOINT_REASON { get; set; }
        /// <summary>
        /// 状态 (0:作废 ,1:有效)
        /// </summary>
        [Description("状态")]
        [EnumName("HMOperationStepEnum")]
        public HMOperationStepEnum STATUS { get; set; }
        /// <summary>
        /// 附件
        /// </summary>
        [Description("附件")]
        public List<T_OG_POLICY_DOCUMENT_DETAIL_FILE> Nav_Files { get; set; }
        /// <summary>
        ///上传人员
        /// </summary>
        [Description("上传人员")]
        [DataFieldForeignKey("Nav_User")]
        public Guid USER_ID { get; set; }
        /// <summary>
        /// 上传人员
        /// </summary>
        [Description("上传人员")]
        public T_FM_USER Nav_User { get; set; }
        [DataFieldIngore]
        public int IS_OVERTIME { get; set; }
    }
}