Эх сурвалжийг харах

栈板号箱号显示问题修改

callm 1 өдөр өмнө
parent
commit
e1624fc022

+ 1 - 0
UAS_MES_HYSX/FunctionCode/Packing/Packing_PackageCollectionZX.cs

@@ -193,6 +193,7 @@ namespace UAS_MES_NEW.Packing
             //加载Grid数据
             dt = (DataTable)dh.ExecuteSql("select pa_outboxcode,pa_prodcode,pd_barcode,pd_innerqty,pd_makecode,pa_indate from packageDetail left join package on pa_id=pd_paid where pa_outboxcode='" + pa_outboxcode.Text + "'", "select");
             BaseUtil.FillDgvWithDataTable(PackageDetail, dt);
+            PackageDetail.FirstDisplayedScrollingRowIndex = PackageDetail.RowCount - 1;
             if (dt.Rows.Count > 0)
             {
                 string choose_pd_barcode = dt.Rows[0]["pd_barcode"].ToString();

+ 60 - 61
UAS_MES_HYSX/FunctionCode/Packing/Packing_PalletCollectionZX.Designer.cs

@@ -63,6 +63,12 @@
             this.NewPalletCode = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
             this.pa_custcode = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
             this.PackageInf = new UAS_MES_NEW.CustomControl.DataGrid_View.DataGridViewWithSerialNum();
+            this.pd_outboxcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pazxcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_innerqty = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.Column3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.Column4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.Column5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.pa_makecode = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
             this.pa_totalqty = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
             this.AutoPrint = new UAS_MES_NEW.CustomControl.CustomCheckBox.AutoPrintCheckBox();
@@ -78,12 +84,6 @@
             this.label7 = new System.Windows.Forms.Label();
             this.PrintList1 = new UAS_MES_NEW.CustomControl.ComBoxWithFocus.PrinterCombox();
             this.label8 = new System.Windows.Forms.Label();
-            this.pd_outboxcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pazxcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pd_innerqty = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.Column3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.Column4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.Column5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             ((System.ComponentModel.ISupportInitialize)(this.PackageInf)).BeginInit();
             this.SuspendLayout();
             // 
@@ -313,7 +313,6 @@
             // 
             this.PrintNum.AllPower = null;
             this.PrintNum.BackColor = System.Drawing.Color.White;
-            this.PrintNum.Enabled = false;
             this.PrintNum.ID = null;
             this.PrintNum.Location = new System.Drawing.Point(1688, 234);
             this.PrintNum.Margin = new System.Windows.Forms.Padding(6);
@@ -520,6 +519,60 @@
             this.PackageInf.Size = new System.Drawing.Size(1412, 830);
             this.PackageInf.TabIndex = 156;
             // 
+            // pd_outboxcode
+            // 
+            this.pd_outboxcode.DataPropertyName = "code";
+            this.pd_outboxcode.HeaderText = "MES箱号";
+            this.pd_outboxcode.MinimumWidth = 200;
+            this.pd_outboxcode.Name = "pd_outboxcode";
+            this.pd_outboxcode.ReadOnly = true;
+            this.pd_outboxcode.Width = 200;
+            // 
+            // pazxcode
+            // 
+            this.pazxcode.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.AllCellsExceptHeader;
+            this.pazxcode.DataPropertyName = "pazxcode";
+            this.pazxcode.HeaderText = "中兴箱号";
+            this.pazxcode.MinimumWidth = 200;
+            this.pazxcode.Name = "pazxcode";
+            this.pazxcode.Width = 200;
+            // 
+            // pd_innerqty
+            // 
+            this.pd_innerqty.DataPropertyName = "pd_innerqty";
+            this.pd_innerqty.HeaderText = "数量";
+            this.pd_innerqty.MinimumWidth = 70;
+            this.pd_innerqty.Name = "pd_innerqty";
+            this.pd_innerqty.ReadOnly = true;
+            this.pd_innerqty.Width = 70;
+            // 
+            // Column3
+            // 
+            this.Column3.DataPropertyName = "pd_prodcode";
+            this.Column3.HeaderText = "产品编号";
+            this.Column3.MinimumWidth = 150;
+            this.Column3.Name = "Column3";
+            this.Column3.ReadOnly = true;
+            this.Column3.Width = 150;
+            // 
+            // Column4
+            // 
+            this.Column4.DataPropertyName = "pd_makecode";
+            this.Column4.HeaderText = "工单号";
+            this.Column4.MinimumWidth = 150;
+            this.Column4.Name = "Column4";
+            this.Column4.ReadOnly = true;
+            this.Column4.Width = 150;
+            // 
+            // Column5
+            // 
+            this.Column5.DataPropertyName = "pa_salecode";
+            this.Column5.HeaderText = "合同";
+            this.Column5.MinimumWidth = 150;
+            this.Column5.Name = "Column5";
+            this.Column5.ReadOnly = true;
+            this.Column5.Width = 150;
+            // 
             // pa_makecode
             // 
             this.pa_makecode.AutoSize = true;
@@ -705,60 +758,6 @@
             this.label8.TabIndex = 214;
             this.label8.Text = "打印机1";
             // 
-            // pd_outboxcode
-            // 
-            this.pd_outboxcode.DataPropertyName = "code";
-            this.pd_outboxcode.HeaderText = "MES箱号";
-            this.pd_outboxcode.MinimumWidth = 200;
-            this.pd_outboxcode.Name = "pd_outboxcode";
-            this.pd_outboxcode.ReadOnly = true;
-            this.pd_outboxcode.Width = 200;
-            // 
-            // pazxcode
-            // 
-            this.pazxcode.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.AllCellsExceptHeader;
-            this.pazxcode.DataPropertyName = "pazxcode";
-            this.pazxcode.HeaderText = "中兴箱号";
-            this.pazxcode.MinimumWidth = 200;
-            this.pazxcode.Name = "pazxcode";
-            this.pazxcode.Width = 200;
-            // 
-            // pd_innerqty
-            // 
-            this.pd_innerqty.DataPropertyName = "pd_innerqty";
-            this.pd_innerqty.HeaderText = "数量";
-            this.pd_innerqty.MinimumWidth = 70;
-            this.pd_innerqty.Name = "pd_innerqty";
-            this.pd_innerqty.ReadOnly = true;
-            this.pd_innerqty.Width = 70;
-            // 
-            // Column3
-            // 
-            this.Column3.DataPropertyName = "pd_prodcode";
-            this.Column3.HeaderText = "产品编号";
-            this.Column3.MinimumWidth = 150;
-            this.Column3.Name = "Column3";
-            this.Column3.ReadOnly = true;
-            this.Column3.Width = 150;
-            // 
-            // Column4
-            // 
-            this.Column4.DataPropertyName = "pd_makecode";
-            this.Column4.HeaderText = "工单号";
-            this.Column4.MinimumWidth = 150;
-            this.Column4.Name = "Column4";
-            this.Column4.ReadOnly = true;
-            this.Column4.Width = 150;
-            // 
-            // Column5
-            // 
-            this.Column5.DataPropertyName = "pa_salecode";
-            this.Column5.HeaderText = "合同";
-            this.Column5.MinimumWidth = 150;
-            this.Column5.Name = "Column5";
-            this.Column5.ReadOnly = true;
-            this.Column5.Width = 150;
-            // 
             // Packing_PalletCollectionZX
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(12F, 24F);

+ 9 - 2
UAS_MES_HYSX/FunctionCode/Packing/Packing_PalletCollectionZX.cs

@@ -75,6 +75,7 @@ namespace UAS_MES_NEW.Packing
             StepCount.LineCode = User.UserLineCode;
             StepCount.Dh = dh;
             StepCount.Start();
+
         }
 
         private void Clean_Click(object sender, EventArgs e)
