wyq 1 year ago
parent
commit
71650c86d2
48 changed files with 365 additions and 139 deletions
  1. 3 1
      Service/CheckServer/CheckServer.csproj
  2. 6 4
      Service/CheckServer/MainForm.cs
  3. 7 1
      Service/CpuCgServer/AddIns/XcorrUtils.cs
  4. 11 8
      Service/CpuCgServer/Controllers/CpuCgController.cs
  5. 3 1
      Service/CpuCgServer/CpuCgServer.csproj
  6. 6 4
      Service/CpuCgServer/MainForm.cs
  7. 3 1
      Service/GpuCgServer/GpuCgServer.csproj
  8. 6 4
      Service/GpuCgServer/MainForm.cs
  9. 4 3
      Service/X2D1NoRefTaskServer/LogInfo.cs
  10. 7 4
      Service/X2D1NoRefTaskServer/MainForm.cs
  11. 6 4
      Service/X2D1TaskServer54/MainForm.cs
  12. 3 3
      XdCxRhDW.App/Controllers/DetectCgController.cs
  13. 15 18
      XdCxRhDW.App/Controllers/PosController.cs
  14. 32 14
      XdCxRhDW.App/CorTools/DetectToolForm.cs
  15. 96 52
      XdCxRhDW.App/CorTools/DetectToolForm.designer.cs
  16. 45 0
      XdCxRhDW.App/DxHelper/SvgHelper.cs
  17. 16 0
      XdCxRhDW.App/ExtensionsDev/GridControlEx.cs
  18. 45 6
      XdCxRhDW.App/ExtensionsDev/MapControlEx.cs
  19. 1 0
      XdCxRhDW.App/MainForm.cs
  20. 2 2
      XdCxRhDW.App/Model/ModelPosRes.cs
  21. BIN
      XdCxRhDW.App/Service/CPU参估服务/AddIns/CPU参估服务.exe
  22. BIN
      XdCxRhDW.App/Service/CPU参估服务/AddIns/CPU参估服务.pdb
  23. BIN
      XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDW.Framework.dll
  24. BIN
      XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDW.Framework.pdb
  25. BIN
      XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDW.WebApi.dll
  26. BIN
      XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDW.WebApi.pdb
  27. BIN
      XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDw.Dto.dll
  28. BIN
      XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDw.Dto.pdb
  29. BIN
      XdCxRhDW.App/Service/CPU参估服务/CPU参估服务.exe
  30. BIN
      XdCxRhDW.App/Service/GPU参估服务/AddIns/GPU参估服务.exe
  31. BIN
      XdCxRhDW.App/Service/GPU参估服务/AddIns/GPU参估服务.pdb
  32. BIN
      XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDW.Framework.dll
  33. BIN
      XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDW.Framework.pdb
  34. BIN
      XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDW.WebApi.dll
  35. BIN
      XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDW.WebApi.pdb
  36. BIN
      XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDw.Dto.dll
  37. BIN
      XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDw.Dto.pdb
  38. BIN
      XdCxRhDW.App/Service/GPU参估服务/GPU参估服务.exe
  39. BIN
      XdCxRhDW.App/Service/信号检测服务/AddIns/XdCxRhDW.Framework.dll
  40. BIN
      XdCxRhDW.App/Service/信号检测服务/AddIns/XdCxRhDW.WebApi.dll
  41. BIN
      XdCxRhDW.App/Service/信号检测服务/AddIns/XdCxRhDw.Dto.dll
  42. BIN
      XdCxRhDW.App/Service/信号检测服务/AddIns/信号检测服务.exe
  43. BIN
      XdCxRhDW.App/Service/信号检测服务/信号检测服务.exe
  44. 0 1
      XdCxRhDW.App/UserControl/CtrlHome.cs
  45. 36 0
      XdCxRhDW.App/XdCxRhDW.App.csproj
  46. 1 8
      XdCxRhDW.Entity/PosRes.cs
  47. 6 0
      XdCxRhDw.Dto/CpuCgDto.cs
  48. 5 0
      XdCxRhDw.Dto/DetectDto.cs

+ 3 - 1
Service/CheckServer/CheckServer.csproj

@@ -232,7 +232,9 @@
   <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
   <PropertyGroup>
     <PostBuildEvent>copy XdCxRhDw*.dll ..\..\..\..\XdCxRhDW.App\Service\信号检测服务\AddIns\
-copy *.exe ..\..\..\..\XdCxRhDW.App\Service\信号检测服务\AddIns\
+copy *.pdb ..\..\..\..\XdCxRhDW.App\Service\信号检测服务\AddIns\
+copy *.exe ..\..\..\..\XdCxRhDW.App\Service\信号检测服务\
+
 del DevExpress*.xml,EntityFramework*.xml,Serilog*.xml,Newtonsoft*.xml
 del System*.xml,Microsoft*.xml,autofac*.xml,MySql*.xml,K4os*.xml,google*.xml
 del BouncyCastle*.xml

+ 6 - 4
Service/CheckServer/MainForm.cs

@@ -1,4 +1,5 @@
-using DxHelper;
+using DevExpress.Utils;
+using DxHelper;
 using System;
 using System.Collections.Generic;
 using System.Configuration;
