Browse Source

优化弹出提示,新增条码核对过站

yhluo 5 days ago
parent
commit
30e9e186e8

+ 602 - 0
UAS_MES_YTDZ/FunctionCode/Make/Make_ShipmentVerify.Designer.cs

@@ -0,0 +1,602 @@
+namespace UAS_MES_NEW.Make
+{
+    partial class Make_ShipmentVerify
+    {
+        /// <summary>
+        /// Required designer variable.
+        /// </summary>
+        private System.ComponentModel.IContainer components = null;
+
+        /// <summary>
+        /// Clean up any resources being used.
+        /// </summary>
+        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
+        protected override void Dispose(bool disposing)
+        {
+            if (disposing && (components != null))
+            {
+                components.Dispose();
+            }
+            base.Dispose(disposing);
+        }
+
+        #region Windows Form Designer generated code
+
+        /// <summary>
+        /// Required method for Designer support - do not modify
+        /// the contents of this method with the code editor.
+        /// </summary>
+        private void InitializeComponent()
+        {
+            this.containerBox = new System.Windows.Forms.Panel();
+            this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
+            this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel();
+            this.Msg1 = new UAS_MES_NEW.CustomControl.RichText.RichTextAutoBottom();
+            this.panel1 = new System.Windows.Forms.Panel();
+            this.claerBtn = new System.Windows.Forms.Button();
+            this.Delete = new System.Windows.Forms.Button();
+            this.Confirm = new System.Windows.Forms.Button();
+            this.PanelQtyVal = new System.Windows.Forms.TextBox();
+            this.PanelQtyLab = new System.Windows.Forms.Label();
+            this.snLab = new System.Windows.Forms.Label();
+            this.snVal = new System.Windows.Forms.TextBox();
+            this.groupBox1 = new System.Windows.Forms.GroupBox();
+            this.dgv = new System.Windows.Forms.DataGridView();
+            this.dataGridViewCheckBoxColumn1 = new System.Windows.Forms.DataGridViewCheckBoxColumn();
+            this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.SNDetails = new UAS_MES_NEW.CustomControl.GroupBoxWithBorder.GroupBoxWithBorder();
+            this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
+            this.productName = new System.Windows.Forms.Label();
+            this.productCode = new System.Windows.Forms.Label();
+            this.workOrder = new System.Windows.Forms.Label();
+            this.label4 = new System.Windows.Forms.Label();
+            this.label1 = new System.Windows.Forms.Label();
+            this.label3 = new System.Windows.Forms.Label();
+            this.label2 = new System.Windows.Forms.Label();
+            this.serialNumber = new System.Windows.Forms.Label();
+            this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn11 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dataGridViewTextBoxColumn12 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.isDel = new System.Windows.Forms.DataGridViewCheckBoxColumn();
+            this.rn = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ms_makecode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ms_sncode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.containerBox.SuspendLayout();
+            this.tableLayoutPanel2.SuspendLayout();
+            this.tableLayoutPanel3.SuspendLayout();
+            this.panel1.SuspendLayout();
+            this.groupBox1.SuspendLayout();
+            ((System.ComponentModel.ISupportInitialize)(this.dgv)).BeginInit();
+            this.SNDetails.SuspendLayout();
+            this.tableLayoutPanel1.SuspendLayout();
+            this.SuspendLayout();
+            // 
+            // containerBox
+            // 
+            this.containerBox.Controls.Add(this.tableLayoutPanel2);
+            this.containerBox.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.containerBox.Location = new System.Drawing.Point(0, 123);
+            this.containerBox.Name = "containerBox";
+            this.containerBox.Size = new System.Drawing.Size(1280, 597);
+            this.containerBox.TabIndex = 28;
+            // 
+            // tableLayoutPanel2
+            // 
+            this.tableLayoutPanel2.ColumnCount = 2;
+            this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 60F));
+            this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 40F));
+            this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
+            this.tableLayoutPanel2.Controls.Add(this.tableLayoutPanel3, 1, 0);
+            this.tableLayoutPanel2.Controls.Add(this.groupBox1, 0, 0);
+            this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.tableLayoutPanel2.Location = new System.Drawing.Point(0, 0);
+            this.tableLayoutPanel2.Name = "tableLayoutPanel2";
+            this.tableLayoutPanel2.RowCount = 1;
+            this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
+            this.tableLayoutPanel2.Size = new System.Drawing.Size(1280, 597);
+            this.tableLayoutPanel2.TabIndex = 2;
+            // 
+            // tableLayoutPanel3
+            // 
+            this.tableLayoutPanel3.ColumnCount = 1;
+            this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
+            this.tableLayoutPanel3.Controls.Add(this.Msg1, 0, 1);
+            this.tableLayoutPanel3.Controls.Add(this.panel1, 0, 0);
+            this.tableLayoutPanel3.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.tableLayoutPanel3.Location = new System.Drawing.Point(771, 3);
+            this.tableLayoutPanel3.Name = "tableLayoutPanel3";
+            this.tableLayoutPanel3.RowCount = 2;
+            this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 40F));
+            this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 60F));
+            this.tableLayoutPanel3.Size = new System.Drawing.Size(506, 591);
+            this.tableLayoutPanel3.TabIndex = 2;
+            // 
+            // Msg1
+            // 
+            this.Msg1.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.Msg1.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.Msg1.Location = new System.Drawing.Point(4, 240);
+            this.Msg1.Margin = new System.Windows.Forms.Padding(4);
+            this.Msg1.Name = "Msg1";
+            this.Msg1.Size = new System.Drawing.Size(498, 347);
+            this.Msg1.TabIndex = 54;
+            this.Msg1.Text = "";
+            // 
+            // panel1
+            // 
+            this.panel1.Controls.Add(this.claerBtn);
+            this.panel1.Controls.Add(this.Delete);
+            this.panel1.Controls.Add(this.Confirm);
+            this.panel1.Controls.Add(this.PanelQtyVal);
+            this.panel1.Controls.Add(this.PanelQtyLab);
+            this.panel1.Controls.Add(this.snLab);
+            this.panel1.Controls.Add(this.snVal);
+            this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.panel1.Location = new System.Drawing.Point(3, 3);
+            this.panel1.Name = "panel1";
+            this.panel1.Size = new System.Drawing.Size(500, 230);
+            this.panel1.TabIndex = 1;
+            // 
+            // claerBtn
+            // 
+            this.claerBtn.Cursor = System.Windows.Forms.Cursors.Hand;
+            this.claerBtn.Font = new System.Drawing.Font("微软雅黑", 9F);
+            this.claerBtn.Location = new System.Drawing.Point(363, 182);
+            this.claerBtn.Name = "claerBtn";
+            this.claerBtn.Size = new System.Drawing.Size(120, 35);
+            this.claerBtn.TabIndex = 21;
+            this.claerBtn.Text = "清除提示";
+            this.claerBtn.UseVisualStyleBackColor = true;
+            this.claerBtn.Click += new System.EventHandler(this.claerBtn_Click);
+            // 
+            // Delete
+            // 
+            this.Delete.Cursor = System.Windows.Forms.Cursors.Hand;
+            this.Delete.Location = new System.Drawing.Point(227, 182);
+            this.Delete.Name = "Delete";
+            this.Delete.Size = new System.Drawing.Size(80, 32);
+            this.Delete.TabIndex = 20;
+            this.Delete.Text = "删除";
+            this.Delete.UseVisualStyleBackColor = true;
+            this.Delete.Click += new System.EventHandler(this.Delete_Click);
+            // 
+            // Confirm
+            // 
+            this.Confirm.Cursor = System.Windows.Forms.Cursors.Hand;
+            this.Confirm.Location = new System.Drawing.Point(90, 182);
+            this.Confirm.Name = "Confirm";
+            this.Confirm.Size = new System.Drawing.Size(80, 32);
+            this.Confirm.TabIndex = 19;
+            this.Confirm.Text = "确认";
+            this.Confirm.UseVisualStyleBackColor = true;
+            this.Confirm.Click += new System.EventHandler(this.Confirm_Click);
+            // 
+            // PanelQtyVal
+            // 
+            this.PanelQtyVal.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.PanelQtyVal.Location = new System.Drawing.Point(90, 30);
+            this.PanelQtyVal.Name = "PanelQtyVal";
+            this.PanelQtyVal.Size = new System.Drawing.Size(64, 31);
+            this.PanelQtyVal.TabIndex = 18;
+            // 
+            // PanelQtyLab
+            // 
+            this.PanelQtyLab.AutoSize = true;
+            this.PanelQtyLab.Font = new System.Drawing.Font("微软雅黑", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.PanelQtyLab.Location = new System.Drawing.Point(14, 30);
+            this.PanelQtyLab.Name = "PanelQtyLab";
+            this.PanelQtyLab.Size = new System.Drawing.Size(92, 27);
+            this.PanelQtyLab.TabIndex = 17;
+            this.PanelQtyLab.Text = "拼板数:";
+            // 
+            // snLab
+            // 
+            this.snLab.AutoSize = true;
+            this.snLab.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.snLab.Location = new System.Drawing.Point(14, 97);
+            this.snLab.Name = "snLab";
+            this.snLab.Size = new System.Drawing.Size(80, 28);
+            this.snLab.TabIndex = 0;
+            this.snLab.Text = "序列号:";
+            // 
+            // snVal
+            // 
+            this.snVal.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.snVal.Location = new System.Drawing.Point(90, 97);
+            this.snVal.Name = "snVal";
+            this.snVal.Size = new System.Drawing.Size(360, 31);
+            this.snVal.TabIndex = 1;
+            this.snVal.KeyDown += new System.Windows.Forms.KeyEventHandler(this.snVal_KeyDown);
+            // 
+            // groupBox1
+            // 
+            this.groupBox1.Controls.Add(this.dgv);
+            this.groupBox1.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.groupBox1.Location = new System.Drawing.Point(3, 3);
+            this.groupBox1.Name = "groupBox1";
+            this.groupBox1.Size = new System.Drawing.Size(762, 591);
+            this.groupBox1.TabIndex = 0;
+            this.groupBox1.TabStop = false;
+            this.groupBox1.Text = "拼板所属小板信息";
+            // 
+            // dgv
+            // 
+            this.dgv.AllowUserToAddRows = false;
+            this.dgv.AutoGenerateColumns = false;
+            this.dgv.AllowUserToDeleteRows = false;
+            this.dgv.AllowUserToResizeRows = false;
+            this.dgv.BackgroundColor = System.Drawing.SystemColors.Control;
+            this.dgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
+            this.dgv.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
+            this.isDel,
+            this.rn,
+            this.ms_makecode,
+            this.ms_sncode});
+            this.dgv.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.dgv.Location = new System.Drawing.Point(3, 27);
+            this.dgv.Name = "dgv";
+            this.dgv.RowHeadersVisible = false;
+            this.dgv.RowHeadersWidth = 62;
+            this.dgv.RowTemplate.Height = 30;
+            this.dgv.Size = new System.Drawing.Size(756, 561);
+            this.dgv.TabIndex = 1;
+            this.dgv.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgv_CellClick);
+            // 
+            // dataGridViewCheckBoxColumn1
+            // 
+            this.dataGridViewCheckBoxColumn1.HeaderText = "是否手补料";
+            this.dataGridViewCheckBoxColumn1.MinimumWidth = 8;
+            this.dataGridViewCheckBoxColumn1.Name = "dataGridViewCheckBoxColumn1";
+            this.dataGridViewCheckBoxColumn1.Width = 80;
+            // 
+            // dataGridViewTextBoxColumn1
+            // 
+            this.dataGridViewTextBoxColumn1.DataPropertyName = "rn";
+            this.dataGridViewTextBoxColumn1.HeaderText = "序号";
+            this.dataGridViewTextBoxColumn1.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
+            this.dataGridViewTextBoxColumn1.Width = 60;
+            // 
+            // dataGridViewTextBoxColumn2
+            // 
+            this.dataGridViewTextBoxColumn2.DataPropertyName = "ms_sncode";
+            this.dataGridViewTextBoxColumn2.HeaderText = "序列号";
+            this.dataGridViewTextBoxColumn2.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
+            this.dataGridViewTextBoxColumn2.ReadOnly = true;
+            this.dataGridViewTextBoxColumn2.Width = 130;
+            // 
+            // dataGridViewTextBoxColumn3
+            // 
+            this.dataGridViewTextBoxColumn3.DataPropertyName = "ps_linecode";
+            this.dataGridViewTextBoxColumn3.HeaderText = "线体";
+            this.dataGridViewTextBoxColumn3.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
+            this.dataGridViewTextBoxColumn3.ReadOnly = true;
+            this.dataGridViewTextBoxColumn3.Width = 150;
+            // 
+            // SNDetails
+            // 
+            this.SNDetails.BorderColor = System.Drawing.Color.Black;
+            this.SNDetails.Controls.Add(this.tableLayoutPanel1);
+            this.SNDetails.Dock = System.Windows.Forms.DockStyle.Top;
+            this.SNDetails.Font = new System.Drawing.Font("微软雅黑", 12F);
+            this.SNDetails.Location = new System.Drawing.Point(0, 0);
+            this.SNDetails.Name = "SNDetails";
+            this.SNDetails.Size = new System.Drawing.Size(1280, 123);
+            this.SNDetails.TabIndex = 27;
+            this.SNDetails.TabStop = false;
+            this.SNDetails.Text = "产品序列信息";
+            this.SNDetails.TextColor = System.Drawing.Color.Black;
+            // 
+            // tableLayoutPanel1
+            // 
+            this.tableLayoutPanel1.ColumnCount = 8;
+            this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 6.451613F));
+            this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 12.09677F));
+            this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 6.451613F));
+            this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 12.09677F));
+            this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 6.451613F));
+            this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 13.19F));
+            this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 6.451613F));
+            this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 36.81F));
+            this.tableLayoutPanel1.Controls.Add(this.productName, 7, 0);
+            this.tableLayoutPanel1.Controls.Add(this.productCode, 5, 0);
+            this.tableLayoutPanel1.Controls.Add(this.workOrder, 3, 0);
+            this.tableLayoutPanel1.Controls.Add(this.label4, 6, 0);
+            this.tableLayoutPanel1.Controls.Add(this.label1, 0, 0);
+            this.tableLayoutPanel1.Controls.Add(this.label3, 4, 0);
+            this.tableLayoutPanel1.Controls.Add(this.label2, 2, 0);
+            this.tableLayoutPanel1.Controls.Add(this.serialNumber, 1, 0);
+            this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Bottom;
+            this.tableLayoutPanel1.Location = new System.Drawing.Point(3, 37);
+            this.tableLayoutPanel1.Name = "tableLayoutPanel1";
+            this.tableLayoutPanel1.RowCount = 1;
+            this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
+            this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 83F));
+            this.tableLayoutPanel1.Size = new System.Drawing.Size(1274, 83);
+            this.tableLayoutPanel1.TabIndex = 0;
+            // 
+            // productName
+            // 
+            this.productName.AutoSize = true;
+            this.productName.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.productName.Location = new System.Drawing.Point(807, 0);
+            this.productName.Name = "productName";
+            this.productName.Size = new System.Drawing.Size(464, 83);
+            this.productName.TabIndex = 7;
+            this.productName.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // productCode
+            // 
+            this.productCode.AutoSize = true;
+            this.productCode.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.productCode.Location = new System.Drawing.Point(557, 0);
+            this.productCode.Name = "productCode";
+            this.productCode.Size = new System.Drawing.Size(162, 83);
+            this.productCode.TabIndex = 6;
+            this.productCode.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // workOrder
+            // 
+            this.workOrder.AutoSize = true;
+            this.workOrder.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.workOrder.Location = new System.Drawing.Point(321, 0);
+            this.workOrder.Name = "workOrder";
+            this.workOrder.Size = new System.Drawing.Size(148, 83);
+            this.workOrder.TabIndex = 5;
+            this.workOrder.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // label4
+            // 
+            this.label4.AutoSize = true;
+            this.label4.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.label4.Location = new System.Drawing.Point(725, 0);
+            this.label4.Name = "label4";
+            this.label4.Size = new System.Drawing.Size(76, 83);
+            this.label4.TabIndex = 3;
+            this.label4.Text = "产品名称: ";
+            this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // label1
+            // 
+            this.label1.AutoSize = true;
+            this.label1.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.label1.Location = new System.Drawing.Point(3, 0);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(76, 83);
+            this.label1.TabIndex = 0;
+            this.label1.Text = "序列号: ";
+            this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // label3
+            // 
+            this.label3.AutoSize = true;
+            this.label3.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.label3.Location = new System.Drawing.Point(475, 0);
+            this.label3.Name = "label3";
+            this.label3.Size = new System.Drawing.Size(76, 83);
+            this.label3.TabIndex = 2;
+            this.label3.Text = "产品编号: ";
+            this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // label2
+            // 
+            this.label2.AutoSize = true;
+            this.label2.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.label2.Location = new System.Drawing.Point(239, 0);
+            this.label2.Name = "label2";
+            this.label2.Size = new System.Drawing.Size(76, 83);
+            this.label2.TabIndex = 1;
+            this.label2.Text = "工单: ";
+            this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // serialNumber
+            // 
+            this.serialNumber.AutoSize = true;
+            this.serialNumber.Dock = System.Windows.Forms.DockStyle.Fill;
+            this.serialNumber.Location = new System.Drawing.Point(85, 0);
+            this.serialNumber.Name = "serialNumber";
+            this.serialNumber.Size = new System.Drawing.Size(148, 83);
+            this.serialNumber.TabIndex = 4;
+            this.serialNumber.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // dataGridViewTextBoxColumn4
+            // 
+            this.dataGridViewTextBoxColumn4.DataPropertyName = "ps_processcode";
+            this.dataGridViewTextBoxColumn4.HeaderText = "机台名称";
+            this.dataGridViewTextBoxColumn4.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4";
+            this.dataGridViewTextBoxColumn4.ReadOnly = true;
+            this.dataGridViewTextBoxColumn4.Visible = false;
+            this.dataGridViewTextBoxColumn4.Width = 190;
+            // 
+            // dataGridViewTextBoxColumn5
+            // 
+            this.dataGridViewTextBoxColumn5.DataPropertyName = "ps_table";
+            this.dataGridViewTextBoxColumn5.HeaderText = "面别";
+            this.dataGridViewTextBoxColumn5.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn5.Name = "dataGridViewTextBoxColumn5";
+            this.dataGridViewTextBoxColumn5.ReadOnly = true;
+            this.dataGridViewTextBoxColumn5.Width = 80;
+            // 
+            // dataGridViewTextBoxColumn6
+            // 
+            this.dataGridViewTextBoxColumn6.DataPropertyName = "psl_location";
+            this.dataGridViewTextBoxColumn6.HeaderText = "站位编号";
+            this.dataGridViewTextBoxColumn6.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn6.Name = "dataGridViewTextBoxColumn6";
+            this.dataGridViewTextBoxColumn6.ReadOnly = true;
+            this.dataGridViewTextBoxColumn6.Width = 90;
+            // 
+            // dataGridViewTextBoxColumn7
+            // 
+            this.dataGridViewTextBoxColumn7.DataPropertyName = "psl_bomlocation";
+            this.dataGridViewTextBoxColumn7.HeaderText = "元件位置";
+            this.dataGridViewTextBoxColumn7.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn7.Name = "dataGridViewTextBoxColumn7";
+            this.dataGridViewTextBoxColumn7.ReadOnly = true;
+            this.dataGridViewTextBoxColumn7.Width = 210;
+            // 
+            // dataGridViewTextBoxColumn8
+            // 
+            this.dataGridViewTextBoxColumn8.DataPropertyName = "psl_prodcode";
+            this.dataGridViewTextBoxColumn8.HeaderText = "物料编号";
+            this.dataGridViewTextBoxColumn8.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn8.Name = "dataGridViewTextBoxColumn8";
+            this.dataGridViewTextBoxColumn8.ReadOnly = true;
+            this.dataGridViewTextBoxColumn8.Width = 140;
+            // 
+            // dataGridViewTextBoxColumn9
+            // 
+            this.dataGridViewTextBoxColumn9.DataPropertyName = "psl_baseqty";
+            this.dataGridViewTextBoxColumn9.HeaderText = "单位用量";
+            this.dataGridViewTextBoxColumn9.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn9.Name = "dataGridViewTextBoxColumn9";
+            this.dataGridViewTextBoxColumn9.ReadOnly = true;
+            this.dataGridViewTextBoxColumn9.Width = 80;
+            // 
+            // dataGridViewTextBoxColumn10
+            // 
+            this.dataGridViewTextBoxColumn10.DataPropertyName = "ReelRemark";
+            this.dataGridViewTextBoxColumn10.HeaderText = "元件信息备注";
+            this.dataGridViewTextBoxColumn10.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn10.Name = "dataGridViewTextBoxColumn10";
+            this.dataGridViewTextBoxColumn10.ReadOnly = true;
+            this.dataGridViewTextBoxColumn10.Width = 150;
+            // 
+            // dataGridViewTextBoxColumn11
+            // 
+            this.dataGridViewTextBoxColumn11.DataPropertyName = "ReelNum";
+            this.dataGridViewTextBoxColumn11.HeaderText = "补料数量";
+            this.dataGridViewTextBoxColumn11.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn11.Name = "dataGridViewTextBoxColumn11";
+            this.dataGridViewTextBoxColumn11.Visible = false;
+            this.dataGridViewTextBoxColumn11.Width = 80;
+            // 
+            // dataGridViewTextBoxColumn12
+            // 
+            this.dataGridViewTextBoxColumn12.DataPropertyName = "ReelNum";
+            this.dataGridViewTextBoxColumn12.HeaderText = "补料数量";
+            this.dataGridViewTextBoxColumn12.MinimumWidth = 8;
+            this.dataGridViewTextBoxColumn12.Name = "dataGridViewTextBoxColumn12";
+            this.dataGridViewTextBoxColumn12.Visible = false;
+            this.dataGridViewTextBoxColumn12.Width = 80;
+            // 
+            // isDel
+            // 
+            this.isDel.DataPropertyName = "isDel";
+            this.isDel.FalseValue = false;
+            this.isDel.HeaderText = "";
+            this.isDel.MinimumWidth = 8;
+            this.isDel.Name = "isDel";
+            this.isDel.TrueValue = true;
+            this.isDel.Width = 80;
+            // 
+            // rn
+            // 
+            this.rn.DataPropertyName = "rn";
+            this.rn.HeaderText = "序号";
+            this.rn.MinimumWidth = 8;
+            this.rn.Name = "rn";
+            this.rn.ReadOnly = true;
+            this.rn.Width = 80;
+            // 
+            // ms_makecode
+            // 
+            this.ms_makecode.DataPropertyName = "ms_makecode";
+            this.ms_makecode.HeaderText = "工单";
+            this.ms_makecode.MinimumWidth = 8;
+            this.ms_makecode.Name = "ms_makecode";
+            this.ms_makecode.ReadOnly = true;
+            this.ms_makecode.Width = 150;
+            // 
+            // ms_sncode
+            // 
+            this.ms_sncode.DataPropertyName = "ms_sncode";
+            this.ms_sncode.HeaderText = "序列号";
+            this.ms_sncode.MinimumWidth = 8;
+            this.ms_sncode.Name = "ms_sncode";
+            this.ms_sncode.ReadOnly = true;
+            this.ms_sncode.Width = 160;
+            // 
+            // Make_ShipmentVerify
+            // 
+            this.AutoScaleDimensions = new System.Drawing.SizeF(11F, 24F);
+            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+            this.ClientSize = new System.Drawing.Size(1280, 720);
+            this.Controls.Add(this.containerBox);
+            this.Controls.Add(this.SNDetails);
+            this.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
+            this.Margin = new System.Windows.Forms.Padding(4);
+            this.Name = "Make_ShipmentVerify";
+            this.Text = "Make_HandFeedRegistration";
+            this.Load += new System.EventHandler(this.Make_HandFeedRegistration_Load);
+            this.containerBox.ResumeLayout(false);
+            this.tableLayoutPanel2.ResumeLayout(false);
+            this.tableLayoutPanel3.ResumeLayout(false);
+            this.panel1.ResumeLayout(false);
+            this.panel1.PerformLayout();
+            this.groupBox1.ResumeLayout(false);
+            ((System.ComponentModel.ISupportInitialize)(this.dgv)).EndInit();
+            this.SNDetails.ResumeLayout(false);
+            this.tableLayoutPanel1.ResumeLayout(false);
+            this.tableLayoutPanel1.PerformLayout();
+            this.ResumeLayout(false);
+
+        }
+
+        #endregion
+
+        private CustomControl.GroupBoxWithBorder.GroupBoxWithBorder SNDetails;
+        private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
+        private System.Windows.Forms.Label productName;
+        private System.Windows.Forms.Label productCode;
+        private System.Windows.Forms.Label workOrder;
+        private System.Windows.Forms.Label label4;
+        private System.Windows.Forms.Label label1;
+        private System.Windows.Forms.Label label3;
+        private System.Windows.Forms.Label label2;
+        private System.Windows.Forms.Label serialNumber;
+        private System.Windows.Forms.Panel containerBox;
+        private System.Windows.Forms.DataGridView dgv;
+        private System.Windows.Forms.Label snLab;
+        private System.Windows.Forms.TextBox snVal;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
+        private System.Windows.Forms.DataGridViewCheckBoxColumn dataGridViewCheckBoxColumn1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn3;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn6;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn7;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn8;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn9;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn10;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn11;
+        private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn12;
+        private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
+        private System.Windows.Forms.GroupBox groupBox1;
+        private System.Windows.Forms.Panel panel1;
+        private System.Windows.Forms.TableLayoutPanel tableLayoutPanel3;
+        private CustomControl.RichText.RichTextAutoBottom Msg1;
+        private System.Windows.Forms.Label PanelQtyLab;
+        private System.Windows.Forms.TextBox PanelQtyVal;
+        private System.Windows.Forms.Button Confirm;
+        private System.Windows.Forms.Button Delete;
+        private System.Windows.Forms.Button claerBtn;
+        private System.Windows.Forms.DataGridViewCheckBoxColumn isDel;
+        private System.Windows.Forms.DataGridViewTextBoxColumn rn;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ms_makecode;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ms_sncode;
+    }
+}

