From a42944f15dcef1b5b27795801de87dceef7d9904 Mon Sep 17 00:00:00 2001 From: wangsr Date: Tue, 22 Aug 2023 17:35:23 +0800 Subject: [PATCH] =?UTF-8?q?change=20-=20=E6=A6=84=E8=8F=8A=E8=AE=BE?= =?UTF-8?q?=E5=A4=87=E5=8F=82=E6=95=B0=E5=8E=8B=E5=8A=9B=E7=AE=A1=E7=90=86?= =?UTF-8?q?=20partchange?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../LjMaterial/MaterialInfoTypeHelp.cs | 2 +- .../LjPressure/FrmPressureUpdate.Designer.cs | 4 +--- .../LjPressure/FrmPressureUpdate.cs | 12 +++++++----- .../LjPressure/InitDbAction.cs | 2 +- .../LjPressure/UpAction.cs | 2 +- Main/MCEdit/Data/MCProject/nodeDevice.xml | 18 +++++++++--------- .../MCProject/nodeForm/FormPressureSetting.xml | 2 +- 7 files changed, 21 insertions(+), 21 deletions(-) diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMaterial/MaterialInfoTypeHelp.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMaterial/MaterialInfoTypeHelp.cs index 71bff69..ef7f49c 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMaterial/MaterialInfoTypeHelp.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMaterial/MaterialInfoTypeHelp.cs @@ -17,7 +17,7 @@ namespace Mesnac.Action.ChemicalWeighing.LjMaterial public class MyNameValueStr { - public String Id { get; set; } + public string Id { get; set; } public string Name { get; set; } } diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/FrmPressureUpdate.Designer.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/FrmPressureUpdate.Designer.cs index 7f9ba6d..b065df0 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/FrmPressureUpdate.Designer.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/FrmPressureUpdate.Designer.cs @@ -45,18 +45,15 @@ namespace Mesnac.Action.ChemicalWeighing.LjPressure // // HighLimit // - this.HighLimit.Enabled = false; this.HighLimit.Location = new System.Drawing.Point(108, 58); this.HighLimit.Margin = new System.Windows.Forms.Padding(5); this.HighLimit.MaxLength = 100; this.HighLimit.Name = "HighLimit"; this.HighLimit.Size = new System.Drawing.Size(129, 21); this.HighLimit.TabIndex = 47; - this.HighLimit.TextChanged += new System.EventHandler(this.HighLimit_TextChanged); // // LowLimit // - this.LowLimit.Enabled = false; this.LowLimit.Location = new System.Drawing.Point(108, 27); this.LowLimit.Margin = new System.Windows.Forms.Padding(5); this.LowLimit.MaxLength = 100; @@ -139,6 +136,7 @@ namespace Mesnac.Action.ChemicalWeighing.LjPressure this.Controls.Add(this.label4); this.Controls.Add(this.label3); this.Controls.Add(this.label1); + this.ForeColor = System.Drawing.SystemColors.ControlText; this.Name = "FrmPressureUpdate"; this.Text = "需改压力参数"; this.ResumeLayout(false); diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/FrmPressureUpdate.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/FrmPressureUpdate.cs index 9f5be01..b6d9fc8 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/FrmPressureUpdate.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/FrmPressureUpdate.cs @@ -85,23 +85,25 @@ namespace Mesnac.Action.ChemicalWeighing.LjPressure PressureSettingView view = new PressureSettingView() { + Id = _id, HighLimit = b, LowLimit = a, Alarm = Convert.ToInt16(Alarm.SelectedValue) }; - + PressurePLC.DownToPlc(new List() { view }); - + + string sql = + $"update PressureSetting set LowLimit={view.LowLimit},HighLimit={view.HighLimit} where Id={view.Id}"; + DBHelp.ExecuteNonQuery(sql); + this.DialogResult = System.Windows.Forms.DialogResult.OK; } - private void HighLimit_TextChanged(object sender, EventArgs e) - { - } } } \ No newline at end of file diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/InitDbAction.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/InitDbAction.cs index e525b88..dc8cce5 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/InitDbAction.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/InitDbAction.cs @@ -47,7 +47,7 @@ namespace Mesnac.Action.ChemicalWeighing.LjPressure } else { - ICSharpCode.Core.LoggingService.Warn("刷新物料信息失败:物料数据控件为Null..."); + ICSharpCode.Core.LoggingService.Warn("刷新物料信息失败:压力数据控件为Null..."); } } diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/UpAction.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/UpAction.cs index 0a12ae8..07b500d 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/UpAction.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPressure/UpAction.cs @@ -34,7 +34,7 @@ namespace Mesnac.Action.ChemicalWeighing.LjPressure foreach (var v in pressureSettingViews) { string sql = - $"update PressureSetting set LowLimit={v.LowLimit},HighLimit={v.LowLimit} where Id={v.Id}"; + $"update PressureSetting set LowLimit={v.LowLimit},HighLimit={v.HighLimit} where Id={v.Id}"; DBHelp.ExecuteNonQuery(sql); } diff --git a/Main/MCEdit/Data/MCProject/nodeDevice.xml b/Main/MCEdit/Data/MCProject/nodeDevice.xml index d441d65..06f5760 100644 --- a/Main/MCEdit/Data/MCProject/nodeDevice.xml +++ b/Main/MCEdit/Data/MCProject/nodeDevice.xml @@ -13,7 +13,7 @@ - + @@ -758,7 +758,7 @@ - + @@ -2610,7 +2610,7 @@ - + @@ -3758,7 +3758,7 @@ - + @@ -4987,7 +4987,7 @@ - + @@ -5867,7 +5867,7 @@ - + @@ -6147,7 +6147,7 @@ - + @@ -6429,7 +6429,7 @@ - + @@ -7665,7 +7665,7 @@ - + diff --git a/Main/MCEdit/Data/MCProject/nodeForm/FormPressureSetting.xml b/Main/MCEdit/Data/MCProject/nodeForm/FormPressureSetting.xml index 7256059..3519525 100644 --- a/Main/MCEdit/Data/MCProject/nodeForm/FormPressureSetting.xml +++ b/Main/MCEdit/Data/MCProject/nodeForm/FormPressureSetting.xml @@ -3,7 +3,7 @@ False - AAEAAAD/////AQAAAAAAAAAMAgAAAEtNZXNuYWMuQ29udHJvbHMuQmFzZSwgVmVyc2lvbj0xLjAuMC4wLCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPW51bGwEAQAAAJoBU3lzdGVtLkNvbGxlY3Rpb25zLkdlbmVyaWMuTGlzdGAxW1tNZXNuYWMuQ29udHJvbHMuQmFzZS5EYXRhR3JpZFZpZXdDb2x1bW5zLCBNZXNuYWMuQ29udHJvbHMuQmFzZSwgVmVyc2lvbj0xLjAuMC4wLCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPW51bGxdXQMAAAAGX2l0ZW1zBV9zaXplCF92ZXJzaW9uBAAAKk1lc25hYy5Db250cm9scy5CYXNlLkRhdGFHcmlkVmlld0NvbHVtbnNbXQIAAAAICAkDAAAABQAAAHwAAAAHAwAAAAABAAAACAAAAAQoTWVzbmFjLkNvbnRyb2xzLkJhc2UuRGF0YUdyaWRWaWV3Q29sdW1ucwIAAAAJBAAAAAkFAAAACQYAAAAJBwAAAAkIAAAADQMFBAAAAChNZXNuYWMuQ29udHJvbHMuQmFzZS5EYXRhR3JpZFZpZXdDb2x1bW5zAgAAAApfZmlsZWREYXRhDF9kaXNwbGF5TmFtZQEBAgAAAAYJAAAAAklkBgoAAAAG57yW5Y+3AQUAAAAEAAAABgsAAAAETmF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