using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace FMSAdmin.Entities {
    public partial class BemsReportFormat {

        public BemsReportFormat() {
            BemsReportFormatToFacility = new List<BemsReportFormatToFacility>();
            BemsReportFormatContent = new List<BemsReportFormatContent>();
        }

        [Display(Name = "사이트 ID"), Key]
        public int SiteId { get; set; }

        //리포트 포맷 관리
        [Display(Name = "일지 포맷 ID"), Key]
        public int ReportFormatId { get; set; }

        [Display(Name = "업부 분야 ID"), Required]
        public int? BusinessFieldId { get; set; }

        [Display(Name = "포맷 이름"), Required]
        [StringLength(50)]
        public string FormatName { get; set; }



        [ForeignKey("SiteId")]
        [InverseProperty("BemsReportFormat")]
        public virtual CmSite CmSite { get; set; }

        [ForeignKey("BusinessFieldId")]
        [InverseProperty("BemsReportFormat")]
        public virtual CmBusinessField CmBusinessField { get; set; }


        [InverseProperty("BemsReportFormat")]
        public virtual ICollection<BemsReportHistory> BemsReportHistory { get; set; }


        [InverseProperty("BemsReportFormat")]
        public virtual ICollection<BemsReportFormatToFacility> BemsReportFormatToFacility { get; set; }

        [InverseProperty("BemsReportFormat")]
        public virtual ICollection<BemsReportFormatContent> BemsReportFormatContent { get; set; }
    }
}