+ 504 - 0
UAS_MES_YTDZ/FunctionCode/Make/Make_ShipmentVerify.cs

@@ -0,0 +1,504 @@
+
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Drawing;
+using System.IO;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+using UAS_MES_NEW.CustomControl.ButtonUtil;
+using UAS_MES_NEW.CustomControl.RichText;
+using UAS_MES_NEW.DataOperate;
+using UAS_MES_NEW.Entity;
+using UAS_MES_NEW.PublicMethod;
+
+namespace UAS_MES_NEW.Make
+{
+    public partial class Make_ShipmentVerify : Form
+    {
+        public Make_ShipmentVerify()
+        {
+            InitializeComponent();
+        }
+
+        DataTable dt, data;
+        DataHelper dh;
+        int panelQty;
+
+        string oMakeCode, oMSID, reworkstatus, ifrework, ErrorMessage;
+
+
+        private void Make_HandFeedRegistration_Load(object sender, EventArgs e)
+        {
+            dh = SystemInf.dh;
+
+            data = new DataTable();
+            data.Columns.Add("isDel", typeof(bool));
+            data.Columns.Add("rn", typeof(int));
+            data.Columns.Add("ms_sncode", typeof(string));
+            data.Columns.Add("ms_makecode", typeof(string));
+
+            dgv.AutoGenerateColumns = false;
+            dgv.DataSource = data;
+
+            snVal.Enabled = false;
+            PanelQtyVal.Focus();
+        }
+
+        private void Confirm_Click(object sender, EventArgs e)
+        {
+            if (Confirm.Text == "确认")
+            {
+                if (string.IsNullOrEmpty(PanelQtyVal.Text))
+                {
+                    PanelQtyVal.Text = "";
+                    ShowMsg(Msg1, 0, "请输入拼板数");
+                    PanelQtyVal.Focus();
+                    return;
+                }
+
+                if (!int.TryParse(PanelQtyVal.Text, out int qty) || qty <= 0)
+                {
+                    PanelQtyVal.Text = "";
+                    ShowMsg(Msg1, 0, "拼板数请输入正整数");
+                    PanelQtyVal.Focus();
+                    return;
+                }
+
+                panelQty = qty;
+                Confirm.Text = "取消";
+                PanelQtyVal.Enabled = false;
+                snVal.Enabled = true;
+                snVal.Focus();
+                snVal.SelectAll();
+            }
+            else if (Confirm.Text == "取消")
+            {
+                Confirm.Text = "确认";
+                panelQty = 0;
+                PanelQtyVal.Enabled = true;
+                snVal.Enabled = false;
+                snVal.Text = "";
+                data.Rows.Clear();
+                UpdateSN("C");
+                PanelQtyVal.Focus();
+                PanelQtyVal.SelectAll();
+            }
+        }
+
+        private void snVal_KeyDown(object sender, KeyEventArgs e)
+        {
+            if (e.KeyCode != Keys.Enter) return;
+
+            e.Handled = true;
+            e.SuppressKeyPress = true;
+
+            if (PanelQtyVal.Enabled || panelQty <= 0)
+            {
+                ShowMsg(Msg1, 0, "请先确认拼板数量");
+                return;
+            }
+
+            string scanSn = snVal.Text.Trim();
+            if (string.IsNullOrEmpty(scanSn))
+            {
+                ShowMsg(Msg1, 0, "请扫描序列号");
+                snVal.Focus();
+                return;
+            }
+
+            if (data.Rows.Count >= panelQty)
+            {
+                ShowMsg(Msg1, 0, "已达到拼板数量");
+                snVal.Focus();
+                snVal.SelectAll();
+                return;
+            }
+
+            string snSql = scanSn.Replace("'", "''");
+            dt = (DataTable)dh.ExecuteSql($@"SELECT ms_sncode, ms_makecode FROM makeserial a WHERE 
+                a.ms_sncode = '{snSql}'", "select");
+            if (dt.Rows.Count > 0)
+            {
+                string snCode = dt.Rows[0]["ms_sncode"].ToString();
+                string makeCode = dt.Rows[0]["ms_makecode"].ToString();
+
+                foreach (DataRow row in data.Rows)
+                {
+                    if (string.Equals(row["ms_sncode"].ToString(), snCode, StringComparison.OrdinalIgnoreCase))
+                    {
+                        ShowMsg(Msg1, 0, "序列号已扫描");
+                        snVal.Focus();
+                        snVal.SelectAll();
+                        return;
+                    }
+                }
+
+                if (!CheckCollectSN(snCode, makeCode))
+                {
+                    snVal.Focus();
+                    snVal.SelectAll();
+                    return;
+                }
+
+                data.Rows.Add(false, data.Rows.Count + 1, snCode, makeCode);
+                UpdateSN("L", snCode);
+                snVal.Text = "";
+                snVal.Focus();
+
+                if (data.Rows.Count >= panelQty)
+                {
+                    ShowMsg(Msg1, 1, "拼板数量已扫满");
+                    PanelFull();
+                }
+            }
+            else
+            {
+                ShowMsg(Msg1, 0, "序列号不存在");
+                UpdateSN("C");
+                snVal.Focus();
+                snVal.SelectAll();
+            }
+        }
+
+        /// <summary>
+        /// 采集工序校验。不通过时已输出红色提示,调用处只需处理焦点。
+        /// </summary>
+        private bool CheckCollectSN(string snCode, string makeCode)
+        {
+            if (!LogicHandler.CheckStepAttribute(Tag.ToString(), User.UserSourceCode, out ErrorMessage))
+            {
+                ShowMsg(Msg1, 0, ErrorMessage);
+                return false;
+            }
+
+            bool NoteAlready = LogicHandler.CheckDiffMakeCodeBeforeStepCheck(snCode, makeCode, true, out oMakeCode, out ErrorMessage);
+            if (!NoteAlready)
+            {
+                ShowMsg(Msg1, 0, ErrorMessage);
+                return false;
+            }
+
+            if (!LogicHandler.CheckStepSNAndMacode(oMakeCode, User.UserSourceCode, snCode, User.UserCode, out oMakeCode, out oMSID, out ErrorMessage))
+            {
+                ShowMsg(Msg1, 0, ErrorMessage);
+                return false;
+            }
+
+            if (!LogicHandler.CheckDiffMakeCodeAfterStepCheck(snCode, oMakeCode, true, NoteAlready, workOrder, out ErrorMessage))
+            {
+                ShowMsg(Msg1, 0, ErrorMessage);
+                return false;
+            }
+
+            if (workOrder.Text != oMakeCode && oMakeCode != null)
+            {
+                string makeSql = oMakeCode.Replace("'", "''");
+                dt = (DataTable)dh.ExecuteSql("select ma_code,ma_prodcode,ma_softversion,ma_salecode,pr_spec,nvl(pr_sendchecktype,'LineCode')pr_sendchecktype,ma_qty from make left join product on ma_prodcode=pr_code where ma_code='" + makeSql + "'", "select");
+                if (dt.Rows.Count > 0)
+                {
+                    BaseUtil.SetFormValue(this.Controls, dt);
+                    workOrder.Text = dt.Rows[0]["ma_code"].ToString();
+                    productCode.Text = dt.Rows[0]["ma_prodcode"].ToString();
+                    productName.Text = dt.Rows[0]["pr_spec"].ToString();
+                }
+            }
+
+            string msIdSql = (oMSID ?? "").Replace("'", "''");
+            dt = (DataTable)dh.ExecuteSql("select ms_nextstepcode,ms_sncode,ms_reworkstatus,nvl(ms_ifrework,0)ms_ifrework,ms_stepcode,ms_status,nvl(st_ifrepair,0) st_ifrepair from makeserial left join step on ms_stepcode=st_code where ms_id='" + msIdSql + "'", "select");
+            if (dt.Rows.Count == 0)
+            {
+                ShowMsg(Msg1, 0, "未查询到序列号工序信息");
+                return false;
+            }
+
+            string status = dt.Rows[0]["ms_status"].ToString();
+            reworkstatus = dt.Rows[0]["ms_reworkstatus"].ToString();
+            string stepcode = dt.Rows[0]["ms_stepcode"].ToString();
+            string ifrepair = dt.Rows[0]["st_ifrepair"].ToString();
+            string ms_nextstepcode = dt.Rows[0]["ms_nextstepcode"].ToString();
+            string sncode = dt.Rows[0]["ms_sncode"].ToString();
+            if (sncode != snCode)
+            {
+                ShowMsg(Msg1, 0, snCode + " 序列号已执行过转号,不允许使用TSN采集");
+                return false;
+            }
+
+            ifrework = dt.Rows[0]["ms_ifrework"].ToString();
+            bool sameStep = stepcode == User.CurrentStepCode && ms_nextstepcode != User.CurrentStepCode && ifrepair == "0";
+            if (ifrework != "0" && sameStep && (reworkstatus == "1" || reworkstatus == "2"))
+            {
+                ShowMsg(Msg1, 0, snCode + " 序列号已执行过" + User.CurrentStepCode + "工序,采集结果为良品");
+                return false;
+            }
+            if (ifrework == "0" && sameStep && (status == "1" || status == "2"))
+            {
+                ShowMsg(Msg1, 0, snCode + " 序列号已执行过" + User.CurrentStepCode + "工序,采集结果为良品");
+                return false;
+            }
+
+            return true;
+        }
+
+        /// <summary>
+        /// 拼板扫满后,表格中的序列号一次全部过站。
+        /// </summary>
+        private void PanelFull()
+        {
+            dgv.EndEdit();
+
+            List<DataRow> rows = new List<DataRow>();
+            foreach (DataRow row in data.Rows)
+            {
+                if (row.RowState == DataRowState.Deleted) continue;
+                rows.Add(row);
+            }
+            if (rows.Count == 0)
+            {
+                ShowMsg(Msg1, 0, "没有可过站的序列号");
+                return;
+            }
+
+            List<string> successList = new List<string>();
+            List<string> afterList = new List<string>();
+            List<string> failList = new List<string>();
+            List<DataRow> passedRows = new List<DataRow>();
+
+            foreach (DataRow row in rows)
+            {
+                string snCode = row["ms_sncode"].ToString();
+                string makeCode = row["ms_makecode"].ToString();
+                string stepError;
+                if (!PassOneSN(snCode, makeCode, out stepError))
+                {
+                    failList.Add(string.IsNullOrEmpty(stepError) ? snCode : snCode + "(" + stepError + ")");
+                    continue;
+                }
+
+                successList.Add(snCode);
+                passedRows.Add(row);
+                if (!string.IsNullOrEmpty(stepError) && stepError.IndexOf("AFTERSUCCESS", StringComparison.OrdinalIgnoreCase) >= 0)
+                    afterList.Add(snCode + " " + stepError);
+
+                LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, makeCode, User.UserLineCode, User.UserSourceCode, "出货核对", "过站成功", snCode, "");
+            }
+
+            foreach (DataRow row in passedRows)
+                data.Rows.Remove(row);
+            for (int i = 0; i < data.Rows.Count; i++)
+                data.Rows[i]["rn"] = i + 1;
+
+            if (successList.Count > 0)
+                ShowMsg(Msg1, 1, $"过站成功{successList.Count}条,序列号:{string.Join("、", successList)}");
+            foreach (string afterMsg in afterList)
+                ShowMsg(Msg1, 2, afterMsg);
+            if (failList.Count > 0)
+                ShowMsg(Msg1, 0, $"过站失败{failList.Count}条,序列号:{string.Join("、", failList)}");
+
+            if (snVal.Enabled)
+            {
+                snVal.Focus();
+                snVal.SelectAll();
+            }
+        }
+
+        /// <summary>
+        /// 单条过站。失败原因写入 stepError,成功且带 AFTERSUCCESS 时 stepError 为附加信息。
+        /// </summary>
+        private bool PassOneSN(string snCode, string makeCode, out string stepError)
+        {
+            stepError = "";
+            try
+            {
+                string snSql = (snCode ?? "").Replace("'", "''");
+                string makeSql = (makeCode ?? "").Replace("'", "''");
+
+                DataTable reworkDt = (DataTable)dh.ExecuteSql($@"SELECT nvl(ms_ifrework,0) ms_ifrework, ms_reworkstatus FROM makeserial WHERE ms_sncode='{snSql}' AND ms_makecode='{makeSql}'", "select");
+                if (reworkDt.Rows.Count == 0)
+                {
+                    stepError = "未查询到序列号";
+                    return false;
+                }
+
+                string rowIfRework = reworkDt.Rows[0]["ms_ifrework"].ToString();
+                string rowReworkStatus = reworkDt.Rows[0]["ms_reworkstatus"].ToString();
+                if (rowIfRework != "0" && rowReworkStatus == "3")
+                {
+                    stepError = "返修不良必须先维修";
+                    return false;
+                }
+
+                if (rowIfRework == "0")
+                {
+                    DataTable badDt = (DataTable)dh.ExecuteSql($@"SELECT mb_id,bc_name,mbr_mbid FROM makebad LEFT JOIN makebadreason ON mbr_mbid=mb_id LEFT JOIN badcode ON mb_badcode=bc_code WHERE mb_sncode='{snSql}' AND mb_makecode='{makeSql}' AND mb_status=0", "select");
+                    List<string> badNames = new List<string>();
+                    for (int i = 0; i < badDt.Rows.Count; i++)
+                    {
+                        if (badDt.Rows[i]["mb_id"].ToString() != badDt.Rows[i]["mbr_mbid"].ToString())
+                            badNames.Add("【" + badDt.Rows[i]["bc_name"].ToString() + "】");
+                    }
+                    if (badNames.Count > 0)
+                    {
+                        stepError = "已判为不良品" + string.Join("", badNames);
+                        return false;
+                    }
+                }
+
+                if (!LogicHandler.SetStepResult(makeCode, User.UserSourceCode, snCode, "出货核对", "检测合格", User.UserCode, out stepError))
+                {
+                    if (string.IsNullOrEmpty(stepError) || stepError == "null")
+                        stepError = "过站失败";
+                    return false;
+                }
+
+                if (stepError == "null")
+                    stepError = "";
+                return true;
+            }
+            catch (Exception ex)
+            {
+                stepError = ex.Message;
+                return false;
+            }
+        }
+
+        private void Delete_Click(object sender, EventArgs e)
+        {
+            dgv.EndEdit();
+
+            List<DataRow> removeRows = new List<DataRow>();
+            foreach (DataRow row in data.Rows)
+            {
+                if (row.RowState == DataRowState.Deleted) continue;
+                if (row["isDel"] != DBNull.Value && Convert.ToBoolean(row["isDel"]))
+                    removeRows.Add(row);
+            }
+
+            if (removeRows.Count == 0)
+            {
+                ShowMsg(Msg1, 0, "请勾选要删除的序列号");
+                return;
+            }
+
+            List<string> snList = new List<string>();
+            foreach (DataRow row in removeRows)
+            {
+                snList.Add(row["ms_sncode"].ToString());
+                data.Rows.Remove(row);
+            }
+
+            for (int i = 0; i < data.Rows.Count; i++)
+                data.Rows[i]["rn"] = i + 1;
+
+            ShowMsg(Msg1, 1, $"已删除{removeRows.Count}条,序列号:{string.Join("、", snList)}");
+            if (snVal.Enabled)
+            {
+                snVal.Focus();
+                snVal.SelectAll();
+            }
+        }
+
+        
+        private void dgv_CellClick(object sender, DataGridViewCellEventArgs e)
+        {
+            if (e.RowIndex < 0 || e.ColumnIndex < 0) return;
+
+            var column = dgv.Columns[e.ColumnIndex];
+
+            if (column is DataGridViewCheckBoxColumn)
+            {
+                var cell = dgv[e.ColumnIndex, e.RowIndex] as DataGridViewCheckBoxCell;
+
+                if (cell != null && !cell.ReadOnly)
+                {
+                    bool currentValue = false;
+                    if (cell.Value != null && cell.Value != DBNull.Value)
+                    {
+                        currentValue = Convert.ToBoolean(cell.Value);
+                    }
+
+                    bool nextValue = !currentValue;
+                    cell.Value = nextValue;
+                    if (e.RowIndex < data.Rows.Count)
+                        data.Rows[e.RowIndex]["isDel"] = nextValue;
+                    dgv.CommitEdit(DataGridViewDataErrorContexts.Commit);
+                    dgv.EndEdit();
+
+                    var row = dgv.Rows[e.RowIndex];
+
+                    if (currentValue)
+                    {
+                        row.DefaultCellStyle.BackColor = dgv.DefaultCellStyle.BackColor;
+                        row.DefaultCellStyle.ForeColor = dgv.DefaultCellStyle.ForeColor;
+                    }
+                    else
+                    {
+                        row.DefaultCellStyle.BackColor = Color.LightSkyBlue;
+                        row.DefaultCellStyle.ForeColor = Color.Black;
+                    }
+                }
+            }
+        }
+
+        private void UpdateSN(string type, string sn = "")
+        {
+            if (type == "C")
+            {
+                serialNumber.Text = "";
+                workOrder.Text = "";
+                productCode.Text = "";
+                productName.Text = "";
+            }
+            else if (type == "L")
+            {
+                string snSql = sn.Replace("'", "''");
+                dt = (DataTable)dh.ExecuteSql($@"SELECT ms_sncode,ma_code,pr_code,pr_spec FROM makeserial,make,product
+                        WHERE ms_sncode = '{snSql}' AND ms_makecode = ma_code AND ms_prodcode = pr_code", "select");
+                if (dt.Rows.Count > 0)
+                {
+                    serialNumber.Text = dt.Rows[0]["ms_sncode"].ToString();
+                    workOrder.Text = dt.Rows[0]["ma_code"].ToString();
+                    productCode.Text = dt.Rows[0]["pr_code"].ToString();
+                    productName.Text = dt.Rows[0]["pr_spec"].ToString();
+                }
+                else
+                {
+                    UpdateSN("C", sn);
+                }
+            }
+        }
+
+        private void claerBtn_Click(object sender, EventArgs e)
+        {
+            Msg1.Clear();
+        }
+
+        private void ShowMsg(RichTextAutoBottom msgBox, int type, string msg)
+        {
+            msg = msg.Replace("\r", "").Replace("\n", "");
+            string msgTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
+            string showMsg = $"{msgTime}: {msg}\n";
+
+            if (type == 0)
+            {
+                msgBox.AppendText(showMsg, Color.Red);
+                msgBox.SelectionStart = msgBox.Text.Length;
+                msgBox.ScrollToCaret();
+            }
+            else if (type == 1)
+            {
+                msgBox.AppendText(showMsg, Color.Green);
+                msgBox.SelectionStart = msgBox.Text.Length;
+                msgBox.ScrollToCaret();
+            }
+            else if (type == 2)
+            {
+                msgBox.AppendText(showMsg, Color.YellowGreen);
+                msgBox.SelectionStart = msgBox.Text.Length;
+                msgBox.ScrollToCaret();
+            }
+        }
+    }
+}

+ 132 - 0
UAS_MES_YTDZ/FunctionCode/Make/Make_ShipmentVerify.resx

@@ -0,0 +1,132 @@
+<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" use="required" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <resheader name="writer">
+    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <metadata name="isDel.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="rn.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ms_makecode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ms_sncode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+</root>

+ 3 - 3
UAS_MES_YTDZ/FunctionCode/Make/Make_TestCollection.cs

@@ -244,7 +244,7 @@ namespace UAS_MES_NEW.Make
                             {
                                 if ((stepcode == User.CurrentStepCode && ms_nextstepcode != User.CurrentStepCode) && (reworkstatus == "1" || reworkstatus == "2") && ifrepair == "0")
                                 {
-                                    OperateResult.AppendText(">>" + ms_sncode.Text + " 序列号已执行过" + User.CurrentStepCode + "工序,采集结果为良品\n", Color.Black, ms_sncode);
+                                    OperateResult.AppendText(">>" + ms_sncode.Text + " 序列号已执行过" + User.CurrentStepCode + "工序,采集结果为良品\n", Color.Red, ms_sncode);
                                     return;
                                 }
                             }
@@ -252,7 +252,7 @@ namespace UAS_MES_NEW.Make
                             {
                                 if ((stepcode == User.CurrentStepCode && ms_nextstepcode != User.CurrentStepCode) && (status == "1" || status == "2") && ifrepair == "0")
                                 {
-                                    OperateResult.AppendText(">>" + ms_sncode.Text + " 序列号已执行过" + User.CurrentStepCode + "工序,采集结果为良品\n", Color.Black, ms_sncode);
+                                    OperateResult.AppendText(">>" + ms_sncode.Text + " 序列号已执行过" + User.CurrentStepCode + "工序,采集结果为良品\n", Color.Red, ms_sncode);
                                     return;
                                 }
                             }
@@ -741,7 +741,7 @@ namespace UAS_MES_NEW.Make
                             dh.UpdateByCondition("makebad", "mb_status=-1", "mb_sncode='" + ms_sncode.Text + "' and mb_makecode='" + ma_code.Text + "' and mb_stepcode='" + User.CurrentStepCode + "'");
                             dh.UpdateByCondition("makeserial", "ms_stepcode='',ms_status=1,ms_nextstepcode='" + User.CurrentStepCode + "'", "ms_id='" + oMSID + "'");
                             LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ma_code.Text, User.UserLineCode, User.UserSourceCode, "快速维修成功", "快速维修", "", ob_checkno.Text);
