From 82d20fd04c850b1d640dc2144bb51764146047c1 Mon Sep 17 00:00:00 2001
From: lu <123456>
Date: 星期三, 29 十月 2025 14:33:29 +0800
Subject: [PATCH] 物料属性设置

---
 DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.cs          |   13 ++++--
 DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.Designer.cs |   86 +++++++++++++++++++++++-------------------
 2 files changed, 55 insertions(+), 44 deletions(-)

diff --git a/DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.Designer.cs b/DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.Designer.cs
index acd2ddc..9108710 100644
--- a/DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.Designer.cs
+++ b/DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.Designer.cs
@@ -30,28 +30,30 @@
         {
             System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Frm_MesItemsShow));
             this.panel1 = new System.Windows.Forms.Panel();
+            this.txt_day = new DevExpress.XtraEditors.TextEdit();
+            this.txt_bz09 = new DevExpress.XtraEditors.TextEdit();
+            this.labelControl3 = new DevExpress.XtraEditors.LabelControl();
             this.txt_lossPercent = new DevExpress.XtraEditors.TextEdit();
             this.labelControl2 = new DevExpress.XtraEditors.LabelControl();
-            this.txt_day = new System.Windows.Forms.NumericUpDown();
             this.btnCancel = new DevExpress.XtraEditors.SimpleButton();
             this.btnSave = new DevExpress.XtraEditors.SimpleButton();
             this.labelControl1 = new DevExpress.XtraEditors.LabelControl();
-            this.labelControl3 = new DevExpress.XtraEditors.LabelControl();
-            this.txt_bz09 = new System.Windows.Forms.NumericUpDown();
+            this.labelControl4 = new DevExpress.XtraEditors.LabelControl();
             this.panel1.SuspendLayout();
+            ((System.ComponentModel.ISupportInitialize)(this.txt_day.Properties)).BeginInit();
+            ((System.ComponentModel.ISupportInitialize)(this.txt_bz09.Properties)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.txt_lossPercent.Properties)).BeginInit();
-            ((System.ComponentModel.ISupportInitialize)(this.txt_day)).BeginInit();
-            ((System.ComponentModel.ISupportInitialize)(this.txt_bz09)).BeginInit();
             this.SuspendLayout();
             // 
             // panel1
             // 
             this.panel1.BackColor = System.Drawing.Color.White;
+            this.panel1.Controls.Add(this.labelControl4);
+            this.panel1.Controls.Add(this.txt_day);
             this.panel1.Controls.Add(this.txt_bz09);
             this.panel1.Controls.Add(this.labelControl3);
             this.panel1.Controls.Add(this.txt_lossPercent);
             this.panel1.Controls.Add(this.labelControl2);
-            this.panel1.Controls.Add(this.txt_day);
             this.panel1.Controls.Add(this.btnCancel);
             this.panel1.Controls.Add(this.btnSave);
             this.panel1.Controls.Add(this.labelControl1);
@@ -60,28 +62,43 @@
             this.panel1.Size = new System.Drawing.Size(360, 222);
             this.panel1.TabIndex = 3;
             // 
+            // txt_day
+            // 
+            this.txt_day.Location = new System.Drawing.Point(205, 53);
+            this.txt_day.Name = "txt_day";
+            this.txt_day.Size = new System.Drawing.Size(120, 24);
+            this.txt_day.TabIndex = 250;
+            // 
+            // txt_bz09
+            // 
+            this.txt_bz09.Location = new System.Drawing.Point(205, 129);
+            this.txt_bz09.Name = "txt_bz09";
+            this.txt_bz09.Size = new System.Drawing.Size(120, 24);
+            this.txt_bz09.TabIndex = 249;
+            // 
+            // labelControl3
+            // 
+            this.labelControl3.Location = new System.Drawing.Point(18, 132);
+            this.labelControl3.Name = "labelControl3";
+            this.labelControl3.Size = new System.Drawing.Size(174, 18);
+            this.labelControl3.TabIndex = 248;
+            this.labelControl3.Text = "IQC绉伴噸(1寮哄埗绉伴噸0鍚�)锛�";
+            // 
             // txt_lossPercent
             // 
-            this.txt_lossPercent.Location = new System.Drawing.Point(205, 81);
-            this.txt_lossPercent.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
+            this.txt_lossPercent.Location = new System.Drawing.Point(205, 91);
+            this.txt_lossPercent.Margin = new System.Windows.Forms.Padding(2);
             this.txt_lossPercent.Name = "txt_lossPercent";
             this.txt_lossPercent.Size = new System.Drawing.Size(120, 24);
             this.txt_lossPercent.TabIndex = 247;
             // 
             // labelControl2
             // 
-            this.labelControl2.Location = new System.Drawing.Point(117, 87);
+            this.labelControl2.Location = new System.Drawing.Point(117, 94);
             this.labelControl2.Name = "labelControl2";
             this.labelControl2.Size = new System.Drawing.Size(75, 18);
             this.labelControl2.TabIndex = 246;
             this.labelControl2.Text = "瓒呴噰姣斾緥锛�";
-            // 
-            // txt_day
-            // 
-            this.txt_day.Location = new System.Drawing.Point(205, 40);
-            this.txt_day.Name = "txt_day";
-            this.txt_day.Size = new System.Drawing.Size(120, 26);
-            this.txt_day.TabIndex = 245;
             // 
             // btnCancel
             // 
