章政 6 gadi atpakaļ
vecāks
revīzija
932e668cea

+ 352 - 352
UAS-出货标签管理(泽天)/UAS_出货标签管理.Designer.cs

@@ -91,17 +91,6 @@
             this.ProcessCount = new System.Windows.Forms.Label();
             this.DCCheck = new UAS_LabelMachine.CustomControl.EnterTextBox();
             this.GridPrcode = new UAS_LabelMachine.CustomControl.DataGridViewWithSerialNum();
-            this.pd_pdno = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pjd_id = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pd_prodcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pd_whcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.CollectedNum = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.UnCollectedNum = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pd_outqty = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pr_unit = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pd_brand = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pjd_zxbzs_user = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.groupBoxWithBorder1 = new UAS_LabelMachine.CustomControl.GroupBoxWithBorder.GroupBoxWithBorder();
             this.label18 = new System.Windows.Forms.Label();
             this.MidBoxEnd = new UAS_LabelMachine.CustomControl.EnterTextBox();
@@ -113,6 +102,26 @@
             this.label7 = new System.Windows.Forms.Label();
             this.Input = new UAS_LabelMachine.CustomControl.EnterTextBox();
             this.LabelInf = new UAS_LabelMachine.CustomControl.DataGridViewWithSerialNum();
+            this.Choose = new System.Windows.Forms.DataGridViewCheckBoxColumn();
+            this.pib_ifprint = new System.Windows.Forms.DataGridViewCheckBoxColumn();
+            this.pib_id1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_pdno = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_prodcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_custprodcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pjd_orispeccode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_brand = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pr_zxbzs = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_lotno = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_datecode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.DateCode1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_qty = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_custbarcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_custmidboxcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_custoutboxcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_pocode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pr_spec = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_outboxcode1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pib_outboxcode2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.pi_inoutno = new UAS_LabelMachine.CustomControl.EnterTextBox();
             this.SingleLabel = new UAS_LabelMachine.CustomControl.GroupBoxWithBorder.GroupBoxWithBorder();
             this.SingleLabelPrinter = new UAS_LabelMachine.CustomControl.PrinterCombox();
@@ -137,26 +146,17 @@
             this.OutboxCapacity = new System.Windows.Forms.NumericUpDown();
             this.OutBoxLabelPrint = new System.Windows.Forms.Button();
             this.OutBoxCombox = new System.Windows.Forms.ComboBox();
-            this.Choose = new System.Windows.Forms.DataGridViewCheckBoxColumn();
-            this.pib_ifprint = new System.Windows.Forms.DataGridViewCheckBoxColumn();
-            this.pib_id1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_pdno = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_prodcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pd_custprodcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pjd_orispeccode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_brand = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pr_zxbzs = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_lotno = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_datecode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.DateCode1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_qty = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_custbarcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_custmidboxcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_custoutboxcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pd_pocode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pr_spec = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_outboxcode1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.pib_outboxcode2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_pdno = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pjd_id = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_custprodcode1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_prodcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_whcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.CollectedNum = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.UnCollectedNum = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_outqty = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pr_unit = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pd_brand = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.pjd_zxbzs_user = new System.Windows.Forms.DataGridViewTextBoxColumn();
             ((System.ComponentModel.ISupportInitialize)(this.MidSource)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.GridPrcode)).BeginInit();
@@ -725,7 +725,7 @@
             this.GridPrcode.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
             this.pd_pdno,
             this.pjd_id,
-            this.Column1,
+            this.pd_custprodcode1,
             this.pd_prodcode,
             this.pd_whcode,
             this.CollectedNum,
@@ -747,85 +747,6 @@
             this.GridPrcode.CellPainting += new System.Windows.Forms.DataGridViewCellPaintingEventHandler(this.GridPrcode_CellPainting);
             this.GridPrcode.SelectionChanged += new System.EventHandler(this.GridPrcode_SelectionChanged);
             // 
-            // pd_pdno
-            // 
-            this.pd_pdno.DataPropertyName = "pd_pdno";
-            this.pd_pdno.HeaderText = "明细序号";
-            this.pd_pdno.Name = "pd_pdno";
-            this.pd_pdno.ReadOnly = true;
-            // 
-            // pjd_id
-            // 
-            this.pjd_id.DataPropertyName = "pjd_id";
-            this.pjd_id.HeaderText = "pjd_id";
-            this.pjd_id.Name = "pjd_id";
-            this.pjd_id.Visible = false;
-            // 
-            // Column1
-            // 
-            this.Column1.DataPropertyName = "pd_custprodcode";
-            this.Column1.HeaderText = "客户料号";
-            this.Column1.Name = "Column1";
-            // 
-            // pd_prodcode
-            // 
-            this.pd_prodcode.DataPropertyName = "pd_prodcode";
-            this.pd_prodcode.HeaderText = "物料编号";
-            this.pd_prodcode.Name = "pd_prodcode";
-            this.pd_prodcode.ReadOnly = true;
-            // 
-            // pd_whcode
-            // 
-            this.pd_whcode.DataPropertyName = "pd_whcode";
-            this.pd_whcode.HeaderText = "仓别";
-            this.pd_whcode.Name = "pd_whcode";
-            // 
-            // CollectedNum
-            // 
-            this.CollectedNum.DataPropertyName = "CollectedNum";
-            this.CollectedNum.HeaderText = "已采数";
-            this.CollectedNum.Name = "CollectedNum";
-            this.CollectedNum.ReadOnly = true;
-            // 
-            // UnCollectedNum
-            // 
-            this.UnCollectedNum.DataPropertyName = "UnCollectedNum";
-            this.UnCollectedNum.HeaderText = "未采集";
-            this.UnCollectedNum.Name = "UnCollectedNum";
-            this.UnCollectedNum.ReadOnly = true;
-            // 
-            // pd_outqty
-            // 
-            this.pd_outqty.DataPropertyName = "pd_outqty";
-            this.pd_outqty.HeaderText = "出库数量";
-            this.pd_outqty.Name = "pd_outqty";
-            this.pd_outqty.ReadOnly = true;
-            this.pd_outqty.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            // 
-            // pr_unit
-            // 
-            this.pr_unit.DataPropertyName = "pr_unit";
-            this.pr_unit.HeaderText = "单位";
-            this.pr_unit.Name = "pr_unit";
-            this.pr_unit.ReadOnly = true;
-            this.pr_unit.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            // 
-            // pd_brand
-            // 
-            this.pd_brand.DataPropertyName = "pd_brand";
-            this.pd_brand.HeaderText = "品牌";
-            this.pd_brand.Name = "pd_brand";
-            this.pd_brand.ReadOnly = true;
-            this.pd_brand.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            // 
-            // pjd_zxbzs_user
-            // 
-            this.pjd_zxbzs_user.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
-            this.pjd_zxbzs_user.DataPropertyName = "pjd_zxbzs_user";
-            this.pjd_zxbzs_user.HeaderText = "最小包装";
-            this.pjd_zxbzs_user.Name = "pjd_zxbzs_user";
-            this.pjd_zxbzs_user.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            // 
             // groupBoxWithBorder1
             // 
             this.groupBoxWithBorder1.Controls.Add(this.label18);
