Browse Source

1.界面功能隐藏 2.电务功率算法dll引入

wrinkle17 2 months ago
parent
commit
fa4b4d624c

+ 31 - 24
DPTools/DevFrmMain.Designer.cs

@@ -3490,6 +3490,7 @@
             this.LGLbBtnI.Id = 186;
             this.LGLbBtnI.LargeGlyph = ((System.Drawing.Image)(resources.GetObject("LGLbBtnI.LargeGlyph")));
             this.LGLbBtnI.Name = "LGLbBtnI";
+            this.LGLbBtnI.Visibility = DevExpress.XtraBars.BarItemVisibility.Never;
             this.LGLbBtnI.ItemClick += new DevExpress.XtraBars.ItemClickEventHandler(this.LGLbBtnI_ItemClick);
             // 
             // barButtonItem10
@@ -3709,6 +3710,7 @@
             this.ribbonPageGroup7.ItemLinks.Add(this.barButtonItem24);
             this.ribbonPageGroup7.Name = "ribbonPageGroup7";
             this.ribbonPageGroup7.Text = "监测管理";
+            this.ribbonPageGroup7.Visible = false;
             // 
             // ribbonPage2
             // 
@@ -3836,8 +3838,8 @@
             this.panelContainer2.ID = new System.Guid("f8af83a4-326d-4eab-9c14-ce77b61552f6");
             this.panelContainer2.Location = new System.Drawing.Point(0, 0);
             this.panelContainer2.Name = "panelContainer2";
-            this.panelContainer2.OriginalSize = new System.Drawing.Size(200, 200);
-            this.panelContainer2.Size = new System.Drawing.Size(250, 232);
+            this.panelContainer2.OriginalSize = new System.Drawing.Size(250, 232);
+            this.panelContainer2.Size = new System.Drawing.Size(0, 26);
             this.panelContainer2.Tabbed = true;
             this.panelContainer2.Text = "panelContainer2";
             // 
@@ -3847,10 +3849,10 @@
             this.fieldListDockPanel1.Dock = DevExpress.XtraBars.Docking.DockingStyle.Fill;
             this.fieldListDockPanel1.ID = new System.Guid("faf69838-a93f-4114-83e8-d0d09cc5ce95");
             this.fieldListDockPanel1.ImageIndex = 0;
-            this.fieldListDockPanel1.Location = new System.Drawing.Point(4, 25);
+            this.fieldListDockPanel1.Location = new System.Drawing.Point(0, 0);
             this.fieldListDockPanel1.Name = "fieldListDockPanel1";
-            this.fieldListDockPanel1.OriginalSize = new System.Drawing.Size(200, 200);
-            this.fieldListDockPanel1.Size = new System.Drawing.Size(242, 175);
+            this.fieldListDockPanel1.OriginalSize = new System.Drawing.Size(242, 175);
+            this.fieldListDockPanel1.Size = new System.Drawing.Size(0, 0);
             this.fieldListDockPanel1.Text = "Field List";
             this.fieldListDockPanel1.XRDesignPanel = null;
             // 
@@ -3858,7 +3860,7 @@
             // 
             this.fieldListDockPanel1_Container.Location = new System.Drawing.Point(0, 0);
             this.fieldListDockPanel1_Container.Name = "fieldListDockPanel1_Container";
-            this.fieldListDockPanel1_Container.Size = new System.Drawing.Size(242, 175);
+            this.fieldListDockPanel1_Container.Size = new System.Drawing.Size(0, 0);
             this.fieldListDockPanel1_Container.TabIndex = 0;
             // 
             // reportExplorerDockPanel1
@@ -3867,10 +3869,10 @@
             this.reportExplorerDockPanel1.Dock = DevExpress.XtraBars.Docking.DockingStyle.Fill;
             this.reportExplorerDockPanel1.ID = new System.Guid("fb3ec6cc-3b9b-4b9c-91cf-cff78c1edbf1");
             this.reportExplorerDockPanel1.ImageIndex = 3;
-            this.reportExplorerDockPanel1.Location = new System.Drawing.Point(4, 25);
+            this.reportExplorerDockPanel1.Location = new System.Drawing.Point(0, 0);
             this.reportExplorerDockPanel1.Name = "reportExplorerDockPanel1";
