ModelPosRes.cs 2.0 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. using XdCxRhDW.Entity;
  9. namespace XdCxRhDW.Repostory
  10. {
  11. /// <summary>
  12. /// 定位结果UI绑定对象
  13. /// </summary>
  14. public class ModelPosRes : 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(Name = "测向编号")]
  23. public long? CxResID { get; set; }
  24. [Display(Name = "参估编号")]
  25. public long CgResID { get; set; }
  26. [Display(AutoGenerateField = false)]
  27. public int? TargetID { get; set; }
  28. [Display(Name = "目标名称")]
  29. public string TarName { get; set; } = "未识别";
  30. [Display(Name = "时隙标识")]
  31. public string TsName { get; set; } = "未知";
  32. [Display(Name = "定位点")]
  33. public string LonLat
  34. {
  35. get
  36. {
  37. if (PosLon == 0 && PosLat == 0)
  38. return "无";
  39. else if (PosLon > 180 || PosLon < -180)
  40. return "无";
  41. else
  42. return $"{PosLon:f4},{PosLat:f4}";
  43. }
  44. }
  45. [Display(Name = "镜像点")]
  46. public string MirrLonLat
  47. {
  48. get
  49. {
  50. if (MirrLon == 0 && MirrLat == 0)
  51. return "无";
  52. else if (MirrLon > 180 || MirrLon < -180)
  53. return "无";
  54. else
  55. return $"{MirrLon:f4},{MirrLat:f4}";
  56. }
  57. }
  58. [Display(Name = "定位类型")]
  59. public EnumPosResType PosResType { get; set; }
  60. [Display(Name = "目标状态")]
  61. public EnumTargetState TargetState { get; set; }
  62. }
  63. }