@@ -15,9 +16,10 @@ namespace CheckServer
         public MainForm()
         {
             InitializeComponent();
-            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>();
-            gridView1.Columns[0].MaxWidth = 150;
-            gridView1.Columns[1].MaxWidth = 120;
+            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>().SetLogImageColumn(nameof(LogInfo.LogType), typeof(EnumLogType));
+            gridView1.Columns[nameof(LogInfo.LogType)].MaxWidth = 100;
+            gridView1.Columns[nameof(LogInfo.LogTime)].MaxWidth = 160;
+            gridView1.Columns[nameof(LogInfo.Msg)].AppearanceCell.TextOptions.HAlignment = HorzAlignment.Near;
             this.IconOptions.SvgImage = DxHelper.SvgHelper.LoadFromFile("Service.svg");
             LogHelper.Logger = info =>
             {

+ 7 - 1
Service/CpuCgServer/AddIns/XcorrUtils.cs

@@ -20,6 +20,8 @@ namespace CpuCgServer
         public double dfRange { get; set; }         //频差范围
         public double snrThreshold { get; set; }	//信噪比门限
 
+        public int TimeoutSeconds { get; set; }
+
         public XcorrStruct Copy()
         {
             XcorrStruct xItem = new XcorrStruct();
@@ -107,7 +109,11 @@ namespace CpuCgServer
                 cafp.Start();
                 Stopwatch stopWatch = new Stopwatch();
                 stopWatch.Start();
-                cafp.WaitForExit();
+                var suceed = cafp.WaitForExit(xs.TimeoutSeconds * 1000);
+                if (!suceed)
+                {
+                    throw new Exception("CPU参估超时");
+                }
                 stopWatch.Stop();
                 TimeSpan ts = stopWatch.Elapsed;
                 var str = cafp.StandardOutput.ReadToEnd();

+ 11 - 8
Service/CpuCgServer/Controllers/CpuCgController.cs

@@ -25,13 +25,17 @@ namespace CpuCgServer.Controllers
         {
             dto.file1 = GetLocalFile(dto.file1);
             dto.file2 = GetLocalFile(dto.file2);
-            XcorrStruct xItem = new XcorrStruct();
-            xItem.file1 = dto.file1;
-            xItem.file2 = dto.file2;
-            xItem.samplingRate = dto.samplingRate;
-            xItem.dtCenter = dto.dtCenter;
-            xItem.dtRange = dto.dtRange;
-            xItem.dfRange = dto.dfRange;
+            XcorrStruct xItem = new XcorrStruct
+            {
+                file1 = dto.file1,
+                file2 = dto.file2,
+                samplingRate = dto.samplingRate,
+                dtCenter = dto.dtCenter,
+                dtRange = dto.dtRange,
+                dfRange = dto.dfRange,
+                TimeoutSeconds = dto.TimeoutSeconds,
+                snrThreshold = dto.snrThreshold,
+            };
             FileInfo file1 = new FileInfo(dto.file1);
             FileInfo file2 = new FileInfo(dto.file2);
             long totalsamp = file1.Length < file2.Length ? file1.Length / 4 : file2.Length / 4;
@@ -49,7 +53,6 @@ namespace CpuCgServer.Controllers
                 xItem.smpCount = dto.smpCount;
             }
             xItem.smpStart = dto.smpStart;
-            xItem.snrThreshold = dto.snrThreshold;
 
             CpuCgResDto resDto = new CpuCgResDto();
             try

+ 3 - 1
Service/CpuCgServer/CpuCgServer.csproj

@@ -184,7 +184,9 @@
   <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
   <PropertyGroup>
     <PostBuildEvent>copy XdCxRhDw*.dll ..\..\..\..\XdCxRhDW.App\Service\CPU参估服务\AddIns\
-copy *.exe ..\..\..\..\XdCxRhDW.App\Service\CPU参估服务\AddIns\
+copy *.pdb ..\..\..\..\XdCxRhDW.App\Service\CPU参估服务\AddIns\
+copy *.exe ..\..\..\..\XdCxRhDW.App\Service\CPU参估服务\
+
 del DevExpress*.xml,EntityFramework*.xml,Serilog*.xml,Newtonsoft*.xml
 del System*.xml,Microsoft*.xml,autofac*.xml,MySql*.xml,K4os*.xml,google*.xml
 del BouncyCastle*.xml

+ 6 - 4
Service/CpuCgServer/MainForm.cs

@@ -1,4 +1,5 @@
-using DxHelper;
+using DevExpress.Utils;
+using DxHelper;
 using System;
 using System.Collections.Generic;
 using System.Configuration;
@@ -15,9 +16,10 @@ namespace CpuCgServer
         public MainForm()
         {
             InitializeComponent();
-            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>();
-            gridView1.Columns[0].MaxWidth = 150;
-            gridView1.Columns[1].MaxWidth = 120;
+            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>().SetLogImageColumn(nameof(LogInfo.LogType), typeof(EnumLogType));
+            gridView1.Columns[nameof(LogInfo.LogType)].MaxWidth = 100;
+            gridView1.Columns[nameof(LogInfo.LogTime)].MaxWidth = 160;
+            gridView1.Columns[nameof(LogInfo.Msg)].AppearanceCell.TextOptions.HAlignment = HorzAlignment.Near;
             this.IconOptions.SvgImage = DxHelper.SvgHelper.LoadFromFile("Service.svg");
             LogHelper.Logger = info =>
             {

+ 3 - 1
Service/GpuCgServer/GpuCgServer.csproj

@@ -200,7 +200,9 @@
   <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
   <PropertyGroup>
     <PostBuildEvent>copy XdCxRhDw*.dll ..\..\..\..\XdCxRhDW.App\Service\GPU参估服务\AddIns\
-copy *.exe ..\..\..\..\XdCxRhDW.App\Service\GPU参估服务\AddIns\
+copy *.pdb ..\..\..\..\XdCxRhDW.App\Service\GPU参估服务\AddIns\
+copy *.exe ..\..\..\..\XdCxRhDW.App\Service\GPU参估服务\
+
 del DevExpress*.xml,EntityFramework*.xml,Serilog*.xml,Newtonsoft*.xml
 del System*.xml,Microsoft*.xml,autofac*.xml,MySql*.xml,K4os*.xml,google*.xml
 del BouncyCastle*.xml

+ 6 - 4
Service/GpuCgServer/MainForm.cs

@@ -1,4 +1,5 @@
-using DxHelper;
+using DevExpress.Utils;
+using DxHelper;
 using System;
 using System.Collections.Generic;
 using System.Configuration;
@@ -15,9 +16,10 @@ namespace GpuCgServer
         public MainForm()
         {
             InitializeComponent();
-            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>();
-            gridView1.Columns[0].MaxWidth = 150;
-            gridView1.Columns[1].MaxWidth = 120;
+            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>().SetLogImageColumn(nameof(LogInfo.LogType), typeof(EnumLogType));
+            gridView1.Columns[nameof(LogInfo.LogType)].MaxWidth = 100;
+            gridView1.Columns[nameof(LogInfo.LogTime)].MaxWidth = 160;
+            gridView1.Columns[nameof(LogInfo.Msg)].AppearanceCell.TextOptions.HAlignment = HorzAlignment.Near;
             this.IconOptions.SvgImage = DxHelper.SvgHelper.LoadFromFile("Service.svg");
             LogHelper.Logger = info =>
             {

+ 4 - 3
Service/X2D1NoRefTaskServer/LogInfo.cs

@@ -15,12 +15,13 @@ namespace X2D1NoRefTaskServer
             this.LogTime = DateTime.Now;
             this.LogType = EnumLogType.Info;
         }
-        [Display(Name = "时间")]
-        public DateTime LogTime { get; private set; }
-
         [Display(Name = "日志类型")]
         public EnumLogType LogType { get; set; }
 
+
+        [Display(Name = "时间")]
+        public DateTime LogTime { get; private set; }
+
         [Display(Name = "内容")]
         public string Msg { get; set; }
     }

+ 7 - 4
Service/X2D1NoRefTaskServer/MainForm.cs

@@ -6,6 +6,8 @@ using System.Windows.Forms;
 using XdCxRhDW.Dto;
 using XdCxRhDW.WebApi;
 using X2D1NoRefTaskServer;
+using DevExpress.Utils;
+using DevExpress.XtraEditors.Repository;
 
 namespace X2D1NoRefTaskServer
 {
@@ -15,9 +17,10 @@ namespace X2D1NoRefTaskServer
         public MainForm()
         {
             InitializeComponent();
-            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>();
-            gridView1.Columns[0].MaxWidth = 150;
-            gridView1.Columns[1].MaxWidth = 120;
+            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>().SetLogImageColumn(nameof(LogInfo.LogType), typeof(EnumLogType));
+            gridView1.Columns[nameof(LogInfo.LogType)].MaxWidth = 100;
+            gridView1.Columns[nameof(LogInfo.LogTime)].MaxWidth = 160;
+            gridView1.Columns[nameof(LogInfo.Msg)].AppearanceCell.TextOptions.HAlignment = HorzAlignment.Near;
             this.IconOptions.SvgImage = DxHelper.SvgHelper.LoadFromFile("Service.svg");
             LogHelper.Logger = info =>
             {
@@ -33,7 +36,7 @@ namespace X2D1NoRefTaskServer
             var posPlatformAddr = ConfigurationManager.AppSettings["PosPlatformAddr"].Trim();
             this.Text = EnumSvrType.X2D1NoRefHistoryTask.GetEnumDisplayName() + "-" + svrID;
             var localIp = IpHelper.GetLocalIp();
-            
+
             Startup.Start(port, $"{System.Reflection.Assembly.GetExecutingAssembly().GetName().Name}.xml", "XdCxRhDW.Dto.xml");
             LogHelper.Info($"服务启动成功.接口地址http://{localIp}:{port}/swagger");
 

+ 6 - 4
Service/X2D1TaskServer54/MainForm.cs

@@ -1,4 +1,5 @@
-using DxHelper;
+using DevExpress.Utils;
+using DxHelper;
 using System;
 using System.Collections.Generic;
 using System.Configuration;
@@ -14,9 +15,10 @@ namespace X3TaskServer54
         public MainForm()
         {
             InitializeComponent();
-            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>();
-            gridView1.Columns[0].MaxWidth = 150;
-            gridView1.Columns[1].MaxWidth = 120;
+            gridLog.UseDefault(list).UseExportCsv().UseClear<LogInfo>().SetLogImageColumn(nameof(LogInfo.LogType), typeof(EnumLogType));
+            gridView1.Columns[nameof(LogInfo.LogType)].MaxWidth = 100;
+            gridView1.Columns[nameof(LogInfo.LogTime)].MaxWidth = 160;
+            gridView1.Columns[nameof(LogInfo.Msg)].AppearanceCell.TextOptions.HAlignment = HorzAlignment.Near;
             this.IconOptions.SvgImage = DxHelper.SvgHelper.LoadFromFile("Service.svg");
             LogHelper.Logger = info =>
             {

+ 3 - 3
XdCxRhDW.App/Controllers/DetectCgController.cs

@@ -29,7 +29,7 @@ namespace XdCxRhDW.App.Controllers
             var svr = ServerContext.Instance.GetRandomOne(EnumSvrType.CpuCgSvr);
             dto.file1 = await HttpHelper.UploadFileAsync(GetLocalFile(dto.file1), svr.BaseHttpAddr + "/api/File/UploadFileAsync");
             dto.file2 = await HttpHelper.UploadFileAsync(GetLocalFile(dto.file2), svr.BaseHttpAddr + "/api/File/UploadFileAsync");
-            var res = await HttpHelper.PostRequestAsync<CpuCgResDto>(svr.BaseHttpAddr + "/api/CpuCg/Calc", dto);
+            var res = await HttpHelper.PostRequestAsync<CpuCgResDto>(svr.BaseHttpAddr + "/api/CpuCg/Calc", dto,dto.TimeoutSeconds);
             return res;
         }
 
@@ -58,7 +58,7 @@ namespace XdCxRhDW.App.Controllers
             var svr = ServerContext.Instance.GetRandomOne(EnumSvrType.CpuCgSvr);
             dto.file1 = await HttpHelper.UploadFileAsync(GetLocalFile(dto.file1), svr.BaseHttpAddr + "/api/File/UploadFileAsync");
             dto.file2 = await HttpHelper.UploadFileAsync(GetLocalFile(dto.file2), svr.BaseHttpAddr + "/api/File/UploadFileAsync");
-            var res = await HttpHelper.PostRequestAsync<List<ImageResultDto>>(svr.BaseHttpAddr + "/api/CpuCg/DrawImage", dto);
+            var res = await HttpHelper.PostRequestAsync<List<ImageResultDto>>(svr.BaseHttpAddr + "/api/CpuCg/DrawImage", dto, dto.TimeoutSeconds);
             return res;
         }
         /// <summary>
@@ -86,7 +86,7 @@ namespace XdCxRhDW.App.Controllers
         {
             var svr = ServerContext.Instance.GetRandomOne(EnumSvrType.CheckSvr);
             dto.file1 = await HttpHelper.UploadFileAsync(GetLocalFile(dto.file1), svr.BaseHttpAddr + "/api/File/UploadFileAsync");
-            var res = await HttpHelper.PostRequestAsync<List<DetectResDto>>(svr.BaseHttpAddr + "/api/Check/Calc", dto);
+            var res = await HttpHelper.PostRequestAsync<List<DetectResDto>>(svr.BaseHttpAddr + "/api/Check/Calc", dto,dto.TimeoutSeconds);
             return res;
         }
 

+ 15 - 18
XdCxRhDW.App/Controllers/PosController.cs

@@ -943,7 +943,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.SxDto,4),
+                    Dto1 = Math.Round(dto.SxDto, 4),
                     Dfo1 = Math.Round(dto.SxDfo.Value, 4),
                     Snr1 = Math.Round(dto.SxSnr.Value, 4),
                     DtoCdb = Math.Round(dto.XdDto, 4),
@@ -1060,7 +1060,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.Dto1,4),
+                    Dto1 = Math.Round(dto.Dto1, 4),
                     Dfo1 = Math.Round(dto.Dfo1.Value, 4),
                     Snr1 = Math.Round(dto.Snr1.Value, 4),
                     Dto2 = Math.Round(dto.Dto2, 4),
@@ -1218,7 +1218,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.Dto1,4),
+                    Dto1 = Math.Round(dto.Dto1, 4),
                     Dfo1 = Math.Round(dto.Dfo1.Value, 4),
                     Snr1 = Math.Round(dto.Snr1.Value, 4),
                     Dto2 = Math.Round(dto.Dto2, 4),
@@ -1335,7 +1335,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.Dto1,4),
+                    Dto1 = Math.Round(dto.Dto1, 4),
                     Dfo1 = Math.Round(dto.Dfo1.Value, 4),
                     Snr1 = Math.Round(dto.Snr1.Value, 4),
                     Dto2 = Math.Round(dto.Dto2, 4),
@@ -1487,7 +1487,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.Dto1,4),
+                    Dto1 = Math.Round(dto.Dto1, 4),
                     Dfo1 = Math.Round(dto.Dfo1.Value, 4),
                     Snr1 = Math.Round(dto.Snr1.Value, 4),
                     Dto2 = Math.Round(dto.Dto2, 4),
@@ -1605,7 +1605,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.Dto1.Value,4),
+                    Dto1 = Math.Round(dto.Dto1.Value, 4),
                     Dfo1 = Math.Round(dto.Dfo1, 4),
                     Snr1 = Math.Round(dto.Snr1.Value, 4),
                     Dto2 = Math.Round(dto.Dto2.Value, 4),
@@ -1765,7 +1765,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.Dto1.Value,4),
+                    Dto1 = Math.Round(dto.Dto1.Value, 4),
                     Dfo1 = Math.Round(dto.Dfo1, 4),
                     Snr1 = Math.Round(dto.Snr1.Value, 4),
                     Dto2 = Math.Round(dto.Dto2.Value, 4),
@@ -1888,7 +1888,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.Dto,4),
+                    Dto1 = Math.Round(dto.Dto, 4),
                     Dfo1 = Math.Round(dto.Dfo, 4),
                     Snr1 = Math.Round(dto.Snr.Value, 4),
                     YbMainDto = Math.Round(dto.YbMainDto, 4),