-            this.reportExplorerDockPanel1.OriginalSize = new System.Drawing.Size(200, 200);
-            this.reportExplorerDockPanel1.Size = new System.Drawing.Size(242, 175);
+            this.reportExplorerDockPanel1.OriginalSize = new System.Drawing.Size(242, 175);
+            this.reportExplorerDockPanel1.Size = new System.Drawing.Size(0, 0);
             this.reportExplorerDockPanel1.Text = "Report Explorer";
             this.reportExplorerDockPanel1.XRDesignPanel = null;
             // 
@@ -3878,7 +3880,7 @@
             // 
             this.reportExplorerDockPanel1_Container.Location = new System.Drawing.Point(0, 0);
             this.reportExplorerDockPanel1_Container.Name = "reportExplorerDockPanel1_Container";
-            this.reportExplorerDockPanel1_Container.Size = new System.Drawing.Size(242, 175);
+            this.reportExplorerDockPanel1_Container.Size = new System.Drawing.Size(0, 0);
             this.reportExplorerDockPanel1_Container.TabIndex = 0;
             // 
             // propertyGridDockPanel1
@@ -3887,18 +3889,18 @@
             this.propertyGridDockPanel1.Dock = DevExpress.XtraBars.Docking.DockingStyle.Fill;
             this.propertyGridDockPanel1.ID = new System.Guid("b38d12c3-cd06-4dec-b93d-63a0088e495a");
             this.propertyGridDockPanel1.ImageIndex = 2;
-            this.propertyGridDockPanel1.Location = new System.Drawing.Point(0, 232);
+            this.propertyGridDockPanel1.Location = new System.Drawing.Point(0, 26);
             this.propertyGridDockPanel1.Name = "propertyGridDockPanel1";
-            this.propertyGridDockPanel1.OriginalSize = new System.Drawing.Size(200, 200);
-            this.propertyGridDockPanel1.Size = new System.Drawing.Size(250, 231);
+            this.propertyGridDockPanel1.OriginalSize = new System.Drawing.Size(250, 231);
+            this.propertyGridDockPanel1.Size = new System.Drawing.Size(0, 0);
             this.propertyGridDockPanel1.Text = "Property Grid";
             this.propertyGridDockPanel1.XRDesignPanel = null;
             // 
             // propertyGridDockPanel1_Container
             // 
-            this.propertyGridDockPanel1_Container.Location = new System.Drawing.Point(4, 25);
+            this.propertyGridDockPanel1_Container.Location = new System.Drawing.Point(0, 0);
             this.propertyGridDockPanel1_Container.Name = "propertyGridDockPanel1_Container";
-            this.propertyGridDockPanel1_Container.Size = new System.Drawing.Size(242, 202);
+            this.propertyGridDockPanel1_Container.Size = new System.Drawing.Size(0, 0);
             this.propertyGridDockPanel1_Container.TabIndex = 0;
             // 
             // toolBoxDockPanel1
@@ -3947,10 +3949,10 @@
             this.errorListDockPanel1.Dock = DevExpress.XtraBars.Docking.DockingStyle.Fill;
             this.errorListDockPanel1.ID = new System.Guid("5a9a01fd-6e95-4e81-a8c4-ac63153d7488");
             this.errorListDockPanel1.ImageIndex = 5;
-            this.errorListDockPanel1.Location = new System.Drawing.Point(4, 25);
+            this.errorListDockPanel1.Location = new System.Drawing.Point(0, 0);
             this.errorListDockPanel1.Name = "errorListDockPanel1";
-            this.errorListDockPanel1.OriginalSize = new System.Drawing.Size(641, 143);
-            this.errorListDockPanel1.Size = new System.Drawing.Size(1056, 143);
+            this.errorListDockPanel1.OriginalSize = new System.Drawing.Size(1056, 143);
+            this.errorListDockPanel1.Size = new System.Drawing.Size(0, 0);
             this.errorListDockPanel1.Text = "Scripts Errors";
             this.errorListDockPanel1.XRDesignPanel = null;
             // 
@@ -3958,7 +3960,7 @@
             // 
             this.errorListDockPanel1_Container.Location = new System.Drawing.Point(0, 0);
             this.errorListDockPanel1_Container.Name = "errorListDockPanel1_Container";