-                            OperateResult.AppendText(">>本次采集不良代码" + badname + "存在于本工序" + User.CurrentStepCode + "中,请解除故障后重新测试本站\n", Color.Black);
+                            OperateResult.AppendText(">>本次采集不良代码" + badname + "存在于本工序" + User.CurrentStepCode + "中,请解除故障后重新测试本站\n", Color.Red);
                         }
                         else OperateResult.AppendText(">>" + ms_sncode.Text + "成功采集为不良\n", Color.Green);
                     }

+ 9 - 0
UAS_MES_YTDZ/UAS_MES_YTDZ.csproj

@@ -571,6 +571,12 @@
     <Compile Include="FunctionCode\Make\Make_BodyTest.Designer.cs">
       <DependentUpon>Make_BodyTest.cs</DependentUpon>
     </Compile>
+    <Compile Include="FunctionCode\Make\Make_ShipmentVerify.cs">
+      <SubType>Form</SubType>
+    </Compile>
+    <Compile Include="FunctionCode\Make\Make_ShipmentVerify.Designer.cs">
+      <DependentUpon>Make_ShipmentVerify.cs</DependentUpon>
+    </Compile>
     <Compile Include="FunctionCode\Make\Make_HandFeedRegistration.cs">
       <SubType>Form</SubType>
     </Compile>
@@ -1391,6 +1397,9 @@
     <EmbeddedResource Include="FunctionCode\Make\Make_BodyTest.resx">
       <DependentUpon>Make_BodyTest.cs</DependentUpon>
     </EmbeddedResource>
+    <EmbeddedResource Include="FunctionCode\Make\Make_ShipmentVerify.resx">
+      <DependentUpon>Make_ShipmentVerify.cs</DependentUpon>
+    </EmbeddedResource>
     <EmbeddedResource Include="FunctionCode\Make\Make_HandFeedRegistration.resx">
       <DependentUpon>Make_HandFeedRegistration.cs</DependentUpon>
     </EmbeddedResource>