@@ -2025,7 +2025,7 @@ namespace XdCxRhDW.App.Controllers
                 var cgRes = db.CgRes.Add(new CgRes()
                 {
                     SigTime = dto.SigTime,
-                    Dto1 = Math.Round(dto.Dto,4),
+                    Dto1 = Math.Round(dto.Dto, 4),
                     Dfo1 = Math.Round(dto.Dfo, 4),
                     Snr1 = Math.Round(dto.Snr.Value, 4),
                     YbMainDto = Math.Round(dto.YbMainDto, 4),
@@ -2168,18 +2168,17 @@ namespace XdCxRhDW.App.Controllers
                             query = query.Where(p => p.PosLon != 999);
                         if (dto.TarFrequpHz != null)
                             query = query.Where(p => p.FreqUpHz == dto.TarFrequpHz.Value);
-                        var posRes = await query.OrderByDescending(p => p.SigTime).ToListAsync();
+                        var posRes = await query.Include(p => p.CheckRes).OrderByDescending(p => p.SigTime).ToListAsync();
 
                         foreach (var itemPos in posRes)
                         {
-                            itemPos.TargetInfo = targets?.FirstOrDefault(p => p.ID == itemPos.TargetInfoID);
-                            if (itemPos.TargetInfo != null && !string.IsNullOrWhiteSpace(itemPos.TargetInfo.TargeColor))
+                            if (itemPos.TargetInfoID > 0)
                             {
-                                itemPos.ColorKey = itemPos.TargetInfo.TargeColor;
+                                itemPos.TargetInfo = targets.FirstOrDefault(p => p.ID == itemPos.TargetInfoID);
+                                if (itemPos.TargetInfo != null && !string.IsNullOrWhiteSpace(itemPos.TargetInfo.TargeColor))
+                                    itemPos.ColorKey = itemPos.TargetInfo.TargeColor;
+
                             }
-                            itemPos.BaseTargetName = itemPos.TargetInfo?.TargetName;
-                            itemPos.CheckRes = await db.CheckRes.FirstOrDefaultAsync(p => p.ID == itemPos.CheckResID);
-                            itemPos.BaseCheckType = itemPos.CheckRes?.PosCheckType?.GetEnumDisplayName();
                         }
                         posList.AddRange(posRes);
                     }
@@ -2390,8 +2389,6 @@ namespace XdCxRhDW.App.Controllers
                 TargetInfo = res.TargetInfo,
                 TargetInfoID = res.TargetInfoID,
                 UpdateTime = res.UpdateTime,
-                BaseTargetName = res.TargetInfo?.TargetName,
-                BaseCheckType = res.CheckRes?.PosCheckType?.GetEnumDisplayName(),
             };
         }
 

+ 32 - 14
XdCxRhDW.App/CorTools/DetectToolForm.cs

@@ -89,6 +89,7 @@ namespace XdCxRhDW.App.CorTools
                                 dfRange = int.Parse(teDfRange.Text),
                                 smpStart = item.smpstart,
                                 snrThreshold = int.Parse(teSnr.Text),
+                                TimeoutSeconds=int.Parse(txtTimeout.Text),
                             };
                         }
                         catch (Exception ex)
@@ -100,7 +101,7 @@ namespace XdCxRhDW.App.CorTools
 
                         try
                         {
-                            var result = await HttpHelper.PostRequestAsync<CpuCgResDto>(baseUrl + "DetectCg/CpuCgCalc", xItem);
+                            var result = await HttpHelper.PostRequestAsync<CpuCgResDto>(baseUrl + "DetectCg/CpuCgCalc", xItem, xItem.TimeoutSeconds);
                             if (result.code == 200)
                             {
                                 item.dt = result.data.Dt;
@@ -232,7 +233,8 @@ namespace XdCxRhDW.App.CorTools
                 }
                 dto.fsHz = double.Parse(tefs.Text) * 1e6;
                 dto.band = double.Parse(txtBand.Text);
-                var dmcResult = await HttpHelper.PostRequestAsync<IEnumerable<DetectResDto>>(baseUrl + "DetectCg/DetectCalc", dto);
+                dto.TimeoutSeconds = int.Parse(txtTimeout.Text);
+                var dmcResult = await HttpHelper.PostRequestAsync<IEnumerable<DetectResDto>>(baseUrl + "DetectCg/DetectCalc", dto,dto.TimeoutSeconds);
                 if (dmcResult.code == 200)
                 {
                     foreach (var dmcItem in dmcResult.data)
@@ -302,6 +304,7 @@ namespace XdCxRhDW.App.CorTools
                 xItem.dfRange = int.Parse(teDfRange.Text);
                 xItem.smpStart = long.Parse(tePos.Text);
                 xItem.snrThreshold = int.Parse(teSnr.Text);
+                xItem.TimeoutSeconds = int.Parse(txtTimeout.Text);
             }
             catch (Exception ex)
             {
@@ -315,7 +318,7 @@ namespace XdCxRhDW.App.CorTools
 
             try
             {
-                var result = await HttpHelper.PostRequestAsync<CpuCgResDto>(baseUrl + "DetectCg/CpuCgCalc", xItem);
+                var result = await HttpHelper.PostRequestAsync<CpuCgResDto>(baseUrl + "DetectCg/CpuCgCalc", xItem, xItem.TimeoutSeconds);
                 if (result.code == 200)
                 {
                     DateTime? sigTime = null;
@@ -343,6 +346,11 @@ namespace XdCxRhDW.App.CorTools
                     DxHelper.MsgBoxHelper.ShowError(result.msg);
                 }
             }
+            catch (TaskCanceledException)
+            {
+                Serilog.Log.Warning("CPU文件参估Http接口调用超时");
+                DxHelper.MsgBoxHelper.ShowInfo("CPU文件参估Http接口调用超时");
+            }
             catch (Exception ex)
             {
                 Serilog.Log.Error(ex, "CPU文件参估出错");
@@ -369,31 +377,41 @@ namespace XdCxRhDW.App.CorTools
                     smpStart = int.Parse(tePos.Text),
                     smpCount = double.Parse(teCount.Text),
                     snrThreshold = int.Parse(teSnr.Text),
-                };
+                    TimeoutSeconds = int.Parse(txtTimeout.Text)
+            };
                 par.file1 = await HttpHelper.UploadFileAsync(btnFile1.Text, baseUrl + "File/UploadFileAsync");
                 par.file2 = await HttpHelper.UploadFileAsync(btnFile2.Text, baseUrl + "File/UploadFileAsync");
               
-                var resp = await HttpHelper.PostRequestAsync<List<ImageResultDto>>(baseUrl + "DetectCg/DrawImage", par);
+                var resp = await HttpHelper.PostRequestAsync<List<ImageResultDto>>(baseUrl + "DetectCg/DrawImage", par,par.TimeoutSeconds);
+                if (resp.code != 200)
+                {
+                    Serilog.Log.Error(resp.msg);
+                    DxHelper.MsgBoxHelper.ShowError(resp.msg);
+                }
+                else
+                {
+                    if (res != null && res.Any())
+                    {
+                        new CgImageForm(res).ShowDialog();
+                    }
+                    else
+                    {
+                        DxHelper.MsgBoxHelper.ShowInfo("无计算结果!");
+                    }
+                }
                 WriteIni();
             }
             catch (Exception ex)
             {
                 Serilog.Log.Error(ex, "参估绘图失败");
-                DxHelper.MsgBoxHelper.ShowError($"参估绘图失败{ex.Message}");
+                DxHelper.MsgBoxHelper.ShowError($"参估绘图失败");
                 return;
             }
             finally
             {
                 layoutControl1.Enabled = true;
             }
