瀏覽代碼

提示音修改,在线箱号核对

callm 1 年之前
父節點
當前提交
c9e55908e0

+ 13 - 0
UAS_MES_LGDZ/CustomControl/RichText/RichTextAutoBottom.cs

@@ -40,6 +40,12 @@ namespace UAS_MES_NEW.CustomControl.RichText
                 thread.Start();
                 thread = new Thread(PlaySound);
             }
+            else if (color == Color.DarkRed && Entity.SystemInf.CheckAudioEnable)
+            {
+                FileName = Application.StartupPath + @"\Resources\Sound\5185.wav";
+                thread.Start();
+                thread = new Thread(PlaySound);
+            }
             else if (color == Color.Green && Entity.SystemInf.CheckAudioEnable)
             {
                 //颜色是绿色,进行正确提示音
@@ -54,6 +60,13 @@ namespace UAS_MES_NEW.CustomControl.RichText
                 thread.Start();
                 thread = new Thread(PlaySound);
             }
+            else if (color == Color.LightGreen && Entity.SystemInf.CheckAudioEnable)
+            {
+                //颜色是绿色,进行正确提示音
+                FileName = Application.StartupPath + @"\Resources\Sound\3853.wav";
+                thread.Start();
+                thread = new Thread(PlaySound);
+            }
             LogManager.DoLog(FindForm().Tag + str);
         }
 

+ 19 - 20
UAS_MES_LGDZ/FunctionCode/Make/Make_ImeiCheck_ThreeLabel_WN.cs

@@ -73,7 +73,7 @@ namespace UAS_MES_NEW.Make
             {
                 if (sncode.Text == "")
                 {
-                    OperateResult.AppendText("<<输入不能为空\n", Color.Red);
+                    OperateResult.AppendText("<<输入不能为空\n", Color.DarkRed);
                     return;
                 }
                 dt = (DataTable)dh.ExecuteSql("select ms_sncode from makeserial where ms_imei1='" + sncode.Text + "' order by ms_id desc", "select");
@@ -138,7 +138,7 @@ namespace UAS_MES_NEW.Make
                                     dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
                                     if (dt.Rows.Count == 0 || dt.Rows[0]["ms_id"].ToString() == "")
                                     {
-                                        OperateResult.AppendText("<<SN错误,序列号" + sncode.Text + "不存在\n", Color.Red, sncode);
+                                        OperateResult.AppendText("<<SN错误,序列号" + sncode.Text + "不存在\n", Color.DarkRed, sncode);
                                         OperateResult.AppendText(">>请输入SN\n", Color.Black);
                                     }
                                 }
@@ -163,9 +163,9 @@ namespace UAS_MES_NEW.Make
                     }
                     else
                     {
-                        OperateResult.AppendText("<<SN:" + sncode.Text + "对应的SN不存在\n", Color.Red, sncode);
+                        OperateResult.AppendText("<<SN:" + sncode.Text + "对应的SN不存在\n", Color.DarkRed, sncode);
                         OperateResult.AppendText(">>请输入SN\n", Color.Black);
-                        SetCheck set = new SetCheck("NG", Color.Red);
+                        SetCheck set = new SetCheck("NG", Color.DarkRed);
                         BaseUtil.SetFormCenter(set);
                         set.ShowDialog();
                     }
@@ -198,9 +198,9 @@ namespace UAS_MES_NEW.Make
                                     dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
                                     if (dt.Rows.Count == 0 || dt.Rows[0]["ms_id"].ToString() == "")
                                     {
-                                        OperateResult.AppendText("<<SN错误,序列号" + sncode.Text + "不存在\n", Color.Red, sncode);
+                                        OperateResult.AppendText("<<SN错误,序列号" + sncode.Text + "不存在\n", Color.DarkRed, sncode);
                                         OperateResult.AppendText(">>请输入SN\n", Color.Black);
-                                        SetCheck set = new SetCheck("NG", Color.Red);
+                                        SetCheck set = new SetCheck("NG", Color.DarkRed);
                                         BaseUtil.SetFormCenter(set);
                                         set.ShowDialog();
                                     }
@@ -230,8 +230,8 @@ namespace UAS_MES_NEW.Make
                         checksn = "";
                         //SN核对失败
                         //>> 请输入SN
-                        OperateResult.AppendText(">>SN核对失败,不一致\n", Color.Red, sncode);
-                        SetCheck set = new SetCheck("NG", Color.Red);
+                        OperateResult.AppendText(">>SN核对失败,不一致\n", Color.DarkRed, sncode);
+                        SetCheck set = new SetCheck("NG", Color.DarkRed);
                         BaseUtil.SetFormCenter(set);
                         set.ShowDialog();
                         OperateResult.AppendText(">>请输入SN\n", Color.Black);
@@ -248,7 +248,7 @@ namespace UAS_MES_NEW.Make
                     dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
                     if (dt.Rows.Count == 0 || dt.Rows[0]["ms_id"].ToString() == "")
                     {
-                        OperateResult.AppendText("<<SN错误,序列号" + sncode.Text + "不存在\n", Color.Red, sncode);
+                        OperateResult.AppendText("<<SN错误,序列号" + sncode.Text + "不存在\n", Color.DarkRed, sncode);
                         OperateResult.AppendText(">>请输入SN\n", Color.Black);
                     }
                     sql.Clear();