@@ -111,31 +128,21 @@
             // 
             // labelControl1
             // 
-            this.labelControl1.Location = new System.Drawing.Point(87, 47);
+            this.labelControl1.Location = new System.Drawing.Point(87, 56);
             this.labelControl1.Name = "labelControl1";
             this.labelControl1.Size = new System.Drawing.Size(105, 18);
             this.labelControl1.TabIndex = 242;
             this.labelControl1.Text = "鎻愬墠鍒拌揣澶╂暟锛�";
             // 
-            // labelControl3
+            // labelControl4
             // 
-            this.labelControl3.Location = new System.Drawing.Point(18, 127);
-            this.labelControl3.Name = "labelControl3";
-            this.labelControl3.Size = new System.Drawing.Size(174, 18);
-            this.labelControl3.TabIndex = 248;
-            this.labelControl3.Text = "IQC绉伴噸(1寮哄埗绉伴噸0鍚�)锛�";
-            // 
-            // txt_bz09
-            // 
-            this.txt_bz09.Location = new System.Drawing.Point(205, 119);
-            this.txt_bz09.Maximum = new decimal(new int[] {
-            1,
-            0,
-            0,
-            0});
-            this.txt_bz09.Name = "txt_bz09";
-            this.txt_bz09.Size = new System.Drawing.Size(120, 26);
-            this.txt_bz09.TabIndex = 249;
+            this.labelControl4.Appearance.ForeColor = System.Drawing.Color.Gray;
+            this.labelControl4.Appearance.Options.UseForeColor = true;
+            this.labelControl4.Location = new System.Drawing.Point(18, 13);
+            this.labelControl4.Name = "labelControl4";
+            this.labelControl4.Size = new System.Drawing.Size(240, 18);
+            this.labelControl4.TabIndex = 251;
+            this.labelControl4.Text = "璇峰~鍐欑浉鍏虫暟鍊硷紝涓虹┖灏嗚烦杩囩浉鍏抽」";
             // 
             // Frm_MesItemsShow
             // 
@@ -151,9 +158,9 @@
             this.Text = "Frm_MesItemsShow";
             this.panel1.ResumeLayout(false);
             this.panel1.PerformLayout();
+            ((System.ComponentModel.ISupportInitialize)(this.txt_day.Properties)).EndInit();
+            ((System.ComponentModel.ISupportInitialize)(this.txt_bz09.Properties)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.txt_lossPercent.Properties)).EndInit();
-            ((System.ComponentModel.ISupportInitialize)(this.txt_day)).EndInit();
-            ((System.ComponentModel.ISupportInitialize)(this.txt_bz09)).EndInit();
             this.ResumeLayout(false);
 
         }
@@ -161,13 +168,14 @@
         #endregion
 
         private System.Windows.Forms.Panel panel1;
-        private System.Windows.Forms.NumericUpDown txt_day;
         private DevExpress.XtraEditors.SimpleButton btnCancel;
         private DevExpress.XtraEditors.SimpleButton btnSave;
         private DevExpress.XtraEditors.LabelControl labelControl1;
         private DevExpress.XtraEditors.TextEdit txt_lossPercent;
         private DevExpress.XtraEditors.LabelControl labelControl2;
         private DevExpress.XtraEditors.LabelControl labelControl3;
-        private System.Windows.Forms.NumericUpDown txt_bz09;
+        private DevExpress.XtraEditors.TextEdit txt_bz09;
+        private DevExpress.XtraEditors.TextEdit txt_day;
+        private DevExpress.XtraEditors.LabelControl labelControl4;
     }
 }
\ No newline at end of file
diff --git a/DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.cs b/DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.cs
index cf48216..56b6cf3 100644
--- a/DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.cs
+++ b/DevApp/Gs.DevApp/DevFrm/BasicData/Frm_MesItemsShow.cs
@@ -38,7 +38,7 @@
                     txt_lossPercent.Focus();
                     return false;
                 }
-                
+
                 // 鏍煎紡鍖栨樉绀猴紝淇濈暀閫傚綋鐨勫皬鏁颁綅鏁�
                 txt_lossPercent.EditValue = Math.Round(value, 4);
                 return true;
@@ -54,17 +54,20 @@
 
         private void BtnSave_Click(object sender, EventArgs e)
         {
+            string _bz10 = txt_day.Text;
+            string _percent = txt_lossPercent.Text;
+            string _bz09 = txt_bz09.Text;
             // 淇濆瓨鍓嶉獙璇佽秴閲囩巼
-            if (!ValidateLossPercent())
+            if (!string.IsNullOrEmpty(_percent) && !ValidateLossPercent())
             {
                 return;
             }
             var _obj = new
             {
                 guidList = this.guidList,
-                bz10 = txt_day.Value,//鎻愬墠鍒拌揣澶╂暟
-                percent = txt_lossPercent.EditValue,
-                bz09= txt_bz09.Value,//鍚庢潵鏀逛负iqc绉伴噸灞炴��1瑕佺О閲�0涓嶇О閲�
+                bz10 = _bz10,//鎻愬墠鍒拌揣澶╂暟
+                percent = _percent,
+                bz09 = _bz09,//鍚庢潵鏀逛负iqc绉伴噸灞炴��1瑕佺О閲�0涓嶇О閲�
             };
             try
             {

--
Gitblit v1.9.3