-            if (res != null && res.Any())
-            {
-                new CgImageForm(res).ShowDialog();
-            }
-            else
-            {
-                DxHelper.MsgBoxHelper.ShowInfo("无计算结果!");
-            }
+            
         }
 
         private void chkDama_CheckedChanged(object sender, EventArgs e)

+ 96 - 52
XdCxRhDW.App/CorTools/DetectToolForm.designer.cs

@@ -58,6 +58,11 @@
             DevExpress.Utils.SerializableAppearanceObject serializableAppearanceObject22 = new DevExpress.Utils.SerializableAppearanceObject();
             DevExpress.Utils.SerializableAppearanceObject serializableAppearanceObject23 = new DevExpress.Utils.SerializableAppearanceObject();
             DevExpress.Utils.SerializableAppearanceObject serializableAppearanceObject24 = new DevExpress.Utils.SerializableAppearanceObject();
+            DevExpress.XtraEditors.Controls.EditorButtonImageOptions editorButtonImageOptions7 = new DevExpress.XtraEditors.Controls.EditorButtonImageOptions();
+            DevExpress.Utils.SerializableAppearanceObject serializableAppearanceObject25 = new DevExpress.Utils.SerializableAppearanceObject();
+            DevExpress.Utils.SerializableAppearanceObject serializableAppearanceObject26 = new DevExpress.Utils.SerializableAppearanceObject();
+            DevExpress.Utils.SerializableAppearanceObject serializableAppearanceObject27 = new DevExpress.Utils.SerializableAppearanceObject();
+            DevExpress.Utils.SerializableAppearanceObject serializableAppearanceObject28 = new DevExpress.Utils.SerializableAppearanceObject();
             this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
             this.txtFileTime = new DevExpress.XtraEditors.DateEdit();
             this.btnCalc = new DevExpress.XtraEditors.SimpleButton();
@@ -111,6 +116,8 @@
             this.layoutItemDrawImage = new DevExpress.XtraLayout.LayoutControlItem();
             this.layoutControlItem13 = new DevExpress.XtraLayout.LayoutControlItem();
             this.itemBand = new DevExpress.XtraLayout.LayoutControlItem();
+            this.txtTimeout = new DevExpress.XtraEditors.ButtonEdit();
+            this.layoutControlItem14 = new DevExpress.XtraLayout.LayoutControlItem();
             ((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
             this.layoutControl1.SuspendLayout();
             ((System.ComponentModel.ISupportInitialize)(this.txtFileTime.Properties)).BeginInit();
@@ -149,6 +156,8 @@
             ((System.ComponentModel.ISupportInitialize)(this.layoutItemDrawImage)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem13)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.itemBand)).BeginInit();
+            ((System.ComponentModel.ISupportInitialize)(this.txtTimeout.Properties)).BeginInit();
+            ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem14)).BeginInit();
             this.SuspendLayout();
             // 
             // layoutControl1
@@ -171,13 +180,14 @@
             this.layoutControl1.Controls.Add(this.teDfRange);
             this.layoutControl1.Controls.Add(this.teSnr);
             this.layoutControl1.Controls.Add(this.txtBand);
+            this.layoutControl1.Controls.Add(this.txtTimeout);
             this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
             this.layoutControl1.Location = new System.Drawing.Point(0, 0);
             this.layoutControl1.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.layoutControl1.Name = "layoutControl1";
             this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(620, 232, 1300, 800);
             this.layoutControl1.Root = this.Root;
-            this.layoutControl1.Size = new System.Drawing.Size(1100, 488);
+            this.layoutControl1.Size = new System.Drawing.Size(1315, 488);
             this.layoutControl1.TabIndex = 0;
             this.layoutControl1.Text = "layoutControl1";
             // 
@@ -191,13 +201,13 @@
             new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
             this.txtFileTime.Properties.CalendarTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
             new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
-            this.txtFileTime.Size = new System.Drawing.Size(65, 20);
+            this.txtFileTime.Size = new System.Drawing.Size(74, 20);
             this.txtFileTime.StyleController = this.layoutControl1;
             this.txtFileTime.TabIndex = 20;
             // 
             // btnCalc
             // 
-            this.btnCalc.Location = new System.Drawing.Point(899, 31);
+            this.btnCalc.Location = new System.Drawing.Point(1114, 31);
             this.btnCalc.Name = "btnCalc";
             this.btnCalc.Size = new System.Drawing.Size(96, 22);
             this.btnCalc.StyleController = this.layoutControl1;
@@ -207,7 +217,7 @@
             // 
             // chkDama
             // 
-            this.chkDama.Location = new System.Drawing.Point(799, 6);
+            this.chkDama.Location = new System.Drawing.Point(1014, 6);
             this.chkDama.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.chkDama.Name = "chkDama";
             this.chkDama.Properties.Caption = "DAMA";
@@ -219,7 +229,7 @@
             // 
             // btnCheck
             // 
-            this.btnCheck.Location = new System.Drawing.Point(799, 31);
+            this.btnCheck.Location = new System.Drawing.Point(1014, 31);
             this.btnCheck.Name = "btnCheck";
             this.btnCheck.Size = new System.Drawing.Size(96, 22);
             this.btnCheck.StyleController = this.layoutControl1;
@@ -234,7 +244,7 @@
             this.gcCheckCgRes.MainView = this.gridView1;
             this.gcCheckCgRes.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.gcCheckCgRes.Name = "gcCheckCgRes";
-            this.gcCheckCgRes.Size = new System.Drawing.Size(1090, 401);
+            this.gcCheckCgRes.Size = new System.Drawing.Size(1305, 401);
             this.gcCheckCgRes.TabIndex = 12;
             this.gcCheckCgRes.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
             this.gridView1});
@@ -408,22 +418,22 @@
             // tePos
             // 
             this.tePos.EditValue = "0";
-            this.tePos.Location = new System.Drawing.Point(934, 57);
+            this.tePos.Location = new System.Drawing.Point(982, 57);
             this.tePos.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.tePos.Name = "tePos";
             this.tePos.Properties.AutoHeight = false;
-            this.tePos.Size = new System.Drawing.Size(50, 20);
+            this.tePos.Size = new System.Drawing.Size(69, 20);
             this.tePos.StyleController = this.layoutControl1;
             this.tePos.TabIndex = 10;
             // 
             // teCount
             // 
             this.teCount.EditValue = "0";
-            this.teCount.Location = new System.Drawing.Point(1045, 57);
+            this.teCount.Location = new System.Drawing.Point(1112, 57);
             this.teCount.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.teCount.Name = "teCount";
             this.teCount.Properties.AutoHeight = false;
-            this.teCount.Size = new System.Drawing.Size(50, 20);
+            this.teCount.Size = new System.Drawing.Size(68, 20);
             this.teCount.StyleController = this.layoutControl1;
             this.teCount.TabIndex = 9;
             this.teCount.ToolTip = "0表示文件末尾,小数表示样点百分比";
@@ -436,7 +446,7 @@
             this.btnFile1.Name = "btnFile1";
             this.btnFile1.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
             new DevExpress.XtraEditors.Controls.EditorButton()});
-            this.btnFile1.Size = new System.Drawing.Size(726, 20);
+            this.btnFile1.Size = new System.Drawing.Size(941, 20);
             this.btnFile1.StyleController = this.layoutControl1;
             this.btnFile1.TabIndex = 5;
             // 
@@ -448,13 +458,13 @@
             this.btnFile2.Name = "btnFile2";
             this.btnFile2.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
             new DevExpress.XtraEditors.Controls.EditorButton()});
-            this.btnFile2.Size = new System.Drawing.Size(726, 20);
+            this.btnFile2.Size = new System.Drawing.Size(941, 20);
             this.btnFile2.StyleController = this.layoutControl1;
             this.btnFile2.TabIndex = 4;
             // 
             // ckIBS
             // 
-            this.ckIBS.Location = new System.Drawing.Point(899, 6);
+            this.ckIBS.Location = new System.Drawing.Point(1114, 6);
             this.ckIBS.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.ckIBS.Name = "ckIBS";
             this.ckIBS.Properties.Caption = "IBS";
@@ -466,7 +476,7 @@
             // 
             // ckKY
             // 
-            this.ckKY.Location = new System.Drawing.Point(999, 6);
+            this.ckKY.Location = new System.Drawing.Point(1214, 6);
             this.ckKY.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.ckKY.Name = "ckKY";
             this.ckKY.Properties.Caption = "能量检测";
