CmPatrolHistoryPos.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233
  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 CmPatrolHistoryPos
  8. {
  9. public int SiteId { get; set; }
  10. public int PatrolHistoryId { get; set; }
  11. public int PosId { get; set; }
  12. [Column(TypeName = "datetime")]
  13. public DateTime PatrolTime { get; set; }
  14. [Column("term")]
  15. public int? Term { get; set; }
  16. [Column("resultType")]
  17. public int ResultType { get; set; }
  18. [Key]
  19. [Column("mId")]
  20. public int MId { get; set; }
  21. [ForeignKey("SiteId,PosId")]
  22. [InverseProperty("CmPatrolHistoryPos")]
  23. public virtual CmPatrolPos CmPatrolPos { get; set; }
  24. [ForeignKey("SiteId,ResultType")]
  25. [InverseProperty("CmPatrolHistoryPos")]
  26. public virtual CmPatrolType CmPatrolType { get; set; }
  27. [ForeignKey(nameof(SiteId))]
  28. [InverseProperty(nameof(CmSite.CmPatrolHistoryPos))]
  29. public virtual CmSite Site { get; set; }
  30. }
  31. }