@@ -985,102 +906,266 @@
             this.LabelInf.CellValueChanged += new System.Windows.Forms.DataGridViewCellEventHandler(this.LabelInf_CellValueChanged);
             this.LabelInf.DataError += new System.Windows.Forms.DataGridViewDataErrorEventHandler(this.LabelInf_DataError);
             // 
-            // pi_inoutno
+            // Choose
             // 
-            this.pi_inoutno.ID = null;
-            this.pi_inoutno.Location = new System.Drawing.Point(82, 10);
-            this.pi_inoutno.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
-            this.pi_inoutno.Name = "pi_inoutno";
-            this.pi_inoutno.Size = new System.Drawing.Size(150, 21);
-            this.pi_inoutno.Str = null;
-            this.pi_inoutno.Str1 = null;
-            this.pi_inoutno.Str2 = null;
-            this.pi_inoutno.TabIndex = 2;
-            this.pi_inoutno.KeyDown += new System.Windows.Forms.KeyEventHandler(this.pi_inoutno_KeyDown);
+            this.Choose.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
+            this.Choose.HeaderText = "勾选";
+            this.Choose.Name = "Choose";
+            this.Choose.Resizable = System.Windows.Forms.DataGridViewTriState.True;
+            this.Choose.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic;
+            this.Choose.Width = 55;
             // 
-            // SingleLabel
+            // pib_ifprint
             // 
-            this.SingleLabel.Controls.Add(this.SingleLabelPrinter);
-            this.SingleLabel.Controls.Add(this.SingleLabelPrint);
-            this.SingleLabel.Controls.Add(this.SingleLabelAutoPrint);
-            this.SingleLabel.Controls.Add(this.SingleLabelCombox);
-            this.SingleLabel.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.SingleLabel.Location = new System.Drawing.Point(726, 6);
-            this.SingleLabel.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
-            this.SingleLabel.Name = "SingleLabel";
-            this.SingleLabel.Padding = new System.Windows.Forms.Padding(2);
-            this.SingleLabel.Size = new System.Drawing.Size(170, 211);
-            this.SingleLabel.TabIndex = 77;
-            this.SingleLabel.TabStop = false;
-            this.SingleLabel.Text = "单盘标签";
+            this.pib_ifprint.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
+            this.pib_ifprint.DataPropertyName = "pib_ifprint";
+            this.pib_ifprint.HeaderText = "已打印";
+            this.pib_ifprint.Name = "pib_ifprint";
+            this.pib_ifprint.Width = 60;
             // 
-            // SingleLabelPrinter
+            // pib_id1
             // 
-            this.SingleLabelPrinter.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.SingleLabelPrinter.Location = new System.Drawing.Point(6, 63);
-            this.SingleLabelPrinter.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
-            this.SingleLabelPrinter.Name = "SingleLabelPrinter";
-            this.SingleLabelPrinter.Size = new System.Drawing.Size(159, 30);
-            this.SingleLabelPrinter.TabIndex = 40;
+            this.pib_id1.DataPropertyName = "pib_id";
+            this.pib_id1.HeaderText = "pib_id";
+            this.pib_id1.Name = "pib_id1";
+            this.pib_id1.Visible = false;
+            this.pib_id1.Width = 66;
             // 
-            // SingleLabelPrint
+            // pib_pdno
             // 
-            this.SingleLabelPrint.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
-            this.SingleLabelPrint.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.SingleLabelPrint.Location = new System.Drawing.Point(14, 175);
-            this.SingleLabelPrint.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
-            this.SingleLabelPrint.Name = "SingleLabelPrint";
-            this.SingleLabelPrint.Size = new System.Drawing.Size(68, 26);
-            this.SingleLabelPrint.TabIndex = 36;
-            this.SingleLabelPrint.Text = "打印盘标";
-            this.SingleLabelPrint.UseVisualStyleBackColor = true;
-            this.SingleLabelPrint.Click += new System.EventHandler(this.SingleLabelPrint_Click);
+            this.pib_pdno.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
+            this.pib_pdno.DataPropertyName = "pib_pdno";
+            this.pib_pdno.HeaderText = "明细序号";
+            this.pib_pdno.Name = "pib_pdno";
+            this.pib_pdno.ReadOnly = true;
+            this.pib_pdno.Width = 96;
             // 
-            // SingleLabelAutoPrint
+            // pib_prodcode
             // 