@@ -271,7 +271,7 @@ namespace UAS_MES_NEW.Make
                                 if (nextstepcode != User.CurrentStepCode)
                                 {
                                     string stname = dh.getFieldDataByCondition("step", "st_name", "st_code='" + nextstepcode + "'").ToString();
-                                    OperateResult.AppendText("<<序列号:" + sncode.Text + "下一工序是" + stname + ",不是当前岗位的工序\n", Color.Red, sncode);
+                                    OperateResult.AppendText("<<序列号:" + sncode.Text + "下一工序是" + stname + ",不是当前岗位的工序\n", Color.DarkRed, sncode);
                                     imei1 = "";
                                     imei2 = "";
                                     checksn = "";
@@ -282,7 +282,6 @@ namespace UAS_MES_NEW.Make
                                 //调用  SETSTEPRESULT ,获取返回的工单号,
                                 if (LogicHandler.SetStepResult(omakeCode, User.UserSourceCode, checksn, "标签核对", "OK", User.UserCode, out oErrorMessage))
                                 {
-
                                     //提示正确返回时传递的信息
                                     if (oErrorMessage.Contains("AFTERSUCCESS"))
                                         OperateResult.AppendText(">>" + oErrorMessage + "\n");
@@ -299,15 +298,15 @@ namespace UAS_MES_NEW.Make
                                     LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ma_code.Text, User.UserLineCode, User.UserSourceCode, "标签核对", "标签核对成功", SN, "");
                                     //SN核对成功
                                     //>> 请输入SN
-                                    OperateResult.AppendText("<<条码2核对成功\n", Color.Green, sncode);
+                                    OperateResult.AppendText("<<条码2核对成功\n", Color.LightGreen, sncode);
                                     OperateResult.AppendText(">>请输入SN\n", Color.Black);
                                 }
                                 else
                                 {
                                     //setstepresult不通过
-                                    OperateResult.AppendText(">>" + oErrorMessage + "\n", Color.Red, sncode);
+                                    OperateResult.AppendText(">>" + oErrorMessage + "\n", Color.DarkRed, sncode);
                                     recordResult(checksn, DateTime.Now.ToString(), "失败");
-                                    SetCheck set = new SetCheck("NG", Color.Red);
+                                    SetCheck set = new SetCheck("NG", Color.DarkRed);
                                     BaseUtil.SetFormCenter(set);
                                     set.ShowDialog();
                                 }
@@ -315,9 +314,9 @@ namespace UAS_MES_NEW.Make
                             else
                             {
                                 //判定序列号下一工序不通过
-                                OperateResult.AppendText(">>" + oErrorMessage + "\n", Color.Red, sncode);
+                                OperateResult.AppendText(">>" + oErrorMessage + "\n", Color.DarkRed, sncode);
                                 recordResult(checksn, DateTime.Now.ToString(), "失败");
-                                SetCheck set = new SetCheck("NG", Color.Red);
+                                SetCheck set = new SetCheck("NG", Color.DarkRed);
                                 BaseUtil.SetFormCenter(set);
                                 set.ShowDialog();
                             }
@@ -325,8 +324,8 @@ namespace UAS_MES_NEW.Make
                         else
                         {
                             //判定工序属性不通过
-                            OperateResult.AppendText(">>" + oErrorMessage + "\n", Color.Red, sncode);
-                            SetCheck set = new SetCheck("NG", Color.Red);
+                            OperateResult.AppendText(">>" + oErrorMessage + "\n", Color.DarkRed, sncode);
+                            SetCheck set = new SetCheck("NG", Color.DarkRed);
                             BaseUtil.SetFormCenter(set);
                             set.ShowDialog();
                             recordResult(checksn, DateTime.Now.ToString(), "失败");
@@ -341,8 +340,8 @@ namespace UAS_MES_NEW.Make
                         checksn = "";
                         //SN核对失败
                         //>> 请输入SN
-                        OperateResult.AppendText(">>SN核对失败,不一致\n", Color.Red, sncode);
-                        SetCheck set = new SetCheck("NG", Color.Red);
+                        OperateResult.AppendText(">>SN核对失败,不一致\n", Color.DarkRed, sncode);
+                        SetCheck set = new SetCheck("NG", Color.DarkRed);
                         BaseUtil.SetFormCenter(set);
                         set.ShowDialog();
                         OperateResult.AppendText(">>请输入SN\n", Color.Black);

+ 147 - 60
UAS_MES_LGDZ/FunctionCode/Make/Make_OutBoxSnCheck.Designer.cs

@@ -30,14 +30,20 @@
         {
             System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Make_OutBoxSnCheck));
             this.label10 = new System.Windows.Forms.Label();
-            this.sncode = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SnCollectionBox();
-            this.cancel = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
-            this.OperateResult = new UAS_MES_NEW.CustomControl.RichText.RichTextAutoBottom();
             this.CheckSnDGV = new System.Windows.Forms.DataGridView();
-            this.pa_outboxcode = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SnCollectionBox();
             this.label1 = new System.Windows.Forms.Label();
+            this.pa_makecode_label = new System.Windows.Forms.Label();
+            this.label2 = new System.Windows.Forms.Label();
+            this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.CheckNum = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
+            this.pa_makecode = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
+            this.pa_outboxcode = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SnCollectionBox();
             this.pd_barcode = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.pd_checksn = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.cancel = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
+            this.sncode = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SnCollectionBox();
+            this.OperateResult = new UAS_MES_NEW.CustomControl.RichText.RichTextAutoBottom();
             ((System.ComponentModel.ISupportInitialize)(this.CheckSnDGV)).BeginInit();
             this.SuspendLayout();
             // 