-            this.errorListDockPanel1_Container.Size = new System.Drawing.Size(1056, 143);
+            this.errorListDockPanel1_Container.Size = new System.Drawing.Size(0, 0);
             this.errorListDockPanel1_Container.TabIndex = 0;
             // 
             // groupAndSortDockPanel1
@@ -3967,10 +3969,10 @@
             this.groupAndSortDockPanel1.Dock = DevExpress.XtraBars.Docking.DockingStyle.Fill;
             this.groupAndSortDockPanel1.ID = new System.Guid("4bab159e-c495-4d67-87dc-f4e895da443e");
             this.groupAndSortDockPanel1.ImageIndex = 1;
-            this.groupAndSortDockPanel1.Location = new System.Drawing.Point(4, 25);
+            this.groupAndSortDockPanel1.Location = new System.Drawing.Point(0, 0);
             this.groupAndSortDockPanel1.Name = "groupAndSortDockPanel1";
-            this.groupAndSortDockPanel1.OriginalSize = new System.Drawing.Size(641, 143);
-            this.groupAndSortDockPanel1.Size = new System.Drawing.Size(1056, 143);
+            this.groupAndSortDockPanel1.OriginalSize = new System.Drawing.Size(1056, 143);
+            this.groupAndSortDockPanel1.Size = new System.Drawing.Size(0, 0);
             this.groupAndSortDockPanel1.Text = "Group and Sort";
             this.groupAndSortDockPanel1.XRDesignPanel = null;
             // 
@@ -3978,7 +3980,7 @@
             // 
             this.groupAndSortDockPanel1_Container.Location = new System.Drawing.Point(0, 0);
             this.groupAndSortDockPanel1_Container.Name = "groupAndSortDockPanel1_Container";
-            this.groupAndSortDockPanel1_Container.Size = new System.Drawing.Size(1056, 143);
+            this.groupAndSortDockPanel1_Container.Size = new System.Drawing.Size(0, 0);
             this.groupAndSortDockPanel1_Container.TabIndex = 0;
             // 
             // galleryDropDown1
@@ -4098,13 +4100,14 @@
             // 
             this.xtraTabDataManager.Name = "xtraTabDataManager";
             this.xtraTabDataManager.Size = new System.Drawing.Size(1325, 498);
-            this.xtraTabDataManager.Text = "数据展示";
+            this.xtraTabDataManager.Text = "工务数据展示";
             // 
             // xtraTabPageLGL
             // 
             this.xtraTabPageLGL.Controls.Add(this.gridControl3);
             this.xtraTabPageLGL.Controls.Add(this.panelControl4);
             this.xtraTabPageLGL.Name = "xtraTabPageLGL";
+            this.xtraTabPageLGL.PageVisible = false;
             this.xtraTabPageLGL.Size = new System.Drawing.Size(1325, 498);
             this.xtraTabPageLGL.Text = "轮轨力数据分析";
             // 
@@ -5249,18 +5252,21 @@
             // xtraTabPageMTLF
             // 
             this.xtraTabPageMTLF.Name = "xtraTabPageMTLF";
+            this.xtraTabPageMTLF.PageVisible = false;
             this.xtraTabPageMTLF.Size = new System.Drawing.Size(1325, 498);
             this.xtraTabPageMTLF.Text = "密贴离缝";
             // 
             // xtraTabPageZZJH
             // 
             this.xtraTabPageZZJH.Name = "xtraTabPageZZJH";
+            this.xtraTabPageZZJH.PageVisible = false;
             this.xtraTabPageZZJH.Size = new System.Drawing.Size(1325, 498);
             this.xtraTabPageZZJH.Text = "逐枕几何";
             // 
             // xtraTabPageXXXW
             // 
             this.xtraTabPageXXXW.Name = "xtraTabPageXXXW";
+            this.xtraTabPageXXXW.PageVisible = false;
             this.xtraTabPageXXXW.Size = new System.Drawing.Size(1325, 498);
             this.xtraTabPageXXXW.Text = "线形线位";
             // 
@@ -5476,6 +5482,7 @@
             this.DWGLanalysisBtn.TabIndex = 5;
             this.DWGLanalysisBtn.Text = "分析算法";
             this.DWGLanalysisBtn.ToolTip = "未定义";