-            this.SingleLabelAutoPrint.AutoSize = true;
-            this.SingleLabelAutoPrint.Checked = true;
-            this.SingleLabelAutoPrint.CheckState = System.Windows.Forms.CheckState.Checked;
-            this.SingleLabelAutoPrint.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.SingleLabelAutoPrint.Location = new System.Drawing.Point(8, 96);
-            this.SingleLabelAutoPrint.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
-            this.SingleLabelAutoPrint.Name = "SingleLabelAutoPrint";
-            this.SingleLabelAutoPrint.Size = new System.Drawing.Size(75, 21);
-            this.SingleLabelAutoPrint.TabIndex = 30;
-            this.SingleLabelAutoPrint.Text = "自动打印";
-            this.SingleLabelAutoPrint.UseVisualStyleBackColor = true;
+            this.pib_prodcode.DataPropertyName = "pib_prodcode";
+            this.pib_prodcode.HeaderText = "物料编号";
+            this.pib_prodcode.Name = "pib_prodcode";
+            this.pib_prodcode.ReadOnly = true;
+            this.pib_prodcode.Width = 78;
             // 
-            // SingleLabelCombox
+            // pd_custprodcode
             // 
-            this.SingleLabelCombox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
-            this.SingleLabelCombox.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.SingleLabelCombox.FormattingEnabled = true;
-            this.SingleLabelCombox.Location = new System.Drawing.Point(7, 31);
-            this.SingleLabelCombox.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
-            this.SingleLabelCombox.Name = "SingleLabelCombox";
-            this.SingleLabelCombox.Size = new System.Drawing.Size(158, 25);
-            this.SingleLabelCombox.TabIndex = 0;
-            this.SingleLabelCombox.SelectedIndexChanged += new System.EventHandler(this.SingleLabelCombox_SelectedIndexChanged);
+            this.pd_custprodcode.DataPropertyName = "pd_custprodcode";
+            this.pd_custprodcode.HeaderText = "CPN";
+            this.pd_custprodcode.Name = "pd_custprodcode";
+            this.pd_custprodcode.Width = 48;
             // 
-            // MidLabel
+            // pjd_orispeccode
             // 