@@ -52,50 +58,6 @@
             this.label10.TabIndex = 12;
             this.label10.Text = "SN";
             // 
-            // sncode
-            // 
-            this.sncode.AllPower = null;
-            this.sncode.BackColor = System.Drawing.Color.White;
-            this.sncode.ID = null;
-            this.sncode.Location = new System.Drawing.Point(146, 790);
-            this.sncode.Margin = new System.Windows.Forms.Padding(4);
-            this.sncode.Name = "sncode";
-            this.sncode.Power = null;
-            this.sncode.Size = new System.Drawing.Size(334, 35);
-            this.sncode.Str = null;
-            this.sncode.Str1 = null;
-            this.sncode.Str2 = null;
-            this.sncode.TabIndex = 14;
-            this.sncode.KeyDown += new System.Windows.Forms.KeyEventHandler(this.sncode_KeyDown);
-            // 
-            // cancel
-            // 
-            this.cancel.AllPower = null;
-            this.cancel.BackColor = System.Drawing.Color.Transparent;
-            this.cancel.DownImage = ((System.Drawing.Image)(resources.GetObject("cancel.DownImage")));
-            this.cancel.Image = null;
-            this.cancel.IsShowBorder = true;
-            this.cancel.Location = new System.Drawing.Point(580, 790);
-            this.cancel.Margin = new System.Windows.Forms.Padding(4);
-            this.cancel.MoveImage = ((System.Drawing.Image)(resources.GetObject("cancel.MoveImage")));
-            this.cancel.Name = "cancel";
-            this.cancel.NormalImage = ((System.Drawing.Image)(resources.GetObject("cancel.NormalImage")));
-            this.cancel.Power = null;
-            this.cancel.Size = new System.Drawing.Size(118, 38);
-            this.cancel.TabIndex = 17;
-            this.cancel.Text = "重新核对";
-            this.cancel.UseVisualStyleBackColor = false;
-            // 
-            // OperateResult
-            // 
-            this.OperateResult.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.OperateResult.Location = new System.Drawing.Point(1223, 137);
-            this.OperateResult.Margin = new System.Windows.Forms.Padding(4);
-            this.OperateResult.Name = "OperateResult";
-            this.OperateResult.Size = new System.Drawing.Size(518, 624);
-            this.OperateResult.TabIndex = 10;
-            this.OperateResult.Text = "";
-            // 
             // CheckSnDGV
             // 
             this.CheckSnDGV.AllowUserToAddRows = false;
@@ -105,10 +67,88 @@
             this.pd_checksn});
             this.CheckSnDGV.Location = new System.Drawing.Point(72, 137);
             this.CheckSnDGV.Name = "CheckSnDGV";
+            this.CheckSnDGV.RowHeadersWidth = 82;
             this.CheckSnDGV.RowTemplate.Height = 37;
             this.CheckSnDGV.Size = new System.Drawing.Size(1117, 624);
             this.CheckSnDGV.TabIndex = 18;
             // 
