Pārlūkot izejas kodu

添加重置合并序号功能

章政 5 gadi atpakaļ
vecāks
revīzija
b3cdcdddd1

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

@@ -28,6 +28,7 @@
         /// </summary>
         private void InitializeComponent()
         {
+            this.components = new System.ComponentModel.Container();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
             System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(UAS_出货标签打印));
             this.pi_inoutno_label = new System.Windows.Forms.Label();
@@ -37,7 +38,7 @@
             this.pib_id = new System.Windows.Forms.Label();
             this.pi_cardcode = new System.Windows.Forms.Label();
             this.Fresh = new System.Windows.Forms.LinkLabel();
-            this.RefreshDBConnect = new System.Windows.Forms.Timer();
+            this.RefreshDBConnect = new System.Windows.Forms.Timer(this.components);
             this.dataGridViewCheckBoxColumn1 = new System.Windows.Forms.DataGridViewCheckBoxColumn();
             this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
@@ -64,7 +65,7 @@
             this.dataGridViewTextBoxColumn21 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.dataGridViewTextBoxColumn22 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.dataGridViewTextBoxColumn23 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.MidSource = new System.Windows.Forms.BindingSource();
+            this.MidSource = new System.Windows.Forms.BindingSource(this.components);
             this.ChooseAll = new System.Windows.Forms.Button();
             this.ExportFileDialog = new System.Windows.Forms.FolderBrowserDialog();
             this.AttachInfo = new System.Windows.Forms.Button();
@@ -155,6 +156,7 @@
             this.MidLabelAutoPrint = new System.Windows.Forms.CheckBox();
             this.MidLabelCombox = new System.Windows.Forms.ComboBox();
             this.OutBoxLabel = new UAS_LabelMachine.CustomControl.GroupBoxWithBorder.GroupBoxWithBorder();
+            this.OnlyOneRow = new System.Windows.Forms.CheckBox();
             this.AllLabel = new System.Windows.Forms.CheckBox();
             this.AddNewOutBox = new System.Windows.Forms.Button();
             this.LogingOut = new System.Windows.Forms.LinkLabel();
@@ -167,7 +169,7 @@
             this.OutBoxCombox = new System.Windows.Forms.ComboBox();
             this.Reset = new System.Windows.Forms.Button();
             this.GetPDdata = new System.Windows.Forms.Button();
-            this.OnlyOneRow = new System.Windows.Forms.CheckBox();
+            this.ResetHBXH = new System.Windows.Forms.Button();
             ((System.ComponentModel.ISupportInitialize)(this.MidSource)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.GridPrcode)).BeginInit();
@@ -909,6 +911,7 @@
             // 
             // groupBoxWithBorder1
             // 
+            this.groupBoxWithBorder1.Controls.Add(this.ResetHBXH);
             this.groupBoxWithBorder1.Controls.Add(this.label18);
             this.groupBoxWithBorder1.Controls.Add(this.MidBoxEnd);
             this.groupBoxWithBorder1.Controls.Add(this.MidBoxBegin);
@@ -1462,6 +1465,18 @@
             this.OutBoxLabel.TabStop = false;
             this.OutBoxLabel.Text = "外箱标签";
             // 
+            // OnlyOneRow
+            // 
+            this.OnlyOneRow.AutoSize = true;
+            this.OnlyOneRow.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.OnlyOneRow.Location = new System.Drawing.Point(107, 93);
+            this.OnlyOneRow.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.OnlyOneRow.Name = "OnlyOneRow";
+            this.OnlyOneRow.Size = new System.Drawing.Size(63, 21);
+            this.OnlyOneRow.TabIndex = 94;
+            this.OnlyOneRow.Text = "仅单行";
+            this.OnlyOneRow.UseVisualStyleBackColor = true;
+            // 
             // AllLabel
             // 
             this.AllLabel.AutoSize = true;