-            this.MidLabel.Controls.Add(this.MidboxCapacity);
-            this.MidLabel.Controls.Add(this.label2);
-            this.MidLabel.Controls.Add(this.MidLabelNum);
-            this.MidLabel.Controls.Add(this.label5);
-            this.MidLabel.Controls.Add(this.MidLabelPrinter);
-            this.MidLabel.Controls.Add(this.MidLabelPrint);
-            this.MidLabel.Controls.Add(this.MidLabelAutoPrint);
-            this.MidLabel.Controls.Add(this.MidLabelCombox);
-            this.MidLabel.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.MidLabel.Location = new System.Drawing.Point(898, 6);
-            this.MidLabel.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
-            this.MidLabel.Name = "MidLabel";
-            this.MidLabel.Padding = new System.Windows.Forms.Padding(2);
-            this.MidLabel.Size = new System.Drawing.Size(172, 211);
-            this.MidLabel.TabIndex = 78;
-            this.MidLabel.TabStop = false;
-            this.MidLabel.Text = "中盒标签";
+            this.pjd_orispeccode.DataPropertyName = "pjd_orispeccode";
+            this.pjd_orispeccode.HeaderText = "MPN";
+            this.pjd_orispeccode.Name = "pjd_orispeccode";
+            this.pjd_orispeccode.ReadOnly = true;
+            this.pjd_orispeccode.Width = 48;
+            // 
+            // pib_brand
+            // 
+            this.pib_brand.DataPropertyName = "pib_brand";
+            this.pib_brand.HeaderText = "品牌";
+            this.pib_brand.Name = "pib_brand";
+            this.pib_brand.ReadOnly = true;
+            this.pib_brand.Width = 54;
+            // 
+            // pr_zxbzs
+            // 
+            this.pr_zxbzs.DataPropertyName = "pr_zxbzs";
+            this.pr_zxbzs.HeaderText = "最小包装数";
+            this.pr_zxbzs.Name = "pr_zxbzs";
+            this.pr_zxbzs.ReadOnly = true;
+            this.pr_zxbzs.Visible = false;
+            this.pr_zxbzs.Width = 90;
+            // 
+            // pib_lotno
+            // 
+            this.pib_lotno.DataPropertyName = "pib_lotno";
+            this.pib_lotno.HeaderText = "LotNo";
+            this.pib_lotno.Name = "pib_lotno";
+            this.pib_lotno.ReadOnly = true;
+            this.pib_lotno.Width = 60;
+            // 
+            // pib_datecode
+            // 
+            this.pib_datecode.DataPropertyName = "pib_datecode";
+            this.pib_datecode.HeaderText = "DateCode";
+            this.pib_datecode.Name = "pib_datecode";
+            this.pib_datecode.ReadOnly = true;
+            this.pib_datecode.Width = 78;
+            // 
+            // DateCode1
+            // 
+            this.DateCode1.DataPropertyName = "DateCode1";
+            this.DateCode1.HeaderText = "DateCode1";
+            this.DateCode1.Name = "DateCode1";
+            this.DateCode1.Width = 84;
+            // 
+            // pib_qty
+            // 
+            this.pib_qty.DataPropertyName = "pib_qty";
+            this.pib_qty.HeaderText = "数量";
+            this.pib_qty.Name = "pib_qty";
+            this.pib_qty.ReadOnly = true;
+            this.pib_qty.Width = 54;
+            // 
+            // pib_custbarcode
+            // 
+            this.pib_custbarcode.DataPropertyName = "pib_custbarcode";
+            this.pib_custbarcode.HeaderText = "料盘条码";
+            this.pib_custbarcode.Name = "pib_custbarcode";
+            this.pib_custbarcode.ReadOnly = true;
+            this.pib_custbarcode.Width = 78;
+            // 
+            // pib_custmidboxcode
+            // 
+            this.pib_custmidboxcode.DataPropertyName = "pib_custmidboxcode";
+            this.pib_custmidboxcode.HeaderText = "中盒条码";
+            this.pib_custmidboxcode.Name = "pib_custmidboxcode";
+            this.pib_custmidboxcode.ReadOnly = true;
+            this.pib_custmidboxcode.Width = 78;
+            // 
+            // pib_custoutboxcode
+            // 
+            this.pib_custoutboxcode.DataPropertyName = "pib_custoutboxcode";
+            this.pib_custoutboxcode.HeaderText = "外箱条码";
+            this.pib_custoutboxcode.Name = "pib_custoutboxcode";
+            this.pib_custoutboxcode.ReadOnly = true;
+            this.pib_custoutboxcode.Width = 78;
+            // 
+            // pd_pocode
+            // 
+            this.pd_pocode.DataPropertyName = "pd_pocode";
+            this.pd_pocode.HeaderText = "客户PO";
+            this.pd_pocode.Name = "pd_pocode";
+            this.pd_pocode.ReadOnly = true;
+            this.pd_pocode.Width = 66;
+            // 
+            // pr_spec
+            // 
+            this.pr_spec.DataPropertyName = "pr_spec";
+            this.pr_spec.HeaderText = "规格";
+            this.pr_spec.Name = "pr_spec";
+            this.pr_spec.ReadOnly = true;
+            this.pr_spec.Visible = false;
+            this.pr_spec.Width = 54;
+            // 
+            // pib_outboxcode1
+            // 
+            this.pib_outboxcode1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
+            this.pib_outboxcode1.DataPropertyName = "pib_outboxcode1";
+            this.pib_outboxcode1.HeaderText = "中盒号";
+            this.pib_outboxcode1.Name = "pib_outboxcode1";
+            this.pib_outboxcode1.ReadOnly = true;
+            this.pib_outboxcode1.Width = 90;
+            // 
+            // pib_outboxcode2
+            // 
+            this.pib_outboxcode2.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
+            this.pib_outboxcode2.DataPropertyName = "pib_outboxcode2";
+            this.pib_outboxcode2.HeaderText = "外箱号";
+            this.pib_outboxcode2.Name = "pib_outboxcode2";
+            this.pib_outboxcode2.ReadOnly = true;
+            this.pib_outboxcode2.Width = 90;
+            // 
+            // pi_inoutno
+            // 
+            this.pi_inoutno.ID = null;
+            this.pi_inoutno.Location = new System.Drawing.Point(82, 10);
+            this.pi_inoutno.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.pi_inoutno.Name = "pi_inoutno";
+            this.pi_inoutno.Size = new System.Drawing.Size(150, 21);
+            this.pi_inoutno.Str = null;
+            this.pi_inoutno.Str1 = null;
+            this.pi_inoutno.Str2 = null;
+            this.pi_inoutno.TabIndex = 2;
+            this.pi_inoutno.KeyDown += new System.Windows.Forms.KeyEventHandler(this.pi_inoutno_KeyDown);
+            // 
+            // SingleLabel
+            // 
+            this.SingleLabel.Controls.Add(this.SingleLabelPrinter);
+            this.SingleLabel.Controls.Add(this.SingleLabelPrint);
+            this.SingleLabel.Controls.Add(this.SingleLabelAutoPrint);
+            this.SingleLabel.Controls.Add(this.SingleLabelCombox);
+            this.SingleLabel.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.SingleLabel.Location = new System.Drawing.Point(726, 6);
+            this.SingleLabel.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.SingleLabel.Name = "SingleLabel";
+            this.SingleLabel.Padding = new System.Windows.Forms.Padding(2);
+            this.SingleLabel.Size = new System.Drawing.Size(170, 211);
+            this.SingleLabel.TabIndex = 77;
+            this.SingleLabel.TabStop = false;
+            this.SingleLabel.Text = "单盘标签";
+            // 
+            // SingleLabelPrinter
+            // 
+            this.SingleLabelPrinter.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.SingleLabelPrinter.Location = new System.Drawing.Point(6, 63);
+            this.SingleLabelPrinter.Margin = new System.Windows.Forms.Padding(5, 6, 5, 6);
+            this.SingleLabelPrinter.Name = "SingleLabelPrinter";
+            this.SingleLabelPrinter.Size = new System.Drawing.Size(159, 30);
+            this.SingleLabelPrinter.TabIndex = 40;
+            // 
+            // SingleLabelPrint
+            // 
+            this.SingleLabelPrint.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right)));
+            this.SingleLabelPrint.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.SingleLabelPrint.Location = new System.Drawing.Point(14, 175);
+            this.SingleLabelPrint.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.SingleLabelPrint.Name = "SingleLabelPrint";
+            this.SingleLabelPrint.Size = new System.Drawing.Size(68, 26);
+            this.SingleLabelPrint.TabIndex = 36;
+            this.SingleLabelPrint.Text = "打印盘标";
+            this.SingleLabelPrint.UseVisualStyleBackColor = true;
+            this.SingleLabelPrint.Click += new System.EventHandler(this.SingleLabelPrint_Click);
+            // 
+            // SingleLabelAutoPrint
+            // 
+            this.SingleLabelAutoPrint.AutoSize = true;
+            this.SingleLabelAutoPrint.Checked = true;
+            this.SingleLabelAutoPrint.CheckState = System.Windows.Forms.CheckState.Checked;
+            this.SingleLabelAutoPrint.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.SingleLabelAutoPrint.Location = new System.Drawing.Point(8, 96);
+            this.SingleLabelAutoPrint.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.SingleLabelAutoPrint.Name = "SingleLabelAutoPrint";
+            this.SingleLabelAutoPrint.Size = new System.Drawing.Size(75, 21);
+            this.SingleLabelAutoPrint.TabIndex = 30;
+            this.SingleLabelAutoPrint.Text = "自动打印";
+            this.SingleLabelAutoPrint.UseVisualStyleBackColor = true;
+            // 
+            // SingleLabelCombox
+            // 
+            this.SingleLabelCombox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.SingleLabelCombox.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.SingleLabelCombox.FormattingEnabled = true;
+            this.SingleLabelCombox.Location = new System.Drawing.Point(7, 31);
+            this.SingleLabelCombox.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.SingleLabelCombox.Name = "SingleLabelCombox";
+            this.SingleLabelCombox.Size = new System.Drawing.Size(158, 25);
+            this.SingleLabelCombox.TabIndex = 0;
+            this.SingleLabelCombox.SelectedIndexChanged += new System.EventHandler(this.SingleLabelCombox_SelectedIndexChanged);
+            // 
+            // MidLabel
+            // 
+            this.MidLabel.Controls.Add(this.MidboxCapacity);
+            this.MidLabel.Controls.Add(this.label2);
+            this.MidLabel.Controls.Add(this.MidLabelNum);
+            this.MidLabel.Controls.Add(this.label5);
+            this.MidLabel.Controls.Add(this.MidLabelPrinter);
+            this.MidLabel.Controls.Add(this.MidLabelPrint);
+            this.MidLabel.Controls.Add(this.MidLabelAutoPrint);
+            this.MidLabel.Controls.Add(this.MidLabelCombox);
+            this.MidLabel.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.MidLabel.Location = new System.Drawing.Point(898, 6);
+            this.MidLabel.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.MidLabel.Name = "MidLabel";
+            this.MidLabel.Padding = new System.Windows.Forms.Padding(2);
+            this.MidLabel.Size = new System.Drawing.Size(172, 211);
+            this.MidLabel.TabIndex = 78;
+            this.MidLabel.TabStop = false;
+            this.MidLabel.Text = "中盒标签";
             // 
             // MidboxCapacity
             // 