+            this.DWGLanalysisBtn.Click += new System.EventHandler(this.DWGLanalysisBtn_Click);
             // 
             // xtraTabPageQK
             // 

+ 10 - 0
DPTools/DevFrmMain.cs

@@ -23,16 +23,21 @@ using System.Configuration;
 using System.IO;
 using Uninpho.Tools.components.SFZDH;
 using Uninpho.Tools.components.DWForm;
+using System.Runtime.InteropServices;
+
 
 namespace Uninpho.Tools
 {
+
     public partial class DevFrmMain : DevExpress.XtraBars.Ribbon.RibbonForm
     {
+        
         //使用tabletools工具
         private Tabletools tabtools = new Tabletools();
 
         public DevFrmMain()
         {
+             
             InitializeComponent();
             Config.zdhjc = true;
             DevExpress.XtraEditors.Controls.Localizer.Active = new MessboxClass();//使XtraMessageBox.Show的按钮都显示汉字
@@ -1039,5 +1044,10 @@ namespace Uninpho.Tools
             }
 
         }
+
+        private void DWGLanalysisBtn_Click(object sender, EventArgs e)
+        {
+            new DataAnalysisClass("功率", gridView4.GetSelectedRows(), ref gridControl4, ref gridView4);
+        }
     }
 }

+ 3 - 1
DPTools/Uninpho.Railway.Tools.csproj

@@ -14,6 +14,7 @@
     <TargetFrameworkProfile>
     </TargetFrameworkProfile>
     <FileAlignment>512</FileAlignment>
+    <IsWebBootstrapper>false</IsWebBootstrapper>
     <PublishUrl>publish\</PublishUrl>
     <Install>true</Install>
     <InstallFrom>Disk</InstallFrom>
@@ -26,7 +27,6 @@
     <MapFileExtensions>true</MapFileExtensions>
     <ApplicationRevision>0</ApplicationRevision>
     <ApplicationVersion>1.0.0.%2a</ApplicationVersion>
-    <IsWebBootstrapper>false</IsWebBootstrapper>
     <UseApplicationTrust>false</UseApplicationTrust>
     <BootstrapperEnabled>true</BootstrapperEnabled>
   </PropertyGroup>
@@ -246,6 +246,7 @@
     <Reference Include="System.Drawing.Design" />
     <Reference Include="System.Management" />
     <Reference Include="System.Runtime.Serialization" />
+    <Reference Include="System.Web.Extensions" />
     <Reference Include="System.Xml.Linq">
       <Private>True</Private>
     </Reference>
@@ -272,6 +273,7 @@
     </Reference>
   </ItemGroup>
   <ItemGroup>
+    <Compile Include="components\DataAnalysis\DWAnalysisAlgorithmcs.cs" />
     <Compile Include="components\DataAnalysis\DWQKCommon.cs" />
     <Compile Include="components\DataAnalysis\DWCommon.cs" />
     <Compile Include="components\DataAnalysis\DataAnalysisClass.cs" />

+ 27 - 15
DPTools/app.config

@@ -1,30 +1,42 @@
 <?xml version="1.0" encoding="utf-8"?>
 <configuration>
-<startup>
-  <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.1"/></startup>
+  <startup>
+    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.1" />
+  </startup>
   <appSettings>
-    <add key="sqssrY" value="MxYwaxN4XPqLpTL9yJI/Su5Tk9K/psFAJ1q+ezrNakU="/>
-    
-    <add key="pzConfig" value="pzConfig.ini"/>    
-    <add key="jgtpath" value="GD_JGT_01.jpg"/> 
-    
-    <add key="dbConnection" value="PORT=5432;DATABASE=jiance10;HOST=49.232.243.74;PASSWORD=UninphoSQL;USER ID=postgres"/>
+    <add key="sqssrY" value="MxYwaxN4XPqLpTL9yJI/Su5Tk9K/psFAJ1q+ezrNakU=" />
+    <add key="pzConfig" value="pzConfig.ini" />
+    <add key="jgtpath" value="GD_JGT_01.jpg" />
+    <add key="dbConnection" value="PORT=5432;DATABASE=jiance10;HOST=49.232.243.74;PASSWORD=UninphoSQL;USER ID=postgres" />
     <!--43.138.89.214 localhost MxYwaxN4XPqLpTL9yJI/Su5Tk9K/psFAJ1q+ezrNakU=-->
