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

namespace APT.MS.Domain.Entities.SE
{
    /// <summary>
    /// 安全意识调查
    /// </summary>
    [Description("安全意识调查")]
    public class T_SE_SAFE_SURVEY : MesEntityBase
    {
        /// <summary>
        /// 调查名称
        /// </summary>
        [Description("调查名称")]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        [DataFieldLength(300)]
        public string NAME { get; set; }
        /// <summary>
        /// 发起时间
        /// </summary>
        [Description("发起时间")]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        public DateTime? LAUNCH_TIME { get; set; }
        /// <summary>
        /// 发起部门ID
        /// </summary>
        [Description("发起部门")]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        [DataFieldForeignKey("Nav_LaunchDepartment")]
        public Guid? LAUNCH_DEPARTMENT_ID { get; set; }
        /// <summary>
        /// 导航: 发起部门
        /// </summary>
        [Description("导航: 发起部门")]
        public T_FM_DEPARTMENT Nav_LaunchDepartment { get; set; }
        /// <summary>
        /// 发起人员ID
        /// </summary>
        [Description("发起人员")]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        [DataFieldForeignKey("Nav_LaunchUser")]
        public Guid LAUNCH_USER_ID { get; set; }
        /// <summary>
        /// 导航: 发起人员
        /// </summary>
        [Description("导航: 发起人员")]
        public T_FM_USER Nav_LaunchUser { get; set; }
        /// <summary>
        /// 截止时间
        /// </summary>
        [Description("截止时间")]
        [FormFieldTable]
        [FormFieldEdit]
        public DateTime? END_TIME { get; set; }
        /// <summary>
        /// 导航: 参与部门
        /// </summary>
        [Description("参与部门")]
        [FormFieldEdit]
        public ICollection<T_SE_SAFE_SURVEY_LIST_DEPARTMENT> Nav_JoinDepartment { get; set; }
        /// <summary>
        /// 导航: 调查内容
        /// </summary>
        [Description("调查内容")]
        [FormFieldEdit]
        public ICollection<T_SE_SAFE_SURVEY_LIST_POINT> Nav_Points { get; set; }
        /// <summary>
        /// 导航: 试题
        /// </summary>
        [Description("试题")]
        [FormFieldEdit]
        public ICollection<T_SE_SAFE_SURVEY_LIST_PAPER> Nav_Papers { get; set; }
        /// <summary>
        /// 导航: 附件
        /// </summary>
        [Description("附件")]
        public ICollection<T_SE_SAFE_SURVEY_LIST_FILE> Nav_Files { get; set; }
        /// <summary>
        /// 状态
        /// </summary>
        [Description("状态")]
        [EnumName("SESafeSurveyStatus")]
        [FormFieldTable]
        [FormFieldQuery]
        public SESafeSurveyStatus STATUS { get; set; }
        /// <summary>
        /// 公司报表通知
        /// </summary>
        [Description("公司报表通知")]
        [FormFieldEdit]
        public bool COMPNAY_REPORT { get; set; }

        /// <summary>
        /// 任务ID
        /// </summary>
        [Description("任务ID")]
        public Guid? TASK_ID { get; set; }
        /// <summary>
        /// 安全员ID
        /// </summary>
        [Description("安全员ID")]
        public string SAFE_USER_IDS { get; set; }
        [Description("是否发布")]
        [DataFieldIngore]
        public string PUBLISH { get; set; }
        [DataFieldIngore]
        public int IS_OVERTIME { get; set; }

        /// <summary>
        /// 含下级组织成员
        /// </summary>
        [Description("含下级组织成员")]
        [DataFieldIngore]
        public bool IS_DOWN { get; set; }

        /// <summary>
        /// 调查人员
        /// </summary>
        [Description("调查人员")]
        public ICollection<T_SE_SAFE_SURVEY_USER> Nav_ListUsers { get; set; }
    }
}