@@ -1279,169 +1364,84 @@
             this.OutBoxCombox.TabIndex = 78;
             this.OutBoxCombox.SelectedIndexChanged += new System.EventHandler(this.OutBoxCombox_SelectedIndexChanged);
             // 
-            // Choose
-            // 
-            this.Choose.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
-            this.Choose.HeaderText = "勾选";
-            this.Choose.Name = "Choose";
-            this.Choose.Resizable = System.Windows.Forms.DataGridViewTriState.True;
-            this.Choose.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Automatic;
-            this.Choose.Width = 55;
-            // 
-            // pib_ifprint
-            // 
-            this.pib_ifprint.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
-            this.pib_ifprint.DataPropertyName = "pib_ifprint";
-            this.pib_ifprint.HeaderText = "已打印";
-            this.pib_ifprint.Name = "pib_ifprint";
-            this.pib_ifprint.Width = 60;
-            // 
-            // pib_id1
-            // 
-            this.pib_id1.DataPropertyName = "pib_id";
-            this.pib_id1.HeaderText = "pib_id";
-            this.pib_id1.Name = "pib_id1";
-            this.pib_id1.Visible = false;
-            this.pib_id1.Width = 66;
-            // 
-            // pib_pdno
-            // 
-            this.pib_pdno.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
-            this.pib_pdno.DataPropertyName = "pib_pdno";
-            this.pib_pdno.HeaderText = "明细序号";
-            this.pib_pdno.Name = "pib_pdno";
-            this.pib_pdno.ReadOnly = true;
-            this.pib_pdno.Width = 96;
-            // 
-            // pib_prodcode
-            // 
-            this.pib_prodcode.DataPropertyName = "pib_prodcode";
-            this.pib_prodcode.HeaderText = "物料编号";
-            this.pib_prodcode.Name = "pib_prodcode";
-            this.pib_prodcode.ReadOnly = true;
-            this.pib_prodcode.Width = 78;
-            // 
-            // pd_custprodcode
-            // 
-            this.pd_custprodcode.DataPropertyName = "pd_custprodcode";
-            this.pd_custprodcode.HeaderText = "CPN";
-            this.pd_custprodcode.Name = "pd_custprodcode";
-            this.pd_custprodcode.Width = 48;
-            // 
-            // pjd_orispeccode
-            // 
-            this.pjd_orispeccode.DataPropertyName = "pjd_orispeccode";
-            this.pjd_orispeccode.HeaderText = "MPN";
-            this.pjd_orispeccode.Name = "pjd_orispeccode";
-            this.pjd_orispeccode.ReadOnly = true;
-            this.pjd_orispeccode.Width = 48;
-            // 
-            // pib_brand
-            // 
-            this.pib_brand.DataPropertyName = "pib_brand";
-            this.pib_brand.HeaderText = "品牌";
-            this.pib_brand.Name = "pib_brand";
-            this.pib_brand.ReadOnly = true;
-            this.pib_brand.Width = 54;
-            // 
-            // pr_zxbzs
-            // 
-            this.pr_zxbzs.DataPropertyName = "pr_zxbzs";
-            this.pr_zxbzs.HeaderText = "最小包装数";
-            this.pr_zxbzs.Name = "pr_zxbzs";
-            this.pr_zxbzs.ReadOnly = true;
-            this.pr_zxbzs.Visible = false;
-            this.pr_zxbzs.Width = 90;
-            // 
-            // pib_lotno
+            // pd_pdno
             // 
-            this.pib_lotno.DataPropertyName = "pib_lotno";
-            this.pib_lotno.HeaderText = "LotNo";
-            this.pib_lotno.Name = "pib_lotno";
-            this.pib_lotno.ReadOnly = true;
-            this.pib_lotno.Width = 60;
+            this.pd_pdno.DataPropertyName = "pd_pdno";
+            this.pd_pdno.HeaderText = "明细序号";
+            this.pd_pdno.Name = "pd_pdno";
+            this.pd_pdno.ReadOnly = true;
             // 