+            // label1
+            // 
+            this.label1.AutoSize = true;
+            this.label1.Font = new System.Drawing.Font("宋体", 24F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.label1.Location = new System.Drawing.Point(66, 46);
+            this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(283, 64);
+            this.label1.TabIndex = 19;
+            this.label1.Text = "卡通箱号";
+            // 
+            // pa_makecode_label
+            // 
+            this.pa_makecode_label.AutoSize = true;
+            this.pa_makecode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.pa_makecode_label.Location = new System.Drawing.Point(1156, 68);
+            this.pa_makecode_label.Margin = new System.Windows.Forms.Padding(6, 0, 6, 0);
+            this.pa_makecode_label.Name = "pa_makecode_label";
+            this.pa_makecode_label.Size = new System.Drawing.Size(146, 41);
+            this.pa_makecode_label.TabIndex = 110;
+            this.pa_makecode_label.Text = "制造单号";
+            // 
+            // label2
+            // 
+            this.label2.AutoSize = true;
+            this.label2.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.label2.Location = new System.Drawing.Point(691, 787);
+            this.label2.Margin = new System.Windows.Forms.Padding(6, 0, 6, 0);
+            this.label2.Name = "label2";
+            this.label2.Size = new System.Drawing.Size(146, 41);
+            this.label2.TabIndex = 112;
+            this.label2.Text = "核對數量";
+            // 
+            // dataGridViewTextBoxColumn1
+            // 
+            this.dataGridViewTextBoxColumn1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.AllCells;
+            this.dataGridViewTextBoxColumn1.DataPropertyName = "pd_barcode";
+            this.dataGridViewTextBoxColumn1.HeaderText = "箱内序列号";
+            this.dataGridViewTextBoxColumn1.MinimumWidth = 10;
+            this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
+            this.dataGridViewTextBoxColumn1.Width = 175;
+            // 
+            // dataGridViewTextBoxColumn2
+            // 
+            this.dataGridViewTextBoxColumn2.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.AllCells;
+            this.dataGridViewTextBoxColumn2.DataPropertyName = "pd_checksn";
+            this.dataGridViewTextBoxColumn2.HeaderText = "扫描SN号";
+            this.dataGridViewTextBoxColumn2.MinimumWidth = 10;
+            this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
+            this.dataGridViewTextBoxColumn2.Width = 151;
+            // 
+            // CheckNum
+            // 
+            this.CheckNum.AutoSize = true;
+            this.CheckNum.CutLength = null;
+            this.CheckNum.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.CheckNum.Location = new System.Drawing.Point(886, 787);
+            this.CheckNum.Margin = new System.Windows.Forms.Padding(6, 0, 6, 0);
+            this.CheckNum.MaximumSize = new System.Drawing.Size(300, 0);
+            this.CheckNum.Name = "CheckNum";
+            this.CheckNum.Size = new System.Drawing.Size(0, 41);
+            this.CheckNum.TabIndex = 113;
+            this.CheckNum.Tag = "1";
+            // 
+            // pa_makecode
+            // 
+            this.pa_makecode.AutoSize = true;
+            this.pa_makecode.CutLength = null;
+            this.pa_makecode.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.pa_makecode.Location = new System.Drawing.Point(1324, 68);
+            this.pa_makecode.Margin = new System.Windows.Forms.Padding(6, 0, 6, 0);
+            this.pa_makecode.MaximumSize = new System.Drawing.Size(300, 0);
+            this.pa_makecode.Name = "pa_makecode";
+            this.pa_makecode.Size = new System.Drawing.Size(0, 41);
+            this.pa_makecode.TabIndex = 111;
+            this.pa_makecode.Tag = "1";
+            // 
             // pa_outboxcode
             // 
             this.pa_outboxcode.AllPower = null;
@@ -126,22 +166,12 @@
             this.pa_outboxcode.TabIndex = 20;
             this.pa_outboxcode.KeyDown += new System.Windows.Forms.KeyEventHandler(this.pa_outboxcode_KeyDown);
             // 
-            // label1
-            // 
-            this.label1.AutoSize = true;
-            this.label1.Font = new System.Drawing.Font("宋体", 24F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label1.Location = new System.Drawing.Point(66, 46);
-            this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
-            this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(284, 64);
-            this.label1.TabIndex = 19;
-            this.label1.Text = "卡通箱号";
-            // 
             // pd_barcode
             // 
             this.pd_barcode.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.AllCells;
             this.pd_barcode.DataPropertyName = "pd_barcode";
             this.pd_barcode.HeaderText = "箱内序列号";
+            this.pd_barcode.MinimumWidth = 10;
             this.pd_barcode.Name = "pd_barcode";
             this.pd_barcode.Width = 175;
             // 
@@ -150,14 +180,65 @@
             this.pd_checksn.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.AllCells;
             this.pd_checksn.DataPropertyName = "pd_checksn";
             this.pd_checksn.HeaderText = "扫描SN号";
+            this.pd_checksn.MinimumWidth = 10;
             this.pd_checksn.Name = "pd_checksn";
             this.pd_checksn.Width = 151;
             // 
+            // cancel
+            // 
+            this.cancel.AllPower = null;
+            this.cancel.BackColor = System.Drawing.Color.Transparent;
+            this.cancel.DownImage = ((System.Drawing.Image)(resources.GetObject("cancel.DownImage")));
+            this.cancel.Image = null;
+            this.cancel.IsShowBorder = true;
+            this.cancel.Location = new System.Drawing.Point(528, 787);
+            this.cancel.Margin = new System.Windows.Forms.Padding(4);
+            this.cancel.MoveImage = ((System.Drawing.Image)(resources.GetObject("cancel.MoveImage")));
+            this.cancel.Name = "cancel";
+            this.cancel.NormalImage = ((System.Drawing.Image)(resources.GetObject("cancel.NormalImage")));
+            this.cancel.Power = null;
+            this.cancel.Size = new System.Drawing.Size(118, 38);
+            this.cancel.TabIndex = 17;
+            this.cancel.Text = "重新核对";
+            this.cancel.UseVisualStyleBackColor = false;
+            this.cancel.Visible = false;
+            this.cancel.Click += new System.EventHandler(this.cancel_Click);
+            // 
+            // sncode
+            // 
+            this.sncode.AllPower = null;
+            this.sncode.BackColor = System.Drawing.Color.White;
+            this.sncode.ID = null;
+            this.sncode.Location = new System.Drawing.Point(146, 790);
+            this.sncode.Margin = new System.Windows.Forms.Padding(4);
+            this.sncode.Name = "sncode";
+            this.sncode.Power = null;
+            this.sncode.Size = new System.Drawing.Size(334, 35);
+            this.sncode.Str = null;
+            this.sncode.Str1 = null;
+            this.sncode.Str2 = null;
+            this.sncode.TabIndex = 14;
+            this.sncode.KeyDown += new System.Windows.Forms.KeyEventHandler(this.sncode_KeyDown);
+            // 
+            // OperateResult
+            // 
+            this.OperateResult.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.OperateResult.Location = new System.Drawing.Point(1223, 137);
+            this.OperateResult.Margin = new System.Windows.Forms.Padding(4);
+            this.OperateResult.Name = "OperateResult";
+            this.OperateResult.Size = new System.Drawing.Size(518, 624);
+            this.OperateResult.TabIndex = 10;
+            this.OperateResult.Text = "";
+            // 
             // Make_OutBoxSnCheck
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(12F, 24F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(1772, 866);
+            this.Controls.Add(this.CheckNum);
+            this.Controls.Add(this.label2);
+            this.Controls.Add(this.pa_makecode);
+            this.Controls.Add(this.pa_makecode_label);
             this.Controls.Add(this.pa_outboxcode);
             this.Controls.Add(this.label1);
             this.Controls.Add(this.CheckSnDGV);
@@ -173,7 +254,7 @@
             this.Load += new System.EventHandler(this.Make_LabelCheck_Load);
             this.SizeChanged += new System.EventHandler(this.Make_LabelCheck_SizeChanged);
             ((System.ComponentModel.ISupportInitialize)(this.CheckSnDGV)).EndInit();
-            this.ResumeLayout(true);
+            this.ResumeLayout(false);
             this.PerformLayout();
 
         }
@@ -188,5 +269,11 @@
         private System.Windows.Forms.Label label1;
         private System.Windows.Forms.DataGridViewTextBoxColumn pd_barcode;
         private System.Windows.Forms.DataGridViewTextBoxColumn pd_checksn;
+        private CustomControl.ValueLabel.ValueLabel pa_makecode;
+        private System.Windows.Forms.Label pa_makecode_label;
+        private CustomControl.ValueLabel.ValueLabel CheckNum;
+        private System.Windows.Forms.Label label2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
     }
 }