@@ -140,6 +141,11 @@ namespace UAS_MES_NEW.Packing
                     {
                         BaseUtil.SetFormValue(this.Controls, dt);
                         pa_makecode.Text = dt.Rows[0]["pd_makecode"].ToString();
+                        if (!CheckBoxNum())
+                        {
+                            OperateResult.AppendText(">>采集箱号" + outboxcode.Text + "不连续\n", Color.Red, outboxcode);
+                            return;
+                        }
                         if (dt.Rows[0]["pa_downstatus"].ToString() != "0")
                         {
                             OperateResult.AppendText(">>箱号" + outboxcode.Text + "下地状态不允许采集\n", Color.Red, outboxcode);
@@ -393,6 +399,7 @@ namespace UAS_MES_NEW.Packing
                 dh.ExecuteSql("update package set pa_checkno='',pa_prodcode='',pa_packtype='',pa_salecode='',pa_makecode='',pa_packageqty=0,pa_totalqty=0,pa_currentqty=0,pa_status=0 where pa_outboxcode='" + pa_outboxcode.Text + "'", "update");
             }
             BaseUtil.FillDgvWithDataTable(PackageInf, dt);
+            PackageInf.FirstDisplayedScrollingRowIndex = PackageInf.RowCount - 1;
         }
 
         private void FillPrintLabel()