-            // pib_datecode
+            // pjd_id
             // 
-            this.pib_datecode.DataPropertyName = "pib_datecode";
-            this.pib_datecode.HeaderText = "DateCode";
-            this.pib_datecode.Name = "pib_datecode";
-            this.pib_datecode.ReadOnly = true;
-            this.pib_datecode.Width = 78;
+            this.pjd_id.DataPropertyName = "pjd_id";
+            this.pjd_id.HeaderText = "pjd_id";
+            this.pjd_id.Name = "pjd_id";
+            this.pjd_id.Visible = false;
             // 
-            // DateCode1
+            // pd_custprodcode1
             // 
-            this.DateCode1.DataPropertyName = "DateCode1";
-            this.DateCode1.HeaderText = "DateCode1";
-            this.DateCode1.Name = "DateCode1";
-            this.DateCode1.Width = 84;
+            this.pd_custprodcode1.DataPropertyName = "pd_custprodcode";
+            this.pd_custprodcode1.HeaderText = "客户料号";
+            this.pd_custprodcode1.Name = "pd_custprodcode1";
             // 
-            // pib_qty
+            // pd_prodcode
             // 
-            this.pib_qty.DataPropertyName = "pib_qty";
-            this.pib_qty.HeaderText = "数量";
-            this.pib_qty.Name = "pib_qty";
-            this.pib_qty.ReadOnly = true;
-            this.pib_qty.Width = 54;
+            this.pd_prodcode.DataPropertyName = "pd_prodcode";
+            this.pd_prodcode.HeaderText = "物料编号";
+            this.pd_prodcode.Name = "pd_prodcode";
+            this.pd_prodcode.ReadOnly = true;
             // 
-            // pib_custbarcode
+            // pd_whcode
             // 
-            this.pib_custbarcode.DataPropertyName = "pib_custbarcode";
-            this.pib_custbarcode.HeaderText = "料盘条码";
-            this.pib_custbarcode.Name = "pib_custbarcode";
-            this.pib_custbarcode.ReadOnly = true;
-            this.pib_custbarcode.Width = 78;
+            this.pd_whcode.DataPropertyName = "pd_whcode";
+            this.pd_whcode.HeaderText = "仓别";
+            this.pd_whcode.Name = "pd_whcode";
             // 
-            // pib_custmidboxcode
+            // CollectedNum
             // 
-            this.pib_custmidboxcode.DataPropertyName = "pib_custmidboxcode";
-            this.pib_custmidboxcode.HeaderText = "中盒条码";
-            this.pib_custmidboxcode.Name = "pib_custmidboxcode";
-            this.pib_custmidboxcode.ReadOnly = true;
-            this.pib_custmidboxcode.Width = 78;
+            this.CollectedNum.DataPropertyName = "CollectedNum";
+            this.CollectedNum.HeaderText = "已采数";
+            this.CollectedNum.Name = "CollectedNum";
+            this.CollectedNum.ReadOnly = true;
             // 
-            // pib_custoutboxcode
+            // UnCollectedNum
             // 
-            this.pib_custoutboxcode.DataPropertyName = "pib_custoutboxcode";
-            this.pib_custoutboxcode.HeaderText = "外箱条码";
-            this.pib_custoutboxcode.Name = "pib_custoutboxcode";
-            this.pib_custoutboxcode.ReadOnly = true;
-            this.pib_custoutboxcode.Width = 78;
+            this.UnCollectedNum.DataPropertyName = "UnCollectedNum";
+            this.UnCollectedNum.HeaderText = "未采集";
+            this.UnCollectedNum.Name = "UnCollectedNum";
+            this.UnCollectedNum.ReadOnly = true;
             // 
-            // pd_pocode
+            // pd_outqty
             // 
-            this.pd_pocode.DataPropertyName = "pd_pocode";
-            this.pd_pocode.HeaderText = "客户PO";
-            this.pd_pocode.Name = "pd_pocode";
-            this.pd_pocode.ReadOnly = true;
-            this.pd_pocode.Width = 66;
+            this.pd_outqty.DataPropertyName = "pd_outqty";
+            this.pd_outqty.HeaderText = "出库数量";
+            this.pd_outqty.Name = "pd_outqty";
+            this.pd_outqty.ReadOnly = true;
+            this.pd_outqty.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
             // 
-            // pr_spec
+            // pr_unit
             // 
-            this.pr_spec.DataPropertyName = "pr_spec";
-            this.pr_spec.HeaderText = "规格";
-            this.pr_spec.Name = "pr_spec";
-            this.pr_spec.ReadOnly = true;
-            this.pr_spec.Visible = false;
-            this.pr_spec.Width = 54;
+            this.pr_unit.DataPropertyName = "pr_unit";
+            this.pr_unit.HeaderText = "单位";
+            this.pr_unit.Name = "pr_unit";
+            this.pr_unit.ReadOnly = true;
+            this.pr_unit.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
             // 
-            // pib_outboxcode1
+            // pd_brand
             // 
-            this.pib_outboxcode1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
-            this.pib_outboxcode1.DataPropertyName = "pib_outboxcode1";
-            this.pib_outboxcode1.HeaderText = "中盒号";
-            this.pib_outboxcode1.Name = "pib_outboxcode1";
-            this.pib_outboxcode1.ReadOnly = true;
-            this.pib_outboxcode1.Width = 90;
+            this.pd_brand.DataPropertyName = "pd_brand";
+            this.pd_brand.HeaderText = "品牌";
+            this.pd_brand.Name = "pd_brand";
+            this.pd_brand.ReadOnly = true;
+            this.pd_brand.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
             // 
-            // pib_outboxcode2
+            // pjd_zxbzs_user
             // 