@@ -478,7 +488,7 @@
             // 
             // btnDrawImage
             // 
-            this.btnDrawImage.Location = new System.Drawing.Point(999, 31);
+            this.btnDrawImage.Location = new System.Drawing.Point(1214, 31);
             this.btnDrawImage.Name = "btnDrawImage";
             this.btnDrawImage.Size = new System.Drawing.Size(96, 22);
             this.btnDrawImage.StyleController = this.layoutControl1;
@@ -489,33 +499,33 @@
             // tefs
             // 
             this.tefs.EditValue = "0.096";
-            this.tefs.Location = new System.Drawing.Point(172, 57);
+            this.tefs.Location = new System.Drawing.Point(181, 57);
             this.tefs.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.tefs.Name = "tefs";
             this.tefs.Properties.AutoHeight = false;
             this.tefs.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
             new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Glyph, "MHz", -1, false, true, false, editorButtonImageOptions1, new DevExpress.Utils.KeyShortcut(System.Windows.Forms.Keys.None), serializableAppearanceObject1, serializableAppearanceObject2, serializableAppearanceObject3, serializableAppearanceObject4, "", null, null, DevExpress.Utils.ToolTipAnchor.Default)});
-            this.tefs.Size = new System.Drawing.Size(72, 20);
+            this.tefs.Size = new System.Drawing.Size(82, 20);
             this.tefs.StyleController = this.layoutControl1;
             this.tefs.TabIndex = 6;
             // 
             // teCenter
             // 
             this.teCenter.EditValue = "0";
-            this.teCenter.Location = new System.Drawing.Point(427, 57);
+            this.teCenter.Location = new System.Drawing.Point(455, 57);
             this.teCenter.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.teCenter.Name = "teCenter";
             this.teCenter.Properties.AutoHeight = false;
             this.teCenter.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
             new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Glyph, "us", -1, false, true, false, editorButtonImageOptions2, new DevExpress.Utils.KeyShortcut(System.Windows.Forms.Keys.None), serializableAppearanceObject5, serializableAppearanceObject6, serializableAppearanceObject7, serializableAppearanceObject8, "", null, null, DevExpress.Utils.ToolTipAnchor.Default)});
-            this.teCenter.Size = new System.Drawing.Size(54, 20);
+            this.teCenter.Size = new System.Drawing.Size(70, 20);
             this.teCenter.StyleController = this.layoutControl1;
             this.teCenter.TabIndex = 7;
             // 
             // teRange
             // 
             this.teRange.EditValue = "40000";
-            this.teRange.Location = new System.Drawing.Point(564, 57);
+            this.teRange.Location = new System.Drawing.Point(608, 57);
             this.teRange.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.teRange.Name = "teRange";
             this.teRange.Properties.AutoHeight = false;
@@ -528,7 +538,7 @@
             // teDfRange
             // 
             this.teDfRange.EditValue = "16384";
-            this.teDfRange.Location = new System.Drawing.Point(698, 57);
+            this.teDfRange.Location = new System.Drawing.Point(742, 57);
             this.teDfRange.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.teDfRange.Name = "teDfRange";
             this.teDfRange.Properties.AutoHeight = false;
@@ -541,26 +551,26 @@
             // teSnr
             // 
             this.teSnr.EditValue = "14";
-            this.teSnr.Location = new System.Drawing.Point(822, 57);
+            this.teSnr.Location = new System.Drawing.Point(866, 57);
             this.teSnr.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.teSnr.Name = "teSnr";
             this.teSnr.Properties.AutoHeight = false;
             this.teSnr.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
             new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Glyph, "dB", -1, false, true, false, editorButtonImageOptions5, new DevExpress.Utils.KeyShortcut(System.Windows.Forms.Keys.None), serializableAppearanceObject17, serializableAppearanceObject18, serializableAppearanceObject19, serializableAppearanceObject20, "", null, null, DevExpress.Utils.ToolTipAnchor.Default)});
-            this.teSnr.Size = new System.Drawing.Size(52, 20);
+            this.teSnr.Size = new System.Drawing.Size(56, 20);
             this.teSnr.StyleController = this.layoutControl1;
             this.teSnr.TabIndex = 14;
             // 
             // txtBand
             // 
             this.txtBand.EditValue = "25";
-            this.txtBand.Location = new System.Drawing.Point(305, 57);
+            this.txtBand.Location = new System.Drawing.Point(324, 57);
             this.txtBand.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
             this.txtBand.Name = "txtBand";
             this.txtBand.Properties.AutoHeight = false;
             this.txtBand.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
             new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Glyph, "KHz", -1, false, true, false, editorButtonImageOptions6, new DevExpress.Utils.KeyShortcut(System.Windows.Forms.Keys.None), serializableAppearanceObject21, serializableAppearanceObject22, serializableAppearanceObject23, serializableAppearanceObject24, "", null, null, DevExpress.Utils.ToolTipAnchor.Default)});
-            this.txtBand.Size = new System.Drawing.Size(61, 21);
+            this.txtBand.Size = new System.Drawing.Size(70, 21);
             this.txtBand.StyleController = this.layoutControl1;
             this.txtBand.TabIndex = 6;
             // 
@@ -586,10 +596,11 @@
             this.layoutControlItem11,
             this.layoutItemDrawImage,
             this.layoutControlItem13,
-            this.itemBand});
+            this.itemBand,
+            this.layoutControlItem14});
             this.Root.Name = "Root";
             this.Root.Padding = new DevExpress.XtraLayout.Utils.Padding(3, 3, 3, 3);
-            this.Root.Size = new System.Drawing.Size(1100, 488);
+            this.Root.Size = new System.Drawing.Size(1315, 488);
             this.Root.TextVisible = false;
             // 
             // layoutControlItem2
@@ -597,7 +608,7 @@
             this.layoutControlItem2.Control = this.btnFile1;
             this.layoutControlItem2.Location = new System.Drawing.Point(0, 0);
             this.layoutControlItem2.Name = "layoutControlItem2";
-            this.layoutControlItem2.Size = new System.Drawing.Size(794, 26);
+            this.layoutControlItem2.Size = new System.Drawing.Size(1009, 26);
             this.layoutControlItem2.Text = "信号文件1:";
             this.layoutControlItem2.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
             this.layoutControlItem2.TextSize = new System.Drawing.Size(59, 14);
@@ -606,11 +617,11 @@
             // layoutControlItem3
             // 
             this.layoutControlItem3.Control = this.tefs;
-            this.layoutControlItem3.Location = new System.Drawing.Point(122, 52);
+            this.layoutControlItem3.Location = new System.Drawing.Point(131, 52);
             this.layoutControlItem3.MaxSize = new System.Drawing.Size(0, 24);
             this.layoutControlItem3.MinSize = new System.Drawing.Size(109, 24);
             this.layoutControlItem3.Name = "layoutControlItem3";
-            this.layoutControlItem3.Size = new System.Drawing.Size(121, 25);
+            this.layoutControlItem3.Size = new System.Drawing.Size(131, 25);
             this.layoutControlItem3.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
             this.layoutControlItem3.Text = "采样率:";
             this.layoutControlItem3.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
@@ -622,7 +633,7 @@
             this.layoutControlItem9.Control = this.gcCheckCgRes;
             this.layoutControlItem9.Location = new System.Drawing.Point(0, 77);
             this.layoutControlItem9.Name = "layoutControlItem9";
-            this.layoutControlItem9.Size = new System.Drawing.Size(1094, 405);
+            this.layoutControlItem9.Size = new System.Drawing.Size(1309, 405);
             this.layoutControlItem9.TextSize = new System.Drawing.Size(0, 0);
             this.layoutControlItem9.TextVisible = false;
             // 
@@ -631,7 +642,7 @@
             this.layoutControlItem1.Control = this.btnFile2;
             this.layoutControlItem1.Location = new System.Drawing.Point(0, 26);
             this.layoutControlItem1.Name = "layoutControlItem1";
-            this.layoutControlItem1.Size = new System.Drawing.Size(794, 26);
+            this.layoutControlItem1.Size = new System.Drawing.Size(1009, 26);
             this.layoutControlItem1.Text = "信号文件2:";
             this.layoutControlItem1.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
             this.layoutControlItem1.TextSize = new System.Drawing.Size(59, 14);
@@ -640,11 +651,11 @@
             // layoutControlItem4
             // 
             this.layoutControlItem4.Control = this.teCenter;
-            this.layoutControlItem4.Location = new System.Drawing.Point(365, 52);
+            this.layoutControlItem4.Location = new System.Drawing.Point(393, 52);
             this.layoutControlItem4.MaxSize = new System.Drawing.Size(0, 24);
             this.layoutControlItem4.MinSize = new System.Drawing.Size(111, 24);
             this.layoutControlItem4.Name = "layoutControlItem4";
-            this.layoutControlItem4.Size = new System.Drawing.Size(115, 25);
+            this.layoutControlItem4.Size = new System.Drawing.Size(131, 25);
             this.layoutControlItem4.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
             this.layoutControlItem4.Text = "时差中心:";
             this.layoutControlItem4.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
@@ -654,7 +665,7 @@
             // layoutControlItem5
             // 
             this.layoutControlItem5.Control = this.teRange;