+ 29 - 2
UAS_MES_LGDZ/FunctionCode/Make/Make_OutBoxSnCheck.cs

@@ -38,12 +38,14 @@ namespace UAS_MES_NEW.Make
             sql = new LogStringBuilder();
             dh = SystemInf.dh;
         }
-
+        string pa_nextstep = "";
         private void Make_LabelCheck_SizeChanged(object sender, EventArgs e)
         {
             asc.controlAutoSize(this);
         }
+        string ErrorMessage = "";
 
+        int CheckRow = 0;
         private void sncode_KeyDown(object sender, KeyEventArgs e)
         {
             //判断是enter事件
@@ -54,6 +56,7 @@ namespace UAS_MES_NEW.Make
                     OperateResult.AppendText("<<输入不能为空\n", Color.Red);
                     return;
                 }
+
                 bool FindSN = false;
                 bool AllCheck = true;
                 dt = (DataTable)dh.ExecuteSql("select ms_sncode from makeserial where ms_imei1='" + sncode.Text + "' order by ms_id desc", "select");
@@ -85,6 +88,7 @@ namespace UAS_MES_NEW.Make
                         }
                     }
                 }
+             
                 for (int i = 0; i < CheckSnDGV.Rows.Count; i++)
                 {
                     if (CheckSnDGV.Rows[i].Cells["pd_barcode"].Value.ToString() == sncode.Text)
@@ -96,6 +100,10 @@ namespace UAS_MES_NEW.Make
                     {
                         AllCheck = false;
                     }
+                    else
+                    {
+                        CheckRow = CheckRow + 1;
+                    }
                 }
                 if (FindSN)
                 {
@@ -105,8 +113,14 @@ namespace UAS_MES_NEW.Make
                 {
                     OperateResult.AppendText("<<SN" + sncode.Text + "校验失败\n", Color.Red, sncode);
                 }
+                CheckNum.Text = CheckRow + "/" + CheckSnDGV.Rows.Count;
                 if (AllCheck)
                 {
+                    if (pa_nextstep != "" && pa_nextstep == User.CurrentStepCode)
+                    {
+                        LogicHandler.OutBoxStepPass(pa_outboxcode.Text, pa_makecode.Text, User.UserSourceCode, User.UserCode, "栈板采集成功,栈板号:" + pa_outboxcode.Text, "栈板采集", out ErrorMessage);
+                    }
+                    CheckRow = 0;
                     SetCheck set = new SetCheck("OK", Color.Green);
                     BaseUtil.SetFormCenter(set);
                     set.ShowDialog();
@@ -119,10 +133,18 @@ namespace UAS_MES_NEW.Make
         {
             if (e.KeyCode == Keys.Enter)
             {
-                dt = (DataTable)dh.ExecuteSql("select pd_barcode from packagedetail where pd_outboxcode='" + pa_outboxcode.Text + "'", "select");
+                dt = (DataTable)dh.ExecuteSql("select pd_barcode,pd_makecode pa_makecode,pa_nextstep from packagedetail left join package on pa_id=pd_paid where pd_outboxcode='" + pa_outboxcode.Text + "'", "select");
                 if (dt.Rows.Count > 0)
                 {
+                    CheckNum.Text = CheckRow + "/" + CheckSnDGV.Rows.Count;
+                    pa_nextstep = dt.Rows[0]["pa_nextstep"].ToString();
+                    if (pa_nextstep != User.CurrentStepCode && pa_nextstep != "")
+                    {
+                        OperateResult.AppendText(">>箱号" + pa_outboxcode.Text + "的下一工序" + pa_nextstep + "不是当前岗位资源对应工序\n", Color.Red);
+                        return;
+                    }
                     BaseUtil.FillDgvWithDataTable(CheckSnDGV, dt);
+                    BaseUtil.SetFormValue(this.Controls, dt);
                     sncode.Focus();
                 }
                 else
@@ -131,5 +153,10 @@ namespace UAS_MES_NEW.Make
                 }
             }
         }
+
+        private void cancel_Click(object sender, EventArgs e)
+        {
+
+        }
     }
 }

+ 6 - 6
UAS_MES_LGDZ/FunctionCode/Make/Make_OutBoxSnCheck.resx

@@ -117,6 +117,12 @@
   <resheader name="writer">
     <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
   </resheader>
+  <metadata name="pd_barcode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="pd_checksn.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
   <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
   <data name="cancel.DownImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