+    <add key="ClientSettingsProvider.ServiceUri" value="" />
   </appSettings>
   <runtime>
     <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
       <dependentAssembly>
-        <assemblyIdentity name="Npgsql" publicKeyToken="5d8b90d52f46fda7" culture="neutral"/>
-        <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0"/>
+        <assemblyIdentity name="Npgsql" publicKeyToken="5d8b90d52f46fda7" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-4.0.11.0" newVersion="4.0.11.0" />
       </dependentAssembly>
       <dependentAssembly>
-        <assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
-        <bindingRedirect oldVersion="0.0.0.0-4.0.4.1" newVersion="4.0.4.1"/>
+        <assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-4.0.4.1" newVersion="4.0.4.1" />
       </dependentAssembly>
       <dependentAssembly>
-        <assemblyIdentity name="System.Memory" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral"/>
-        <bindingRedirect oldVersion="0.0.0.0-4.0.1.1" newVersion="4.0.1.1"/>
+        <assemblyIdentity name="System.Memory" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-4.0.1.1" newVersion="4.0.1.1" />
       </dependentAssembly>
     </assemblyBinding>
   </runtime>
-</configuration>
+  <system.web>
+    <membership defaultProvider="ClientAuthenticationMembershipProvider">
+      <providers>
+        <add name="ClientAuthenticationMembershipProvider" type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" />
+      </providers>
+    </membership>
+    <roleManager defaultProvider="ClientRoleProvider" enabled="true">
+      <providers>
+        <add name="ClientRoleProvider" type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" cacheTimeout="86400" />
+      </providers>
+    </roleManager>
+  </system.web>
+</configuration>

+ 18 - 0
DPTools/components/DataAnalysis/DWAnalysisAlgorithmcs.cs

@@ -0,0 +1,18 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Runtime.InteropServices;
+
+namespace Uninpho.Tools.components.DataAnalysis
+{
+    class DWAnalysisAlgorithmcs
+    {
+        [DllImport("sub_module_power_analysis.dll")]
+        public static extern void EC_ClosePort(uint hdl_port);
+
+
+
+    }
+}

+ 75 - 33
DPTools/components/DataAnalysis/DataAnalysisClass.cs

