PosRes.cs 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel.DataAnnotations;
  4. using System.ComponentModel.DataAnnotations.Schema;
  5. using System.Linq;
  6. using System.Text;
  7. using System.Threading.Tasks;
  8. namespace XdCxRhDW.Entity
  9. {
  10. /// <summary>
  11. /// 定位结果表
  12. /// </summary>
  13. [Table("PosRes")]
  14. public class PosRes : PosData
  15. {
  16. [Display(Name = "任务编号")]
  17. public int TaskInfoID { get; set; }
  18. [Display(Name = "上行频点")]
  19. public long FreqUpHz { get; set; }
  20. [Display(Name = "站点ID")]
  21. public long StationResID { get; set; }
  22. [Display(AutoGenerateField = false)]
  23. public virtual StationRes StationRes { get; set; }
  24. [Display(Name = "测向编号")]
  25. public long? CxResID { get; set; }
  26. [Display(AutoGenerateField = false)]
  27. public virtual CxRes CxRes { get; set; }
  28. [Display(Name = "参估编号")]
  29. public long CgResID { get; set; }
  30. [Display(AutoGenerateField = false)]
  31. public virtual CgRes CgRes { get; set; }
  32. [Display(AutoGenerateField = false)]
  33. public int? TargetInfoID { get; set; }
  34. public TargetInfo TargetInfo;
  35. [Display(Name = "检测编号")]
  36. public long? CheckResID { get; set; }
  37. [Display(AutoGenerateField = false)]
  38. public virtual CheckRes CheckRes { get; set; }
  39. //public CheckRes CheckRes;
  40. [Display(Name = "定位点")]
  41. public string LonLat
  42. {
  43. get
  44. {
  45. if (PosLon == 0 && PosLat == 0)
  46. return "--";
  47. else if (PosLon > 180 || PosLon < -180)
  48. return "--";
  49. else
  50. return $"{PosLon:f4},{PosLat:f4}";
  51. }
  52. }
  53. [Display(Name = "镜像点")]
  54. public string MirrLonLat
  55. {
  56. get
  57. {
  58. if (MirrLon == 0 && MirrLat == 0)
  59. return "--";
  60. else if (MirrLon > 180 || MirrLon < -180)
  61. return "--";
  62. else
  63. return $"{MirrLon:f4},{MirrLat:f4}";
  64. }
  65. }
  66. [Display(Name = "定位类型")]
  67. [ToolTip]
  68. public EnumPosResType PosResType { get; set; }
  69. [Display(Name = "目标状态")]
  70. [ToolTip]
  71. public EnumTargetState TargetState { get; set; }
  72. }
  73. }