@@ -1604,17 +1619,17 @@
             this.GetPDdata.UseVisualStyleBackColor = true;
             this.GetPDdata.Click += new System.EventHandler(this.GetPDdata_Click);
             // 
-            // OnlyOneRow
+            // ResetHBXH
             // 
-            this.OnlyOneRow.AutoSize = true;
-            this.OnlyOneRow.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.OnlyOneRow.Location = new System.Drawing.Point(107, 93);
-            this.OnlyOneRow.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
-            this.OnlyOneRow.Name = "OnlyOneRow";
-            this.OnlyOneRow.Size = new System.Drawing.Size(63, 21);
-            this.OnlyOneRow.TabIndex = 94;
-            this.OnlyOneRow.Text = "仅单行";
-            this.OnlyOneRow.UseVisualStyleBackColor = true;
+            this.ResetHBXH.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.ResetHBXH.Location = new System.Drawing.Point(40, 177);
+            this.ResetHBXH.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.ResetHBXH.Name = "ResetHBXH";
+            this.ResetHBXH.Size = new System.Drawing.Size(92, 26);
+            this.ResetHBXH.TabIndex = 112;
+            this.ResetHBXH.Text = "重置合并序号";
+            this.ResetHBXH.UseVisualStyleBackColor = true;
+            this.ResetHBXH.Click += new System.EventHandler(this.ResetHBXH_Click);
             // 
             // UAS_出货标签打印
             // 
@@ -1830,5 +1845,6 @@
         private System.Windows.Forms.Button GetPDdata;
         private System.Windows.Forms.CheckBox AllLabel;
         private System.Windows.Forms.CheckBox OnlyOneRow;
+        private System.Windows.Forms.Button ResetHBXH;
     }
 }

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

@@ -594,7 +594,7 @@ namespace UAS_LabelMachine
                     {
                         CustomerLabel.Enabled = true;
                     }
-       
+
                     OutBoxNum_Click(new object(), new EventArgs());
                     LoadPrcodeData();
                     //获取条码规则
@@ -1030,7 +1030,7 @@ namespace UAS_LabelMachine
                     MidReport.Print();
                     dh.UpdateByCondition("prodiobarcode", "pib_midifprint=-1", "pib_inoutno='" + pi_inoutno.Text + "' and pib_outboxcode1 in (" + pib_outboxcode1 + ")");
                     SelectRowIndex = -1;
-                    LogManager.DoCommandLog(pi_inoutno.Text, User.UserCode, "打印中盒" + pib_outboxcode1.Replace("'",""), "打印成功");
+                    LogManager.DoCommandLog(pi_inoutno.Text, User.UserCode, "打印中盒" + pib_outboxcode1.Replace("'", ""), "打印成功");
                 }
                 Properties.Settings.Default.MPrinter = MidLabelPrinter.Text;
                 Properties.Settings.Default.Save();
@@ -1897,7 +1897,8 @@ namespace UAS_LabelMachine
             {
                 CombindetailTwo.Checked = false;
             }
-            if (LoadCheck) {
+            if (LoadCheck)
+            {
                 LoadPrcodeData();
                 string response = "";
                 string[] param = new string[] { PI_ID, "1", response };
@@ -1980,5 +1981,11 @@ namespace UAS_LabelMachine
             dh.UpdateByCondition("CS$InoutPrcode", "collectednum=(select nvl(sum(pib_qty),0) from prodiobarcode where pib_inoutno=pd_inoutno and pib_pdno=pd_pdno)", "pd_inoutno='" + pi_inoutno.Text + "'");
             MessageBox.Show("同步出货单明细数据成功", "提示");
         }
+
+        private void ResetHBXH_Click(object sender, EventArgs e)
+        {
+            dh.ExecuteSql("update prodiodetail set PD_HBXH_USER=pd_pdno where pd_inoutno='" + pi_inoutno.Text + "'", "update");
+            MessageBox.Show("重置序号成功", "提示");
+        }
     }
 }