@@ -156,10 +162,4 @@
         ROJSU3qXjMKwG/vjzEz/skOI3Zqgv7AAAAAASUVORK5CYII=
 </value>
   </data>
-  <metadata name="pd_barcode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="pd_checksn.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
 </root>

+ 29 - 14
UAS_MES_LGDZ/FunctionCode/Make/Make_RePrintLabel.Designer.cs

@@ -44,6 +44,7 @@
             this.pr_detail = new System.Windows.Forms.Label();
             this.AllowInBox = new System.Windows.Forms.CheckBox();
             this.groupBoxWithBorder1 = new UAS_MES_NEW.CustomControl.GroupBoxWithBorder.GroupBoxWithBorder();
+            this.BigBox = new System.Windows.Forms.RadioButton();
             this.CartonBox = new System.Windows.Forms.RadioButton();
             this.fuselagel = new System.Windows.Forms.RadioButton();
             this.giftBox = new System.Windows.Forms.RadioButton();
@@ -53,7 +54,7 @@
             this.inputText = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SnCollectionBox();
             this.PrintLabel = new UAS_MES_NEW.CustomControl.ComBoxWithFocus.ComboxWithTip(this.components);
             this.Printer = new UAS_MES_NEW.CustomControl.ComBoxWithFocus.PrinterCombox();
-            this.BigBox = new System.Windows.Forms.RadioButton();
+            this.Pallte = new System.Windows.Forms.RadioButton();
             this.groupBoxWithBorder1.SuspendLayout();
             this.SuspendLayout();
             // 
@@ -199,6 +200,7 @@
             // groupBoxWithBorder1
             // 
             this.groupBoxWithBorder1.BorderColor = System.Drawing.Color.Black;
+            this.groupBoxWithBorder1.Controls.Add(this.Pallte);
             this.groupBoxWithBorder1.Controls.Add(this.BigBox);
             this.groupBoxWithBorder1.Controls.Add(this.CartonBox);
             this.groupBoxWithBorder1.Controls.Add(this.fuselagel);
@@ -214,11 +216,23 @@
             this.groupBoxWithBorder1.Text = "打印类型";
             this.groupBoxWithBorder1.TextColor = System.Drawing.Color.Black;
             // 
+            // BigBox
+            // 
+            this.BigBox.AutoSize = true;
+            this.BigBox.Font = new System.Drawing.Font("微软雅黑", 12F);
+            this.BigBox.Location = new System.Drawing.Point(597, 81);
+            this.BigBox.Margin = new System.Windows.Forms.Padding(4, 2, 4, 2);
+            this.BigBox.Name = "BigBox";
+            this.BigBox.Size = new System.Drawing.Size(177, 45);
+            this.BigBox.TabIndex = 4;
+            this.BigBox.Text = "大箱打印";
+            this.BigBox.UseVisualStyleBackColor = true;
+            // 
             // CartonBox
             // 
             this.CartonBox.AutoSize = true;
             this.CartonBox.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.CartonBox.Location = new System.Drawing.Point(474, 73);
+            this.CartonBox.Location = new System.Drawing.Point(295, 81);
             this.CartonBox.Margin = new System.Windows.Forms.Padding(4, 2, 4, 2);
             this.CartonBox.Name = "CartonBox";
             this.CartonBox.Size = new System.Drawing.Size(216, 45);
@@ -231,7 +245,7 @@
             // 
             this.fuselagel.AutoSize = true;
             this.fuselagel.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.fuselagel.Location = new System.Drawing.Point(1127, 73);
+            this.fuselagel.Location = new System.Drawing.Point(875, 81);
             this.fuselagel.Margin = new System.Windows.Forms.Padding(4, 2, 4, 2);
             this.fuselagel.Name = "fuselagel";
             this.fuselagel.Size = new System.Drawing.Size(209, 45);
@@ -245,7 +259,7 @@
             this.giftBox.AutoSize = true;
             this.giftBox.Checked = true;
             this.giftBox.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.giftBox.Location = new System.Drawing.Point(111, 73);
+            this.giftBox.Location = new System.Drawing.Point(50, 81);
             this.giftBox.Margin = new System.Windows.Forms.Padding(4, 2, 4, 2);
             this.giftBox.Name = "giftBox";
             this.giftBox.Size = new System.Drawing.Size(177, 45);
@@ -335,17 +349,17 @@
             this.Printer.Size = new System.Drawing.Size(296, 50);
             this.Printer.TabIndex = 186;
             // 
-            // BigBox
+            // Pallte
             // 
-            this.BigBox.AutoSize = true;
-            this.BigBox.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.BigBox.Location = new System.Drawing.Point(813, 73);
-            this.BigBox.Margin = new System.Windows.Forms.Padding(4, 2, 4, 2);
-            this.BigBox.Name = "BigBox";
-            this.BigBox.Size = new System.Drawing.Size(177, 45);
-            this.BigBox.TabIndex = 4;
-            this.BigBox.Text = "大箱打印";
-            this.BigBox.UseVisualStyleBackColor = true;
+            this.Pallte.AutoSize = true;
+            this.Pallte.Font = new System.Drawing.Font("微软雅黑", 12F);
+            this.Pallte.Location = new System.Drawing.Point(1172, 81);
+            this.Pallte.Margin = new System.Windows.Forms.Padding(4, 2, 4, 2);
+            this.Pallte.Name = "Pallte";
+            this.Pallte.Size = new System.Drawing.Size(209, 45);
+            this.Pallte.TabIndex = 5;
+            this.Pallte.Text = "栈板标打印";
+            this.Pallte.UseVisualStyleBackColor = true;
             // 
             // Make_RePrintLabel
             // 
