ExamDataReport.cs 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. using Microsoft.EntityFrameworkCore;
  2. using System;
  3. using System.ComponentModel.DataAnnotations;
  4. using System.ComponentModel.DataAnnotations.Schema;
  5. namespace YBEE.EQM.Core;
  6. /// <summary>
  7. /// 监测计划数据上报类型
  8. /// </summary>
  9. [Comment("监测计划数据上报类型")]
  10. public class ExamDataReport : DEntityBase
  11. {
  12. /// <summary>
  13. /// 监测计划ID
  14. /// </summary>
  15. [Comment("监测计划ID")]
  16. [Required]
  17. public int ExamPlanId { get; set; }
  18. /// <summary>
  19. /// 上报类型
  20. /// </summary>
  21. [Comment("上报类型")]
  22. [Required, Column(TypeName = "smallint")]
  23. public DataReportType Type { get; set; }
  24. /// <summary>
  25. /// 状态
  26. /// </summary>
  27. [Comment("状态")]
  28. [Required, Column(TypeName = "smallint")]
  29. public ExamStatus Status { get; set; } = ExamStatus.READY;
  30. /// <summary>
  31. /// 开始时间
  32. /// </summary>
  33. [Comment("开始时间")]
  34. [Required]
  35. public DateTime BeginTime { get; set; }
  36. /// <summary>
  37. /// 结束时间
  38. /// </summary>
  39. [Comment("结束时间")]
  40. [Required]
  41. public DateTime EndTime { get; set; }
  42. /// <summary>
  43. /// 上报说明
  44. /// </summary>
  45. [Comment("上报说明")]
  46. [StringLength(2000)]
  47. public string Remark { get; set; } = "";
  48. /// <summary>
  49. /// 附件
  50. /// </summary>
  51. [Comment("附件")]
  52. [Column(TypeName = "json")]
  53. public string Attachments { get; set; } = "[]";
  54. /// <summary>
  55. /// 一对一引用(监测计划)
  56. /// </summary>
  57. public virtual ExamPlan ExamPlan { get; set; }
  58. }