using Microsoft.EntityFrameworkCore; using System.ComponentModel.DataAnnotations.Schema; using System.ComponentModel.DataAnnotations; using BMA.EHR.Recurit.Exam.Service.Models.Disables; using BMA.EHR.Recurit.Exam.Service.Models.Documents; namespace BMA.EHR.Recurit.Exam.Service.Models { public class PeriodExam : EntityBase { [Required, MaxLength(150), Column(Order = 8), Comment("ชื่อการสอบ")] public string Name { get; set; } = string.Empty; [Required, Comment("ตรวจสอบเอกสารหลังประกาศผลสอบ")] public bool CheckDocument { get; set; } = false; [Required, Comment("คนพิการ")] public bool CheckDisability { get; set; } = false; [Column(Order = 9), Comment("รอบการสอบ")] public int? Round { get; set; } [Comment("ปีงบประมาณ")] public int? Year { get; set; } [Comment("ค่าธรรมเนียม")] public float? Fee { get; set; } = 0; [Column(Order = 1), Comment("วันเริ่มสมัครสอบ")] public DateTime? RegisterStartDate { get; set; } [Column(Order = 2), Comment("วันสิ้นสุดสมัครสอบ")] public DateTime? RegisterEndDate { get; set; } [Column(Order = 3), Comment("วันเริ่มชำระเงิน")] public DateTime? PaymentStartDate { get; set; } [Column(Order = 4), Comment("วันสิ้นสุดชำระเงิน")] public DateTime? PaymentEndDate { get; set; } [Column(Order = 5), Comment("วันประกาศผลสอบ")] public DateTime? AnnouncementDate { get; set; } [Required, Column(Order = 6), Comment("วันเริ่มประกาศ")] public DateTime AnnouncementStartDate { get; set; } = DateTime.Now.Date; [Required, Column(Order = 7), Comment("วันสิ้นสุดประกาศ")] public DateTime AnnouncementEndDate { get; set; } = DateTime.Now.Date; [Comment("วันที่สอบ")] public DateTime? ExamDate { get; set; } [Comment("Id รหัสส่วนราชการ")] public Guid? OrganizationCodeId { get; set; } [Comment("ชื่อรหัสส่วนราชการ")] public string? OrganizationCodeName { get; set; } [Comment("Id หน่วยงาน")] public Guid? OrganizationId { get; set; } [Comment("ชื่อหน่วยงาน")] public string? OrganizationName { get; set; } [Comment("ชำระเงินผ่านกรุงไทย")] public string? PaymentKrungThai { get; set; } [Comment("รายละเอียดสมัครสอบ")] public string? Detail { get; set; } [Comment("รายละเอียดเงื่อนไขการสมัคร")] public string? EditorCondition { get; set; } [Comment("รายละเอียดคำรับรอง")] public string? EditorConfirm { get; set; } [Comment("หมายเหตุ")] public string? Note { get; set; } [Comment("สถานะการใช้งาน")] public bool IsActive { get; set; } = true; [Comment("เช็คอัพคะแนน")] public bool SetSeat { get; set; } = false; [Comment("ประกาศนี้มีสมัครสอบคัดเลือก")] public bool AnnouncementExam { get; set; } = false; [Comment("สำนัก")] public string? Category { get; set; } [Comment("รายชื่อคนสม้ครในรอบ")] public List Candidate { get; set; } = new List(); [Comment("ตำแหน่งสมัคร")] public List PositionExam { get; set; } = new List(); [Comment("ช่องทางชำระเงิน")] public List BankExam { get; set; } = new List(); [Comment("เอกสารอื่นๆ")] public virtual List PeriodExamDocuments { get; set; } = new(); [Comment("รูป")] public virtual List PeriodExamImages { get; set; } = new(); public Document? ImportFile { get; set; } = new Document(); public List Disables { get; set; } = new List(); public ScoreImport? ScoreImport { get; set; } public List ImportHostories { get; set; } = new List(); } }