@@ -412,5 +426,6 @@
         private CustomControl.GroupBoxWithBorder.GroupBoxWithBorder groupBoxWithBorder1;
         private System.Windows.Forms.CheckBox AllowInBox;
         private System.Windows.Forms.RadioButton BigBox;
+        private System.Windows.Forms.RadioButton Pallte;
     }
 }

+ 62 - 2
UAS_MES_LGDZ/FunctionCode/Make/Make_RePrintLabel.cs

@@ -105,6 +105,11 @@ namespace UAS_MES_NEW.Make
                 OperateResult.AppendText(">>请输入大箱号\n", Color.Black);
                 clearAll();
             }
+            else if (btn.Name == "Pallte" && btn.Checked)
+            {
+                OperateResult.AppendText(">>请输入栈板号\n", Color.Black);
+                clearAll();
+            }
         }
 
         private void inputText_KeyDown(object sender, KeyEventArgs e)
@@ -165,7 +170,7 @@ namespace UAS_MES_NEW.Make
                 //打印类型为卡通箱
                 else if (CartonBox.Checked)
                 {
-                    dt = (DataTable)dh.ExecuteSql("select ms_outboxcode from makeserial where ms_outboxcode='"+inputText.Text+"' or ms_imei2='"+inputText.Text+"' or ms_imei1='" + inputText.Text + "' order by ms_id desc", "select");
+                    dt = (DataTable)dh.ExecuteSql("select ms_outboxcode from makeserial where ms_outboxcode='" + inputText.Text + "' or ms_imei2='" + inputText.Text + "' or ms_imei1='" + inputText.Text + "' order by ms_id desc", "select");
                     if (dt.Rows.Count > 0)
                     {
                         inputText.Text = dt.Rows[0]["ms_outboxcode"].ToString();
@@ -225,6 +230,37 @@ namespace UAS_MES_NEW.Make
                     inputValue.Text = inputText.Text;
                     inputText.Text = "";
                 }
+                else if (Pallte.Checked)
+                {
+                    dt = (DataTable)dh.ExecuteSql("select ms_outboxcode from makeserial where ms_imei1='" + inputText.Text + "' order by ms_id desc", "select");
+                    if (dt.Rows.Count > 0)
+                    {
+                        inputText.Text = dt.Rows[0]["ms_outboxcode"].ToString();
+                    }
+                    else
+                    {
+                        dt = (DataTable)dh.ExecuteSql("select ms_outboxcode from makeserial where ms_imei2='" + inputText.Text + "' order by ms_id desc", "select");
+                        if (dt.Rows.Count > 0)
+                        {
+                            inputText.Text = dt.Rows[0]["ms_outboxcode"].ToString();
+                        }
+                    }
+                    //查询箱号是否存在
+                    dt = (DataTable)dh.ExecuteSql("select pa_id,pa_prodcode pr_code,pa_makecode ms_makecode,pr_detail from package left join product on pr_code=pa_prodcode where pa_outboxcode='" + inputText.Text + "' and pa_type=3", "select");
+                    if (dt.Rows.Count == 0)
+                    {
+                        //无值,返回提示用户“箱号不存在”, “>>请输入卡通箱号”
+                        OperateResult.AppendText("<<栈板:" + inputText.Text + "不存在\n", Color.Red, inputText);
+                        OperateResult.AppendText(">>请输入栈板号\n", Color.Black);
+                        return;
+                    }
+                    //界面赋值
+                    BaseUtil.SetFormValue(this.Controls, dt);
+                    //有值,可以打
+                    //展示产品编号和标签模板到界面
+                    inputValue.Text = inputText.Text;
+                    inputText.Text = "";
+                }
                 print_Click(sender, new EventArgs());
             }
 
@@ -242,8 +278,10 @@ namespace UAS_MES_NEW.Make
                 type = "彩盒标";
             else if (CartonBox.Checked)
                 type = "卡通箱标";
-            else
+            else if (BigBox.Checked)
                 type = "大箱标";
+            else
+                type = "栈板标";
             listA = (DataTable)dh.ExecuteSql("select la_id,la_url,la_isdefault,replace(LA_SOFTTYPE,';',',')LA_SOFTTYPE from label where la_prodcode='" + pr_code.Text + "'  and la_templatetype='" + type + "' and la_statuscode='AUDITED' order by la_isdefault", "select");
             if (listA.Rows.Count == 0)
             {
@@ -369,6 +407,28 @@ namespace UAS_MES_NEW.Make
                 //    putInfo2MakeDown();
                 //}
             }
