using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using APT.BaseData.Domain.Entities.FM;
using APT.BaseData.Domain.Enums;
using APT.Infrastructure.Core;
using APT.MS.Domain.Entities.BS;
using APT.MS.Domain.Entities.DM;
using APT.MS.Domain.Enums;

namespace APT.MS.Domain.Entities.HM
{
    /// <summary>
    /// 辨识区域
    /// </summary>
    [Description("辨识区域")]
    public partial class T_HM_RISK_AREA : TreeEntityBase<T_HM_RISK_AREA>
    {
        /// <summary>
        /// 编码
        /// </summary>
        [Description("编码")]
        [DataFieldLength(50)]
        public string CODE { get; set; }

        /// <summary>
        /// 区域名称
        /// </summary>
        [Description("区域名称")]
        [DataFieldLength(100)]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        public string NAME { get; set; }
        /// <summary>
        /// 状态
        /// </summary>
        [Description("状态")]
        [FormFieldTable]
        [FormFieldQuery]
        [FormFieldEdit]
        [EnumName("STATUSEnum")]
        public STATUSEnum STATUS { get; set; }

        [Description("部门ID")]
        [DataFieldForeignKey("Nav_Department")]
        public Guid? DEPARTMENT_ID { get; set; }

        [Description("导航：部门")]
        public virtual T_FM_DEPARTMENT Nav_Department { get; set; }

        /// <summary>
        /// 层级
        /// </summary>
        [Description("层级")]
        [EnumName("FMDepartmentType")]
        [FormFieldTable]
        [FormFieldEdit]
        public FMDepartmentType LEVEL { get; set; }

        [Description("导航：人员")]
        [DataFieldIngore]
        public virtual ICollection<T_FM_USER> Nav_User { get; set; }

        [Description("导航：岗位")]
        [DataFieldIngore]
        public List<T_FM_USER_POST> Nav_Post { get; set; }

        [Description("导航：设备设施")]
        [DataFieldIngore]
        public List<T_DM_DEVICE_BASE> Nav_Device { get; set; }

        [Description("导航：风险库")]
        [DataFieldIngore]
        public List<T_HM_EVALUATE_RISK> Nav_Risk { get; set; }
        [Description("导航：隐患上报记录")]
        [DataFieldIngore]
        public List<T_BS_RISK_SUBMIT_CONTENT> Nav_Submit { get; set; }
        [Description("导航：检查记录")]
        [DataFieldIngore]
        public List<T_BS_SAFE_CHECK> Nav_Check { get; set; }
    }
}