-            this.layoutControlItem5.Location = new System.Drawing.Point(480, 52);
+            this.layoutControlItem5.Location = new System.Drawing.Point(524, 52);
             this.layoutControlItem5.MaxSize = new System.Drawing.Size(0, 24);
             this.layoutControlItem5.MinSize = new System.Drawing.Size(133, 24);
             this.layoutControlItem5.Name = "layoutControlItem5";
@@ -668,11 +679,11 @@
             // layoutControlItem10
             // 
             this.layoutControlItem10.Control = this.teSnr;
-            this.layoutControlItem10.Location = new System.Drawing.Point(748, 52);
+            this.layoutControlItem10.Location = new System.Drawing.Point(792, 52);
             this.layoutControlItem10.MaxSize = new System.Drawing.Size(0, 24);
             this.layoutControlItem10.MinSize = new System.Drawing.Size(125, 24);
             this.layoutControlItem10.Name = "layoutControlItem10";
-            this.layoutControlItem10.Size = new System.Drawing.Size(125, 25);
+            this.layoutControlItem10.Size = new System.Drawing.Size(129, 25);
             this.layoutControlItem10.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
             this.layoutControlItem10.Text = "信噪比门限:";
             this.layoutControlItem10.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
@@ -682,7 +693,7 @@
             // layoutControlItem8
             // 
             this.layoutControlItem8.Control = this.teDfRange;
-            this.layoutControlItem8.Location = new System.Drawing.Point(613, 52);
+            this.layoutControlItem8.Location = new System.Drawing.Point(657, 52);
             this.layoutControlItem8.MaxSize = new System.Drawing.Size(0, 24);
             this.layoutControlItem8.MinSize = new System.Drawing.Size(135, 24);
             this.layoutControlItem8.Name = "layoutControlItem8";
@@ -696,11 +707,11 @@
             // lciStartPos
             // 
             this.lciStartPos.Control = this.tePos;
-            this.lciStartPos.Location = new System.Drawing.Point(873, 52);
+            this.lciStartPos.Location = new System.Drawing.Point(921, 52);
             this.lciStartPos.MaxSize = new System.Drawing.Size(0, 24);
             this.lciStartPos.MinSize = new System.Drawing.Size(110, 24);
             this.lciStartPos.Name = "lciStartPos";
-            this.lciStartPos.Size = new System.Drawing.Size(110, 25);
+            this.lciStartPos.Size = new System.Drawing.Size(129, 25);
             this.lciStartPos.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
             this.lciStartPos.Text = "起始样点:";
             this.lciStartPos.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
@@ -710,11 +721,11 @@
             // lciSampleLength
             // 
             this.lciSampleLength.Control = this.teCount;
-            this.lciSampleLength.Location = new System.Drawing.Point(983, 52);
+            this.lciSampleLength.Location = new System.Drawing.Point(1050, 52);
             this.lciSampleLength.MaxSize = new System.Drawing.Size(0, 24);
             this.lciSampleLength.MinSize = new System.Drawing.Size(111, 24);
             this.lciSampleLength.Name = "lciSampleLength";
-            this.lciSampleLength.Size = new System.Drawing.Size(111, 25);
+            this.lciSampleLength.Size = new System.Drawing.Size(129, 25);
             this.lciSampleLength.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
             this.lciSampleLength.Text = "样点长度:";
             this.lciSampleLength.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
@@ -726,7 +737,7 @@
             this.layoutControlItem12.ContentHorzAlignment = DevExpress.Utils.HorzAlignment.Center;
             this.layoutControlItem12.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
             this.layoutControlItem12.Control = this.chkDama;
-            this.layoutControlItem12.Location = new System.Drawing.Point(794, 0);
+            this.layoutControlItem12.Location = new System.Drawing.Point(1009, 0);
             this.layoutControlItem12.MaxSize = new System.Drawing.Size(100, 26);
             this.layoutControlItem12.MinSize = new System.Drawing.Size(100, 26);
             this.layoutControlItem12.Name = "layoutControlItem12";
@@ -738,7 +749,7 @@
             // lciBtnCheck
             // 
             this.lciBtnCheck.Control = this.btnCheck;
-            this.lciBtnCheck.Location = new System.Drawing.Point(794, 26);
+            this.lciBtnCheck.Location = new System.Drawing.Point(1009, 26);
             this.lciBtnCheck.MaxSize = new System.Drawing.Size(100, 26);
             this.lciBtnCheck.MinSize = new System.Drawing.Size(100, 26);
             this.lciBtnCheck.Name = "lciBtnCheck";
@@ -752,7 +763,7 @@
             this.layoutControlItem6.ContentHorzAlignment = DevExpress.Utils.HorzAlignment.Center;
             this.layoutControlItem6.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
             this.layoutControlItem6.Control = this.ckIBS;
-            this.layoutControlItem6.Location = new System.Drawing.Point(894, 0);
+            this.layoutControlItem6.Location = new System.Drawing.Point(1109, 0);
             this.layoutControlItem6.MaxSize = new System.Drawing.Size(100, 26);
             this.layoutControlItem6.MinSize = new System.Drawing.Size(100, 26);
             this.layoutControlItem6.Name = "layoutControlItem6";
@@ -766,7 +777,7 @@
             this.layoutControlItem7.ContentHorzAlignment = DevExpress.Utils.HorzAlignment.Center;
             this.layoutControlItem7.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
             this.layoutControlItem7.Control = this.ckKY;
-            this.layoutControlItem7.Location = new System.Drawing.Point(994, 0);
+            this.layoutControlItem7.Location = new System.Drawing.Point(1209, 0);
             this.layoutControlItem7.MaxSize = new System.Drawing.Size(100, 24);
             this.layoutControlItem7.MinSize = new System.Drawing.Size(100, 24);
             this.layoutControlItem7.Name = "layoutControlItem7";
@@ -778,7 +789,7 @@
             // layoutControlItem11
             // 
             this.layoutControlItem11.Control = this.btnCalc;
-            this.layoutControlItem11.Location = new System.Drawing.Point(894, 26);
+            this.layoutControlItem11.Location = new System.Drawing.Point(1109, 26);
             this.layoutControlItem11.MaxSize = new System.Drawing.Size(100, 26);
             this.layoutControlItem11.MinSize = new System.Drawing.Size(100, 26);
             this.layoutControlItem11.Name = "layoutControlItem11";
@@ -792,7 +803,7 @@
             this.layoutItemDrawImage.Control = this.btnDrawImage;
             this.layoutItemDrawImage.ControlAlignment = System.Drawing.ContentAlignment.TopLeft;
             this.layoutItemDrawImage.CustomizationFormText = "lciBtnCheck";
-            this.layoutItemDrawImage.Location = new System.Drawing.Point(994, 26);
+            this.layoutItemDrawImage.Location = new System.Drawing.Point(1209, 26);
             this.layoutItemDrawImage.MaxSize = new System.Drawing.Size(100, 26);
             this.layoutItemDrawImage.MinSize = new System.Drawing.Size(100, 26);
             this.layoutItemDrawImage.Name = "layoutItemDrawImage";
@@ -809,7 +820,7 @@
             this.layoutControlItem13.MaxSize = new System.Drawing.Size(0, 24);
             this.layoutControlItem13.MinSize = new System.Drawing.Size(107, 24);
             this.layoutControlItem13.Name = "layoutControlItem13";
-            this.layoutControlItem13.Size = new System.Drawing.Size(122, 25);
+            this.layoutControlItem13.Size = new System.Drawing.Size(131, 25);
             this.layoutControlItem13.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
             this.layoutControlItem13.Text = "文件时间";
             this.layoutControlItem13.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
@@ -821,10 +832,10 @@
             this.itemBand.Control = this.txtBand;
             this.itemBand.ControlAlignment = System.Drawing.ContentAlignment.TopLeft;
             this.itemBand.CustomizationFormText = "采样率:";
-            this.itemBand.Location = new System.Drawing.Point(243, 52);
+            this.itemBand.Location = new System.Drawing.Point(262, 52);
             this.itemBand.MinSize = new System.Drawing.Size(50, 25);
             this.itemBand.Name = "itemBand";
-            this.itemBand.Size = new System.Drawing.Size(122, 25);
+            this.itemBand.Size = new System.Drawing.Size(131, 25);
             this.itemBand.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
             this.itemBand.Text = "信号带宽:";
             this.itemBand.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
@@ -832,11 +843,40 @@
             this.itemBand.TextToControlDistance = 5;
             this.itemBand.Visibility = DevExpress.XtraLayout.Utils.LayoutVisibility.Never;
             // 