+            else if (Pallte.Checked)
+            {
+                //select pa_downstatus from package where pa_outboxcode=? 输入值code
+                mapB = (DataTable)dh.ExecuteSql("select pa_downstatus from package where pa_outboxcode='" + inputValue.Text + "'", "select");
+                //无值提示用户箱号错误,不存在。
+                if (mapB.Rows.Count == 0)
+                {
+                    OperateResult.AppendText("<<栈板号:" + inputValue.Text + "错误,不存在\n", Color.Red);
+                    return;
+                }
+                if (Print.BarTender(Tag.ToString(), ref engine, PrintLabel.Text, PrintLabel.SelectedValue.ToString(), Printer.Text, inputValue.Text, int.Parse(printNum.Text), ms_makecode.Text, pr_code.Text, "栈板标", "-1", out errorMessage))
+                {
+                    //判断通过,打印
+                    OperateResult.AppendText("<<打印成功\n", Color.Green);
+                }
+                else
+                {
+                    OperateResult.AppendText(errorMessage + "\n", Color.Red);
+                }
+                //打印成功,记录日志commandlog , cl_operate彩盒或者机身标补打印,cl_result补打印成功
+                LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ms_makecode.Text, User.UserLineCode, User.UserSourceCode, "栈板标签补打印,栈板号:" + inputValue.Text, "补打印成功", inputValue.Text, "");
+            }
         }
 
 

+ 1 - 1
UAS_MES_LGDZ/FunctionCode/Packing/Packing_PackageCollectionWeigh_ReadLine1.cs

@@ -174,7 +174,7 @@ namespace UAS_MES_NEW.Packing
             sql.Clear();
             sql.Append("select pa_prodcode,pr_cartonmaxw,pa_salecode,pa_remark,pa_makecode,pr_cartonunit,pr_code,pr_cartonminw,pr_cartongw,pa_outboxcode,pa_sccode,nvl(pa_downstatus,0) pa_downstatus,pa_checkno,");
             sql.Append("pa_status,pr_packrule,pr_detail,nvl(pr_sendchecktype,'LineCode')pr_sendchecktype,pa_packageqty,nvl(pa_standardqty,0)pa_standardqty,nvl(pr_outboxinnerqty,0)pr_outboxinnerqty,nvl(PR_CHECKCARTONW,'0') PR_CHECKCARTONW,pa_currentqty from package left join ");
-            sql.Append("product on pa_prodcode=pr_code where pa_outboxcode='" + pa_outboxcode.Text + "'");
+            sql.Append(" packagedetail on pd_paid=pa_id left join product on pd_prodcode=pr_code where pa_outboxcode='" + pa_outboxcode.Text + "'");
             Err = "箱号";
             DataTable dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
             if (dt.Rows.Count > 0)

+ 1 - 1
UAS_MES_LGDZ/FunctionCode/Special/Special_CancelCollection.cs

@@ -24,7 +24,7 @@ namespace UAS_MES_NEW.Special
         private void Confirm_Click(object sender, EventArgs e)
         {
             //获取序列号的途程
-            DataTable dt = (DataTable)dh.ExecuteSql("select ms_outboxcode,ms_sncode,ms_firstsn,ms_id,ms_nextstepcode,ms_currentstepcode,ms_makecode,ms_status,ms_checkno,ms_craftcode,ms_prodcode,ms_stepcode from makeserial where (ms_sncode='" + sn_code.Text + "'  or ms_imei1='" + sn_code.Text + "' and ms_imei2='" + sn_code.Text + "')and ms_makecode='" + ma_code.Text + "' order by ms_id desc", "select");
+            DataTable dt = (DataTable)dh.ExecuteSql("select ms_outboxcode,ms_sncode,ms_firstsn,ms_id,ms_nextstepcode,ms_currentstepcode,ms_makecode,ms_status,ms_checkno,ms_craftcode,ms_prodcode,ms_stepcode from makeserial where (ms_sncode='" + sn_code.Text + "'  or ms_imei1='" + sn_code.Text + "' or ms_imei2='" + sn_code.Text + "')and ms_makecode='" + ma_code.Text + "' order by ms_id desc", "select");
             if (dt.Rows.Count > 0)
             {
                 string pr_code = dt.Rows[0]["ms_prodcode"].ToString();

+ 3 - 1
UAS_MES_LGDZ/FunctionCode/SystemSetting/SystemSetting_PrinterTest.cs

@@ -273,9 +273,11 @@ namespace UAS_MES_NEW.SystemSetting
         {
             Dbfind = ma_code.ReturnData;
             BaseUtil.SetFormValue(this.Controls, Dbfind);
-            DataTable dt = (DataTable)dh.ExecuteSql("select ma_qty,ma_prodcode,pr_detail,ma_printnum from make left join product on ma_prodcode=pr_code left join (select count(1)ma_printnum,mil_makecode from makeimeilist where mil_printstatus=-1 group by mil_makecode) on mil_makecode=ma_code where ma_code='" + ma_code.Text + "'", "select");
+            DataTable dt = (DataTable)dh.ExecuteSql("select ma_submodel,ma_color,ma_qty,ma_prodcode,pr_detail,ma_printnum from make left join product on ma_prodcode=pr_code left join (select count(1)ma_printnum,mil_makecode from makeimeilist where mil_printstatus=-1 group by mil_makecode) on mil_makecode=ma_code where ma_code='" + ma_code.Text + "'", "select");
             if (dt.Rows.Count > 0)
             {
+                Color.Text = dt.Rows[0]["ma_color"].ToString();
+                MachineType.Text = dt.Rows[0]["ma_submodel"].ToString();
                 pr_code.Text = dt.Rows[0]["ma_prodcode"].ToString();
                 ma_qty.Text = dt.Rows[0]["ma_qty"].ToString();
                 ma_printcount.Text = dt.Rows[0]["ma_printnum"].ToString();

二進制
UAS_MES_LGDZ/Resources/Sound/1454.wav


二進制
UAS_MES_LGDZ/Resources/Sound/3853.wav