CmPatrolHistory.cs 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel.DataAnnotations;
  4. using System.ComponentModel.DataAnnotations.Schema;
  5. namespace FMSAdmin.Entities
  6. {
  7. public partial class CmPatrolHistory
  8. {
  9. public int SiteId { get; set; }
  10. [Key]
  11. public int PatrolHistoryId { get; set; }
  12. public int ScheduleId { get; set; }
  13. [Column("startDate", TypeName = "datetime")]
  14. public DateTime StartDate { get; set; }
  15. [Column("endDate", TypeName = "datetime")]
  16. public DateTime? EndDate { get; set; }
  17. [Column("resultTypeId")]
  18. public int ResultTypeId { get; set; }
  19. [Column("resultDesc")]
  20. [StringLength(1024)]
  21. public string ResultDesc { get; set; }
  22. [Column("resultPosCnt")]
  23. public int? ResultPosCnt { get; set; }
  24. [Column("resultNormalCnt")]
  25. public int? ResultNormalCnt { get; set; }
  26. [Column("resultAbnormalCnt")]
  27. public int? ResultAbnormalCnt { get; set; }
  28. [ForeignKey("SiteId,ResultTypeId")]
  29. [InverseProperty("CmPatrolHistory")]
  30. public virtual CmPatrolType CmPatrolType { get; set; }
  31. [ForeignKey("SiteId,ScheduleId")]
  32. [InverseProperty(nameof(CmPatrolSchedule.CmPatrolHistory))]
  33. public virtual CmPatrolSchedule S { get; set; }
  34. [ForeignKey(nameof(SiteId))]
  35. [InverseProperty(nameof(CmSite.CmPatrolHistory))]
  36. public virtual CmSite Site { get; set; }
  37. }
  38. }