PosRes.cs 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  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.App.Model
  9. {
  10. [Table("PosRes")]
  11. public class PosRes : PosData
  12. {
  13. [Display(Name = "任务编号")]
  14. public int TaskID { get; set; }
  15. [Display(AutoGenerateField = false)]
  16. public virtual TaskInfo TaskInfo { get;set;}
  17. [Display(Name = "站点ID")]
  18. public long StationResID { get; set; }
  19. [Display(AutoGenerateField = false)]
  20. public virtual StationRes StationRes { get; set; }
  21. [Display(Name = "测向编号")]
  22. public long? CxResID { get; set; }
  23. [Display(AutoGenerateField =false)]
  24. public virtual CxRes CxRes { get; set;}
  25. [Display(Name = "参估编号")]
  26. public long CgResID { get; set; }
  27. [Display(AutoGenerateField = false)]
  28. public virtual CgRes CgRes { get; set; }
  29. [Display(AutoGenerateField = false)]
  30. public int? TargetID { get; set; }
  31. [Display(Name = "目标名称")]
  32. public string TarName { get; set; } = "未识别";
  33. [Display(Name = "时隙标识")]
  34. public string TsName { get; set; } = "未知";
  35. [Display(Name = "定位点")]
  36. public string LonLat
  37. {
  38. get
  39. {
  40. if (PosLon == 0 && PosLat == 0)
  41. return "无";
  42. else if (PosLon > 180 || PosLon < -180)
  43. return "无";
  44. else
  45. return $"{PosLon:f4},{PosLat:f4}";
  46. }
  47. }
  48. [Display(Name = "镜像点")]
  49. public string MirrLonLat
  50. {
  51. get
  52. {
  53. if (MirrLon == 0 && MirrLat == 0)
  54. return "无";
  55. else if (MirrLon > 180 || MirrLon < -180)
  56. return "无";
  57. else
  58. return $"{MirrLon:f4},{MirrLat:f4}";
  59. }
  60. }
  61. }
  62. }