+            // txtTimeout
+            // 
+            this.txtTimeout.EditValue = "30";
+            this.txtTimeout.Location = new System.Drawing.Point(1241, 57);
+            this.txtTimeout.Margin = new System.Windows.Forms.Padding(2, 1, 2, 1);
+            this.txtTimeout.Name = "txtTimeout";
+            this.txtTimeout.Properties.AutoHeight = false;
+            this.txtTimeout.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
+            new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Glyph, "秒", -1, false, true, false, editorButtonImageOptions7, new DevExpress.Utils.KeyShortcut(System.Windows.Forms.Keys.None), serializableAppearanceObject25, serializableAppearanceObject26, serializableAppearanceObject27, serializableAppearanceObject28, "", null, null, DevExpress.Utils.ToolTipAnchor.Default)});
+            this.txtTimeout.Size = new System.Drawing.Size(69, 20);
+            this.txtTimeout.StyleController = this.layoutControl1;
+            this.txtTimeout.TabIndex = 14;
+            // 
+            // layoutControlItem14
+            // 
+            this.layoutControlItem14.Control = this.txtTimeout;
+            this.layoutControlItem14.ControlAlignment = System.Drawing.ContentAlignment.TopLeft;
+            this.layoutControlItem14.CustomizationFormText = "信噪比门限:";
+            this.layoutControlItem14.Location = new System.Drawing.Point(1179, 52);
+            this.layoutControlItem14.MaxSize = new System.Drawing.Size(0, 24);
+            this.layoutControlItem14.MinSize = new System.Drawing.Size(125, 24);
+            this.layoutControlItem14.Name = "layoutControlItem14";
+            this.layoutControlItem14.Size = new System.Drawing.Size(130, 25);
+            this.layoutControlItem14.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
+            this.layoutControlItem14.Text = "超时时间:";
+            this.layoutControlItem14.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.AutoSize;
+            this.layoutControlItem14.TextSize = new System.Drawing.Size(52, 14);
+            this.layoutControlItem14.TextToControlDistance = 5;
+            // 
             // DetectToolForm
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.ClientSize = new System.Drawing.Size(1100, 488);
+            this.ClientSize = new System.Drawing.Size(1315, 488);
             this.Controls.Add(this.layoutControl1);
             this.Margin = new System.Windows.Forms.Padding(2);
             this.MaximizeBox = false;
@@ -882,6 +922,8 @@
             ((System.ComponentModel.ISupportInitialize)(this.layoutItemDrawImage)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem13)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.itemBand)).EndInit();
+            ((System.ComponentModel.ISupportInitialize)(this.txtTimeout.Properties)).EndInit();
+            ((System.ComponentModel.ISupportInitialize)(this.layoutControlItem14)).EndInit();
             this.ResumeLayout(false);
 
         }
@@ -941,5 +983,7 @@
         private DevExpress.XtraGrid.Columns.GridColumn modRate;
         private DevExpress.XtraGrid.Columns.GridColumn DemType;
         private DevExpress.XtraGrid.Columns.GridColumn colFFC;
+        private DevExpress.XtraEditors.ButtonEdit txtTimeout;
+        private DevExpress.XtraLayout.LayoutControlItem layoutControlItem14;
     }
 }

+ 45 - 0
XdCxRhDW.App/DxHelper/SvgHelper.cs

@@ -552,5 +552,50 @@ namespace DxHelper
             ms.Dispose();
             return svg;
         }
+        /// <summary>
+        /// Info
+        /// </summary>
+        /// <returns></returns>
+        public static SvgImage CreateInfo (string color= "#1177D7", int width = 24, int height = 24)
+        {
+            string xml = $"<svg xmlns='http://www.w3.org/2000/svg\' width='{width}px' height='{height}px' viewBox='0 0 32 32'>"
+                + $"<path fill='{color}' d='M16,2C8.3,2,2,8.3,2,16s6.3,14,14,14s14-6.3,14-14S23.7,2,16,2z M16,6c1.1,0,2,0.9,2,2s-0.9,2-2,2s-2-0.9-2-2S14.9,6,16,6z M20,24h-8v-2h2v-8h-2v-2h2h4v10h2V24z'/>\r\n"
+                + $"<path fill='{color}' d='M16,2C8.3,2,2,8.3,2,16s6.3,14,14,14s14-6.3,14-14S23.7,2,16,2z M16,6c1.1,0,2,0.9,2,2s-0.9,2-2,2s-2-0.9-2-2S14.9,6,16,6z M20,24h-8v-2h2v-8h-2v-2h2h4v10h2V24z'/>\r\n"
+                + "</svg>";
+            MemoryStream ms = new MemoryStream(Encoding.UTF8.GetBytes(xml));
+            var svg = SvgLoader.LoadFromStream(ms);
+            ms.Dispose();
+            return svg;
+        }
+        /// <summary>
+        /// Warning
+        /// </summary>
+        /// <returns></returns>
+        public static SvgImage CreateWarning(string color= "#FFB115", int width = 24, int height = 24)
+        {
+            string xml = $"<svg xmlns='http://www.w3.org/2000/svg\' width='{width}px' height='{height}px' viewBox='0 0 32 32'>"
+                + $"<path fill='{color}' d='M14.9,4.7c0.6-1,1.5-1,2.1,0l12.7,21.5c0.6,1,0.1,1.8-1,1.8H3.3c-1.2,0-1.6-0.8-1-1.8L14.9,4.7z'/>"
+                + $"<circle fill='#727272' cx='16' cy='22' r='2'/>"
+                + $"<rect x='14' y='10' fill='#727272' width='4' height='8'/>"
+                + "</svg>";
+            MemoryStream ms = new MemoryStream(Encoding.UTF8.GetBytes(xml));
+            var svg = SvgLoader.LoadFromStream(ms);
+            ms.Dispose();
+            return svg;
+        }
+        /// <summary>
+        /// Error
+        /// </summary>
+        /// <returns></returns>
+        public static SvgImage CreateError(string color = "#D11C1C", int width = 24, int height = 24)
+        {
+            string xml = $"<svg xmlns='http://www.w3.org/2000/svg\' width='{width}px' height='{height}px' viewBox='0 0 32 32'>"
+                + $"<path fill='{color}' d='M16,2C8.3,2,2,8.3,2,16s6.3,14,14,14s14-6.3,14-14S23.7,2,16,2z M16,24c-1.1,0-2-0.9-2-2s0.9-2,2-2s2,0.9,2,2S17.1,24,16,24z M18,18h-4V8h4V18z'/>"
+                + "</svg>";
+            MemoryStream ms = new MemoryStream(Encoding.UTF8.GetBytes(xml));
+            var svg = SvgLoader.LoadFromStream(ms);
+            ms.Dispose();
+            return svg;
+        }
     }
 }

+ 16 - 0
XdCxRhDW.App/ExtensionsDev/GridControlEx.cs

@@ -6,6 +6,7 @@ using DevExpress.Utils.Svg;
 using DevExpress.XtraBars;
 using DevExpress.XtraEditors;
 using DevExpress.XtraEditors.Controls;
+using DevExpress.XtraEditors.Repository;
 using DevExpress.XtraGrid;
 using DevExpress.XtraGrid.Columns;
 using DevExpress.XtraGrid.Views.Grid;
@@ -361,6 +362,21 @@ public static class GridControlEx
         }, false);
         return grid;
     }
+    public static GridControl SetLogImageColumn(this GridControl grid, string columnFieldName,Type enumType)
+    {
+        var view = grid.MainView as GridView;
+        RepositoryItemImageComboBox edit = new RepositoryItemImageComboBox();
+        edit.AddEnum(enumType);
+        SvgImageCollection svgImages = new SvgImageCollection();
+        svgImages.ImageSize = new System.Drawing.Size(20, 20);
+        svgImages.Add(SvgHelper.CreateInfo());
+        svgImages.Add(SvgHelper.CreateWarning());
+        svgImages.Add(SvgHelper.CreateError());
+        edit.SmallImages = svgImages;
+        edit.GlyphAlignment = DevExpress.Utils.HorzAlignment.Center;
+        view.Columns[columnFieldName].ColumnEdit = edit;
+        return grid;
+    }
 
     /// <summary>
     /// 为GirdControl启用右键清除所有数据的功能

+ 45 - 6
XdCxRhDW.App/ExtensionsDev/MapControlEx.cs

@@ -135,6 +135,12 @@ public static class MapControlEx
         ctrl.ToolTipController.BeforeShow += (sender, e) =>
         {
             if (e.SelectedObject == null) return;
+            if (e.SelectedObject is MapPolyline)
+            {
+                e.SuperTip = null;
+                e.ToolTip = null;
+                return;
+            }
             SuperToolTip superToolTip = new SuperToolTip();
             if (innerData.posMenu.Visible || innerData.mapMenu.Visible || innerData.rectMenu.Visible)
             {
@@ -550,8 +556,41 @@ public static class MapControlEx
             };
             list.Add(mapItem);
             innerData._dataCache.Add(p, mapItem);
+
         }
+        var itemList = items.OrderBy(p => p.SigTime).ToList().GroupBy(t => t.ColorKey);
+        List<MapPolyline> listLine = new List<MapPolyline>();
+        foreach (var groupItems in itemList)
+        {
+            var targets = groupItems.ToList();
+            var colorKey = targets.First().ColorKey;
+            for (int i = 0; i < targets.Count - 1; i++)
+            {
+                var line = new MapPolyline();
+                line.CanEdit = false;
+                line.CanMove = false;
+                line.CanResize = false;
+                line.CanRotate = false;
+                line.EnableSelection = DefaultBoolean.False;
+                line.EnableHighlighting = DefaultBoolean.False;
+                line.IsGeodesic = true;
+                line.Stroke = ColorHelper.IsHtmlColor(colorKey) ? ColorTranslator.FromHtml(colorKey) : ColorHelper.GetColor(colorKey);
+                line.EndLineCap.Width = 12;
+                line.EndLineCap.Length = 20;
+                line.EndLineCap.Visible = true;
+                line.EndLineCap.IsFilled = false;
+                line.StrokeWidth = 2;
+                //line.EndLineCap.Length = 100;
+                var p1 = new GeoPoint(targets[i].PosLat, targets[i].PosLon);
+                var p2 = new GeoPoint(targets[i + 1].PosLat, targets[i + 1].PosLon);
+                line.Points.Add(p1);
+                line.Points.Add(p2);
+                listLine.Add(line);
+            }
+        }
+
         innerData.posStorge.Items.AddRange(list);