@@ -54,7 +54,7 @@ namespace Uninpho.Tools.components.DataAnalysis
             if (iszhengc)
             {
                 bool boo = true;
-                if (type != "微小")
+                if (type != "微小" && type != "功率")
                 {
                     SuanFaFrom frm = new SuanFaFrom();
                     frm.StartPosition = FormStartPosition.CenterParent;
@@ -83,54 +83,96 @@ namespace Uninpho.Tools.components.DataAnalysis
             }
             else
             {
-                for (int i = 0; i < selectrow.Length; i++)
+                if (type == "功率")
                 {
-                    var a = GV.GetRowCellValue(selectrow[i], "Rwzt").ToString();
-                    if (GV.GetRowCellValue(selectrow[i], "Wjzt").ToString().Trim() != "正常")
+                    for (int i = 0; i < selectrow.Length; i++)
                     {
-                        XtraMessageBox.Show("存在文件状态异常文件,请检查后再执行算法!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
-                        iszhengc = false;
-                        break;
-                    }
-                    else if (GV.GetRowCellValue(selectrow[i], "Jccxx").ToString() == " " || GV.GetRowCellValue(selectrow[i], "Jccxx").ToString() == "")
-                    {
-                        XtraMessageBox.Show("没有选定检测车信息,请检查!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
-                        iszhengc = false;
-                        break;
+                        var a = GV.GetRowCellValue(selectrow[i], "Taskstatus").ToString();
+                        if (GV.GetRowCellValue(selectrow[i], "Filestatus").ToString().Trim() != "正常")
+                        {
+                            XtraMessageBox.Show("存在文件状态异常文件,请检查后再执行算法!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            iszhengc = false;
+                            break;
+                        }               
+                        else if (GV.GetRowCellValue(selectrow[i], "Taskstatus").ToString() == type + "算法执行完毕" || GV.GetRowCellValue(selectrow[i], "Taskstatus").ToString() == "算法执行失败")
+                        {
+                           
+                                if (b)
+                                {
+                                    if (XtraMessageBox.Show(type + "算法已执行,是否重新执行?", "提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question) != DialogResult.OK)
+                                    {
+                                        iszhengc = false;
+                                        break;
+                                    }
+                                    else
+                                    {
+                                        b = false;
+                                    }
+                                }
+
+                                DataAnalysisToPG.DelUpdataData(GV.GetRowCellValue(selectrow[i], "Id").ToString(), type);
+                        
+                        }
+                        else if (GV.GetRowCellValue(selectrow[i], "Rwzt").ToString() == "算法未执行" && type == "微小")
+                        {
+                            XtraMessageBox.Show("请先执行几何算法!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            iszhengc = false;
+                            break;
+                        }
                     }
-                    else if (GV.GetRowCellValue(selectrow[i], "Rwzt").ToString() == type + "算法执行完毕" || GV.GetRowCellValue(selectrow[i], "Rwzt").ToString() == "算法执行失败")
+                }
+                else
+                {
+                    for (int i = 0; i < selectrow.Length; i++)
                     {
-                        if (type != "微小")
+                        var a = GV.GetRowCellValue(selectrow[i], "Rwzt").ToString();
+                        if (GV.GetRowCellValue(selectrow[i], "Wjzt").ToString().Trim() != "正常")
+                        {
+                            XtraMessageBox.Show("存在文件状态异常文件,请检查后再执行算法!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            iszhengc = false;
+                            break;
+                        }
+                        else if (GV.GetRowCellValue(selectrow[i], "Jccxx").ToString() == " " || GV.GetRowCellValue(selectrow[i], "Jccxx").ToString() == "")
+                        {
+                            XtraMessageBox.Show("没有选定检测车信息,请检查!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            iszhengc = false;
+                            break;
+                        }
+                        else if (GV.GetRowCellValue(selectrow[i], "Rwzt").ToString() == type + "算法执行完毕" || GV.GetRowCellValue(selectrow[i], "Rwzt").ToString() == "算法执行失败")
                         {
-                            if (b)
+                            if (type != "微小")
                             {
-                                if (XtraMessageBox.Show(type + "算法已执行,是否重新执行?", "提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question) != DialogResult.OK)
-                                {
-                                    iszhengc = false;
-                                    break;
-                                }
-                                else
+                                if (b)
                                 {
-                                    b = false;
+                                    if (XtraMessageBox.Show(type + "算法已执行,是否重新执行?", "提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question) != DialogResult.OK)
+                                    {
+                                        iszhengc = false;
+                                        break;
+                                    }
+                                    else
+                                    {
+                                        b = false;
+                                    }
                                 }
-                            }
 
-                            DataAnalysisToPG.DelUpdataData(GV.GetRowCellValue(selectrow[i], "Id").ToString(), type);
+                                DataAnalysisToPG.DelUpdataData(GV.GetRowCellValue(selectrow[i], "Id").ToString(), type);
+                            }
+                            else
+                            {
+                                XtraMessageBox.Show("微小算法不能重新执行", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                                iszhengc = false;
+                                break;
+                            }
                         }
-                        else
+                        else if (GV.GetRowCellValue(selectrow[i], "Rwzt").ToString() == "算法未执行" && type == "微小")
                         {
-                            XtraMessageBox.Show("微小算法不能重新执行", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            XtraMessageBox.Show("请先执行几何算法!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
                             iszhengc = false;
                             break;
                         }
                     }
-                    else if (GV.GetRowCellValue(selectrow[i], "Rwzt").ToString() == "算法未执行" && type == "微小")
-                    {
-                        XtraMessageBox.Show("请先执行几何算法!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
-                        iszhengc = false;
-                        break; 
-                    }
                 }
+               
             }
         }
 

+ 6 - 0
Uninpho.DBOperation/Operation/DataAnalysisToPG.cs

@@ -386,6 +386,12 @@ namespace Uninpho.DBOperation.Operation
                 DelToPGJHBX(whichupdata);
                 DelToPGJH(file);
             }
+            //else if (type == "功率")
+            //{
+            //    List<T_dwfile_account> whichupdata = (List<T_dwfile_account>)QueryToPGByName(yswjm);
+            //    DelToPGJHBX(whichupdata);
+            //    DelToPGJH(file);
+            //}
         }
         /// <summary>
         /// 删除数据 by ID