@@ -491,12 +498,12 @@ namespace UAS_MES_NEW.Packing
             int currentnum = 0;
             if (maxbox != "")
             {
-                maxnum = int.Parse(maxbox.Substring(maxbox.Length-4));
+                maxnum = int.Parse(maxbox.Substring(maxbox.Length - 4));
             }
             string currentbox = dh.getFieldDataByCondition("package", "(pa_zxcode)", "pa_outboxcode='" + outboxcode.Text + "'").ToString();
             if (currentbox != "")
             {
-                currentnum = int.Parse(currentbox.Substring(currentbox.Length-4));
+                currentnum = int.Parse(currentbox.Substring(currentbox.Length - 4));
             }
             if ((maxnum + 1) == currentnum)
             {

+ 5 - 5
UAS_MES_HYSX/FunctionCode/Packing/Packing_PalletCollectionZX.resx

@@ -177,7 +177,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDwAACw8BkvkDpQAACdNJREFUeF7t3dtOW4cW
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDgAACw4BQL7hQQAACdNJREFUeF7t3dtOW4cW
         heFe9VUibakv1/eoVGk/TFedps2hnCGAjTnYnAlgbGNzJpUqza2xgL2zmSlL4oqV8V98Fx2q190/YxwC
         30XEdwA8pQGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMNAHykAYCPNADwkQYAPtIAwEcaAPhIAwAfaQDg
         Iw0AfKQBgI80APCRBgA+0gDARxoA+EgDAB9pAOAjDQB8pAGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMN
@@ -308,7 +308,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDwAACw8BkvkDpQAACdNJREFUeF7t3dtOW4cW
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDgAACw4BQL7hQQAACdNJREFUeF7t3dtOW4cW
         heFe9VUibakv1/eoVGk/TFedps2hnCGAjTnYnAlgbGNzJpUqza2xgL2zmSlL4oqV8V98Fx2q190/YxwC
         30XEdwA8pQGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMNAHykAYCPNADwkQYAPtIAwEcaAPhIAwAfaQDg
         Iw0AfKQBgI80APCRBgA+0gDARxoA+EgDAB9pAOAjDQB8pAGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMN
@@ -439,7 +439,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDwAACw8BkvkDpQAACdNJREFUeF7t3dtOW4cW
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDgAACw4BQL7hQQAACdNJREFUeF7t3dtOW4cW
         heFe9VUibakv1/eoVGk/TFedps2hnCGAjTnYnAlgbGNzJpUqza2xgL2zmSlL4oqV8V98Fx2q190/YxwC
         30XEdwA8pQGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMNAHykAYCPNADwkQYAPtIAwEcaAPhIAwAfaQDg
         Iw0AfKQBgI80APCRBgA+0gDARxoA+EgDAB9pAOAjDQB8pAGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMN
@@ -570,7 +570,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDwAACw8BkvkDpQAACdNJREFUeF7t3dtOW4cW
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDgAACw4BQL7hQQAACdNJREFUeF7t3dtOW4cW
         heFe9VUibakv1/eoVGk/TFedps2hnCGAjTnYnAlgbGNzJpUqza2xgL2zmSlL4oqV8V98Fx2q190/YxwC
         30XEdwA8pQGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMNAHykAYCPNADwkQYAPtIAwEcaAPhIAwAfaQDg
         Iw0AfKQBgI80APCRBgA+0gDARxoA+EgDAB9pAOAjDQB8pAGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMN
@@ -701,7 +701,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDwAACw8BkvkDpQAACdNJREFUeF7t3dtOW4cW
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDgAACw4BQL7hQQAACdNJREFUeF7t3dtOW4cW
         heFe9VUibakv1/eoVGk/TFedps2hnCGAjTnYnAlgbGNzJpUqza2xgL2zmSlL4oqV8V98Fx2q190/YxwC
         30XEdwA8pQGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMNAHykAYCPNADwkQYAPtIAwEcaAPhIAwAfaQDg
         Iw0AfKQBgI80APCRBgA+0gDARxoA+EgDAB9pAOAjDQB8pAGAjzQA8JEGAD7SAMBHGgD4SAMAH2kA4CMN