-            this.pib_outboxcode2.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
-            this.pib_outboxcode2.DataPropertyName = "pib_outboxcode2";
-            this.pib_outboxcode2.HeaderText = "外箱号";
-            this.pib_outboxcode2.Name = "pib_outboxcode2";
-            this.pib_outboxcode2.ReadOnly = true;
-            this.pib_outboxcode2.Width = 90;
+            this.pjd_zxbzs_user.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
+            this.pjd_zxbzs_user.DataPropertyName = "pjd_zxbzs_user";
+            this.pjd_zxbzs_user.HeaderText = "最小包装";
+            this.pjd_zxbzs_user.Name = "pjd_zxbzs_user";
+            this.pjd_zxbzs_user.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
             // 
             // UAS_出货标签打印
             // 
@@ -1500,18 +1500,18 @@
             ((System.ComponentModel.ISupportInitialize)(this.MidSource)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.GridPrcode)).EndInit();
-            this.groupBoxWithBorder1.ResumeLayout(false);
+            this.groupBoxWithBorder1.ResumeLayout(true);
             this.groupBoxWithBorder1.PerformLayout();
             ((System.ComponentModel.ISupportInitialize)(this.LabelInf)).EndInit();
-            this.SingleLabel.ResumeLayout(false);
+            this.SingleLabel.ResumeLayout(true);
             this.SingleLabel.PerformLayout();
-            this.MidLabel.ResumeLayout(false);
+            this.MidLabel.ResumeLayout(true);
             this.MidLabel.PerformLayout();
             ((System.ComponentModel.ISupportInitialize)(this.MidboxCapacity)).EndInit();
-            this.OutBoxLabel.ResumeLayout(false);
+            this.OutBoxLabel.ResumeLayout(true);
             this.OutBoxLabel.PerformLayout();
             ((System.ComponentModel.ISupportInitialize)(this.OutboxCapacity)).EndInit();
-            this.ResumeLayout(false);
+            this.ResumeLayout(true);
             this.PerformLayout();
 
         }
@@ -1613,17 +1613,6 @@
         private System.Windows.Forms.Label pi_title;
         private System.Windows.Forms.Label label9;
         private System.Windows.Forms.Label ProcessCount;
-        private System.Windows.Forms.DataGridViewTextBoxColumn pd_pdno;
-        private System.Windows.Forms.DataGridViewTextBoxColumn pjd_id;
-        private System.Windows.Forms.DataGridViewTextBoxColumn Column1;
-        private System.Windows.Forms.DataGridViewTextBoxColumn pd_prodcode;
-        private System.Windows.Forms.DataGridViewTextBoxColumn pd_whcode;
-        private System.Windows.Forms.DataGridViewTextBoxColumn CollectedNum;
-        private System.Windows.Forms.DataGridViewTextBoxColumn UnCollectedNum;
-        private System.Windows.Forms.DataGridViewTextBoxColumn pd_outqty;
-        private System.Windows.Forms.DataGridViewTextBoxColumn pr_unit;
-        private System.Windows.Forms.DataGridViewTextBoxColumn pd_brand;
-        private System.Windows.Forms.DataGridViewTextBoxColumn pjd_zxbzs_user;
         private System.Windows.Forms.DataGridViewCheckBoxColumn Choose;
         private System.Windows.Forms.DataGridViewCheckBoxColumn pib_ifprint;
         private System.Windows.Forms.DataGridViewTextBoxColumn pib_id1;
@@ -1644,5 +1633,16 @@
         private System.Windows.Forms.DataGridViewTextBoxColumn pr_spec;
         private System.Windows.Forms.DataGridViewTextBoxColumn pib_outboxcode1;
         private System.Windows.Forms.DataGridViewTextBoxColumn pib_outboxcode2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pd_pdno;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pjd_id;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pd_custprodcode1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pd_prodcode;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pd_whcode;
+        private System.Windows.Forms.DataGridViewTextBoxColumn CollectedNum;
+        private System.Windows.Forms.DataGridViewTextBoxColumn UnCollectedNum;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pd_outqty;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pr_unit;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pd_brand;
+        private System.Windows.Forms.DataGridViewTextBoxColumn pjd_zxbzs_user;
     }
 }

+ 39 - 22
UAS-出货标签管理(泽天)/UAS_出货标签管理.cs