+        innerData.posStorge.Items.AddRange(listLine);
     }
 
     /// <summary>
@@ -649,7 +688,7 @@ public static class MapControlEx
     /// <param name="setCenter">是否将这个点设置到地图中心显示</param>
     public static void UpdatePosItem<T>(this MapControl ctrl, T item, bool setCenter = false) where T : PosData, new()
     {
-        if (item == null||item.PosLon==999||item.PosLat==999) return;
+        if (item == null || item.PosLon == 999 || item.PosLat == 999) return;
         var innerData = ctrl.Tag as InnerData;
         var key = innerData._dataCache.Keys.Where(p => p.ID == item.ID).FirstOrDefault();
         if (key != null)
@@ -874,7 +913,7 @@ public static class MapControlEx
                 tileSource.LayerName = "satellite";
                 ImageLayer satelliteImageLayer = new ImageLayer()
                 {
-                     Name="WMTS:SJZX-SatMap"
+                    Name = "WMTS:SJZX-SatMap"
                 };
                 ctrl.Layers.Add(satelliteImageLayer);
                 satelliteImageLayer.DataProvider = provider;
@@ -889,7 +928,7 @@ public static class MapControlEx
                 tileSource.LayerName = "electron";
                 ImageLayer electronImageLayer = new ImageLayer()
                 {
-                    Name="WMTS:SJZX-Electron"
+                    Name = "WMTS:SJZX-Electron"
                 };
                 ctrl.Layers.Add(electronImageLayer);
                 electronImageLayer.DataProvider = provider;
@@ -936,7 +975,7 @@ public static class MapControlEx
                 tileSource.LayerType = layerType;
                 tileSource.LayerName = "overlay-final";
                 ImageLayer overlayImageLayer = new ImageLayer()
-                { 
+                {
                     Name = "WMTS:ZCJ-Overlay"
                 };
                 ctrl.Layers.Add(overlayImageLayer);
@@ -983,7 +1022,7 @@ public static class MapControlEx
         //    if (string.IsNullOrWhiteSpace(layerName))
         //        provider.ActiveLayerName = e.Layers[0].Name;
         //};
-        ImageLayer layer = new ImageLayer() { Name="WMTS:Wms"};
+        ImageLayer layer = new ImageLayer() { Name = "WMTS:Wms" };
         layer.DataProvider = provider;
         ctrl.Layers.Add(layer);
         return ctrl;
@@ -1906,7 +1945,7 @@ public static class MapControlEx
         mMapType = mapType;
         listMapCtrl.ForEach(t =>
         {
-            var localLayer =t.GetImageLayer()?.FirstOrDefault(p=>p.Name=="WMTS:Local");
+            var localLayer = t.GetImageLayer()?.FirstOrDefault(p => p.Name == "WMTS:Local");
             if (localLayer == null) return;
             var provider = localLayer.DataProvider as MapTileDataProviderBase;
             provider?.ClearCache();

+ 1 - 0
XdCxRhDW.App/MainForm.cs

@@ -78,6 +78,7 @@ namespace XdCxRhDW
             {
                 this.HtmlText = $"<size=12>{text}(<size=9>{settings.TimeZoneDisplayName}</size>)";
             });
+            await Task.Delay(5000);
             StartProcess();
             _ = XlScan();
             _ = XlClear();

+ 2 - 2
XdCxRhDW.App/Model/ModelPosRes.cs

@@ -18,10 +18,10 @@ namespace XdCxRhDW.App.Model
         }
         [Display(Name = "目标名称")]
         [ToolTip]
-        public string TargetName => BaseTargetName;
+        public string TargetName => TargetInfo?.TargetName;
 
         [Display(Name = "检测方式")]
         [ToolTip]
-        public string CheckType => BaseCheckType;
+        public string CheckType => CheckRes?.PosCheckType?.GetEnumDisplayName();
     }
 }

BIN
XdCxRhDW.App/Service/CPU参估服务/AddIns/CPU参估服务.exe


BIN
XdCxRhDW.App/Service/CPU参估服务/AddIns/CPU参估服务.pdb


BIN
XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDW.Framework.dll


BIN
XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDW.Framework.pdb


BIN
XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDW.WebApi.dll


BIN
XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDW.WebApi.pdb


BIN
XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDw.Dto.dll


BIN
XdCxRhDW.App/Service/CPU参估服务/AddIns/XdCxRhDw.Dto.pdb


BIN
XdCxRhDW.App/Service/CPU参估服务/CPU参估服务.exe


BIN
XdCxRhDW.App/Service/GPU参估服务/AddIns/GPU参估服务.exe


BIN
XdCxRhDW.App/Service/GPU参估服务/AddIns/GPU参估服务.pdb


BIN
XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDW.Framework.dll


BIN
XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDW.Framework.pdb


BIN
XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDW.WebApi.dll


BIN
XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDW.WebApi.pdb


BIN
XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDw.Dto.dll


BIN
XdCxRhDW.App/Service/GPU参估服务/AddIns/XdCxRhDw.Dto.pdb


BIN
XdCxRhDW.App/Service/GPU参估服务/GPU参估服务.exe


BIN
XdCxRhDW.App/Service/信号检测服务/AddIns/XdCxRhDW.Framework.dll


BIN
XdCxRhDW.App/Service/信号检测服务/AddIns/XdCxRhDW.WebApi.dll


BIN
XdCxRhDW.App/Service/信号检测服务/AddIns/XdCxRhDw.Dto.dll


BIN
XdCxRhDW.App/Service/信号检测服务/AddIns/信号检测服务.exe


BIN
XdCxRhDW.App/Service/信号检测服务/信号检测服务.exe


+ 0 - 1
XdCxRhDW.App/UserControl/CtrlHome.cs

@@ -1435,7 +1435,6 @@ namespace XdCxRhDW.App.UserControl
                 {
                     p.TargetInfoID = tar.ID;
                     p.TargetInfo = tar;
-                    p.BaseTargetName = tar.TargetName;
                     p.ColorKey = tar.TargeColor;
                 });
                 gridView2.RefreshData();

+ 36 - 0
XdCxRhDW.App/XdCxRhDW.App.csproj

@@ -1169,6 +1169,42 @@
     <None Include="Service\信号检测服务\信号检测服务.xml">
       <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
     </None>
+    <None Include="Service\CPU参估服务\AddIns\CPU参估服务.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\CPU参估服务\AddIns\XdCxRhDw.Dto.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\CPU参估服务\AddIns\XdCxRhDW.Framework.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\CPU参估服务\AddIns\XdCxRhDW.WebApi.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\GPU参估服务\AddIns\GPU参估服务.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\GPU参估服务\AddIns\XdCxRhDw.Dto.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\GPU参估服务\AddIns\XdCxRhDW.Framework.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\GPU参估服务\AddIns\XdCxRhDW.WebApi.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\信号检测服务\AddIns\XdCxRhDw.Dto.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\信号检测服务\AddIns\XdCxRhDW.Framework.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\信号检测服务\AddIns\XdCxRhDW.WebApi.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
+    <None Include="Service\信号检测服务\AddIns\信号检测服务.pdb">
+      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+    </None>
     <Content Include="定位.ico" />
   </ItemGroup>
   <ItemGroup>

+ 1 - 8
XdCxRhDW.Entity/PosRes.cs

@@ -35,10 +35,6 @@ namespace XdCxRhDW.Entity
         [JsonIgnore]
         public virtual CxRes CxRes { get; set; }
 
-        [NotMapped]
-        [Display(AutoGenerateField = false)]
-        public string BaseCheckType { get; set; }
-
         [Display(Name = "参估编号")]
         public long CgResID { get; set; }
 
@@ -48,17 +44,14 @@ namespace XdCxRhDW.Entity
 
         [Display(AutoGenerateField = false)]
         public int? TargetInfoID { get; set; }
-        public TargetInfo TargetInfo;
 
-        [NotMapped]
         [Display(AutoGenerateField = false)]
-        public string BaseTargetName { get; set; }
+        public virtual TargetInfo TargetInfo { get; set; }
 
         [Display(Name = "检测编号")]
         public long? CheckResID { get; set; }
 
         [Display(AutoGenerateField = false)]
-        [JsonIgnore]
         public virtual CheckRes CheckRes { get; set; }
 
         [Display(Name = "定位点")]

+ 6 - 0
XdCxRhDw.Dto/CpuCgDto.cs

@@ -70,6 +70,12 @@ namespace XdCxRhDW.Dto
         [RangeDouble(10, 50, IncludeMin = true)]
         public double snrThreshold { get; set; }
 
+        /// <summary>
+        /// 超时时间(秒)
+        /// </summary>
+        [RangeInt(1)]
+        public int TimeoutSeconds { get; set; } = 30;
+
         /// <summary>
         /// 模型参数自定义验证(复杂的验证逻辑在这里面写)
         /// </summary>

+ 5 - 0
XdCxRhDw.Dto/DetectDto.cs

@@ -37,6 +37,11 @@ namespace XdCxRhDW.Dto
         [RangeDouble(0, 100)]
         public double? band { get; set; } = 25;
 
+        /// <summary>
+        /// 超时时间(秒)
+        /// </summary>
+        [RangeInt(1)]
+        public int TimeoutSeconds { get; set; } = 30;
         /// <summary>
         /// 
         /// </summary>