@@ -369,26 +369,26 @@ namespace UAS_LabelMachine
             //采集达到了数量进行换行
             if (CollectQty == double.Parse(CurrentPrCount))
             {
-                for (int i = 0; i < GridPrcode.Rows.Count; i++)
-                {
-                    string outqty = GridPrcode.Rows[i].Cells["pd_outqty"].Value.ToString();
-                    string collectnum = GridPrcode.Rows[i].Cells["CollectedNum"].Value.ToString();
-                    //采集之前的行,如后续行有物料编号相同的并且编号较大的跳到这样
-                    if (GridPrcode.Rows[i].Cells["pd_prodcode"].Value.ToString() == CurrentPrCode && double.Parse(outqty) > double.Parse(collectnum == "" ? "0" : collectnum))
-                    {
-                        if (int.Parse(GridPrcode.Rows[i].Cells["pd_pdno"].Value.ToString()) > int.Parse(CurrentPDNO))
-                        {
-                            GridPrcode.Rows[i].Selected = true;
-                            if (i - 1 > 0)
-                                GridPrcode.FirstDisplayedScrollingRowIndex = i - 1;
-                            else
-                                GridPrcode.FirstDisplayedScrollingRowIndex = i;
-                            Input.Clear();
-                            OutBoxNum_Click(new object(), new EventArgs());
-                            return;
-                        }
-                    }
-                }
+                //for (int i = 0; i < GridPrcode.Rows.Count; i++)
+                //{
+                //    string outqty = GridPrcode.Rows[i].Cells["pd_outqty"].Value.ToString();
+                //    string collectnum = GridPrcode.Rows[i].Cells["CollectedNum"].Value.ToString();
+                //    //采集之前的行,如后续行有物料编号相同的并且编号较大的跳到这样
+                //    if (GridPrcode.Rows[i].Cells["pd_prodcode"].Value.ToString() == CurrentPrCode && double.Parse(outqty) > double.Parse(collectnum == "" ? "0" : collectnum))
+                //    {
+                //        if (int.Parse(GridPrcode.Rows[i].Cells["pd_pdno"].Value.ToString()) > int.Parse(CurrentPDNO))
+                //        {
+                //            GridPrcode.Rows[i].Selected = true;
+                //            if (i - 1 > 0)
+                //                GridPrcode.FirstDisplayedScrollingRowIndex = i - 1;
+                //            else
+                //                GridPrcode.FirstDisplayedScrollingRowIndex = i;
+                //            Input.Clear();
+                //            OutBoxNum_Click(new object(), new EventArgs());
+                //            return;
+                //        }
+                //    }
+                //}
                 DataGridViewSelectedRowCollection selectrow = GridPrcode.SelectedRows;
                 if (selectrow.Count > 0)
                 {
@@ -531,6 +531,7 @@ namespace UAS_LabelMachine
         {
             if (e.KeyCode == Keys.Enter)
             {
+                Combindetail.Checked = false;
                 Input.Clear();
                 sql.Clear();
                 sql.Append("select pi_id,pi_cardcode,pi_title,to_char(pi_date,'yyyymmdd')pi_date from prodinout where pi_inoutno='" + pi_inoutno.Text + "' and pi_invostatuscode='AUDITED'");
@@ -1061,6 +1062,20 @@ namespace UAS_LabelMachine
             //有数据的话默认取第一条的品牌去取采集策略
             if (LabelInf.Rows.Count > 0)
                 LabelInf.FirstDisplayedScrollingRowIndex = LabelInf.Rows.Count - 1;
+            double CollectNum = 0;
+            double OutNum = 0;
+            for (int i = 0; i < GridPrcode.Rows.Count; i++)
+            {
+                string CurrentPrCode = GridPrcode.Rows[i].Cells["pd_prodcode"].Value.ToString();
+                string CurrentPDNO = GridPrcode.Rows[i].Cells["pd_pdno"].Value.ToString();
+                string CurrentOutQTY = GridPrcode.Rows[i].Cells["pd_outqty"].Value.ToString();
+                string collectqty = (LabelInfDataTable.Compute("sum(pib_qty)", "pib_prodcode='" + CurrentPrCode + "' and pib_pdno='" + CurrentPDNO + "'").ToString());
+                CollectNum += double.Parse(collectqty == "" ? "0" : collectqty);
+                OutNum += double.Parse(CurrentOutQTY);
+                GridPrcode.Rows[i].Cells["CollectedNum"].Value = collectqty;
+                GridPrcode.Rows[i].Cells["UnCollectedNum"].Value = Convert.ToDouble(double.Parse(GridPrcode.Rows[i].Cells["pd_outqty"].Value.ToString()) - double.Parse(collectqty == "" ? "0" : collectqty)).ToString("0.000");
+            }
+            ProcessCount.Text = CollectNum + "/" + OutNum;
         }
 
         private void Refresh_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
@@ -1287,14 +1302,16 @@ namespace UAS_LabelMachine
                     if (i + 1 < GridPrcode.Rows.Count)
                     {
                         string BProdCode = GridPrcode.Rows[i].Cells["pd_prodcode"].Value.ToString();
+                        string BCustProdCode = GridPrcode.Rows[i].Cells["pd_custprodcode1"].Value.ToString();
                         string BWhCode = GridPrcode.Rows[i].Cells["pd_whcode"].Value.ToString();
                         string BPrUnit = GridPrcode.Rows[i].Cells["pr_unit"].Value.ToString();
                         string BPrBrand = GridPrcode.Rows[i].Cells["pd_brand"].Value.ToString();
                         string FProdCode = GridPrcode.Rows[i + 1].Cells["pd_prodcode"].Value.ToString();
+                        string FCustProdCode = GridPrcode.Rows[i + 1].Cells["pd_custprodcode1"].Value.ToString();
                         string FPrUnit = GridPrcode.Rows[i + 1].Cells["pr_unit"].Value.ToString();
                         string FrBrand = GridPrcode.Rows[i + 1].Cells["pd_brand"].Value.ToString();
                         string FWhCode = GridPrcode.Rows[i + 1].Cells["pd_whcode"].Value.ToString();
-                        if (BProdCode == FProdCode && BWhCode == FWhCode)
+                        if (BProdCode == FProdCode && BPrBrand == FrBrand && BCustProdCode == FCustProdCode)
                         {
                             GridPrcode.Rows[CurrentIndex].Cells["pd_outqty"].Value = double.Parse(GridPrcode.Rows[CurrentIndex].Cells["pd_outqty"].Value.ToString()) + double.Parse(GridPrcode.Rows[i + 1].Cells["pd_outqty"].Value.ToString());
                             GridPrcode.Rows[CurrentIndex].Cells["CollectedNum"].Value = double.Parse(GridPrcode.Rows[CurrentIndex].Cells["CollectedNum"].Value.ToString()) + double.Parse(GridPrcode.Rows[i + 1].Cells["CollectedNum"].Value.ToString());
@@ -1305,7 +1322,7 @@ namespace UAS_LabelMachine
                         {
                             CurrentIndex = i + 1;
                         }
-                      
+
                     }
                 }
                 foreach (int item in RemoveIndex.OrderByDescending(x => x))

+ 1 - 1
UAS-出货标签管理(泽天)/UAS_出货标签管理.resx

@@ -132,7 +132,7 @@
   <metadata name="pjd_id.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="Column1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="pd_custprodcode1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
   <metadata name="pd_prodcode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">