Explorar o código

正通MES项目修改提交

caosy %!s(int64=3) %!d(string=hai) anos
pai
achega
4c1d433b9e

+ 45 - 0
UAS_MES_ZT/CustomControl/RichText/RichTextAutoBottom.cs

@@ -153,6 +153,51 @@ namespace UAS_MES_NEW.CustomControl.RichText
             LogManager.DoLog(FindForm().Tag + str);
         }
 
+        /// <summary>
+        /// 提示错误信息清楚指定控件的值
+        /// </summary>
+        /// <param name="str"></param>
+        /// <param name="color"></param>
+        /// <param name="ctl"></param>
+        public void AppendText(string str, Color color, Control ctl, Control ct2, Control ct3)
+        {
+            SelectionColor = color;
+            base.AppendText(str);
+            ctl.Text = "";
+            ct2.Text = "";
+            ct3.Text = "";
+            //如果颜色是红色则进行提示音
+            if (color == Color.Red && Entity.SystemInf.CheckAudioEnable)
+            {
+                FileName = Application.StartupPath + @"\Resources\Sound\FAIL.wav";
+                thread.Start();
+                thread = new Thread(PlaySound);
+
+            }
+            else if (color == Color.Green && Entity.SystemInf.CheckAudioEnable)
+            {
+                //颜色是绿色,进行正确提示音
+                FileName = Application.StartupPath + @"\Resources\Sound\PASS.wav";
+                thread.Start();
+                thread = new Thread(PlaySound);
+            }
+            else if (color == Color.Blue && Entity.SystemInf.CheckAudioEnable)
+            {
+                //颜色是绿色,进行正确提示音
+                FileName = Application.StartupPath + @"\Resources\Sound\4082.wav";
+                thread.Start();
+                thread = new Thread(PlaySound);
+            }
+            else if (color == Color.OrangeRed && Entity.SystemInf.CheckAudioEnable)
+            {
+                //颜色是绿色,进行正确提示音
+                FileName = Application.StartupPath + @"\Resources\Sound\失败.wav";
+                thread.Start();
+                thread = new Thread(PlaySound);
+            }
+            LogManager.DoLog(FindForm().Tag + str);
+        }
+
         private void PlaySound()
         {
             //要加载COM组件:Microsoft speech object Library    

+ 58 - 13
UAS_MES_ZT/FunctionCode/Make/Make_Repair.Designer.cs

@@ -61,6 +61,8 @@
             this.ma_craftcode_label = new System.Windows.Forms.Label();
             this.pr_detail_label = new System.Windows.Forms.Label();
             this.ms_prodcode_label = new System.Windows.Forms.Label();
+            this.label1 = new System.Windows.Forms.Label();
+            this.normalButton2 = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
             this.cd_stepcode = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SearchTextBox();
             this.RepairComplete = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
             this.ms_sncode = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
@@ -180,7 +182,7 @@
             this.mbc_component_label.AutoSize = true;
             this.mbc_component_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.mbc_component_label.ForeColor = System.Drawing.Color.Black;
-            this.mbc_component_label.Location = new System.Drawing.Point(253, 384);
+            this.mbc_component_label.Location = new System.Drawing.Point(247, 579);
             this.mbc_component_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.mbc_component_label.Name = "mbc_component_label";
             this.mbc_component_label.Size = new System.Drawing.Size(110, 31);
@@ -205,24 +207,26 @@
             this.mbl_loc_label.AutoSize = true;
             this.mbl_loc_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.mbl_loc_label.ForeColor = System.Drawing.Color.Black;
-            this.mbl_loc_label.Location = new System.Drawing.Point(244, 430);
+            this.mbl_loc_label.Location = new System.Drawing.Point(244, 610);
             this.mbl_loc_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.mbl_loc_label.Name = "mbl_loc_label";
             this.mbl_loc_label.Size = new System.Drawing.Size(110, 31);
             this.mbl_loc_label.TabIndex = 103;
             this.mbl_loc_label.Text = "不良位置";
+            this.mbl_loc_label.Visible = false;
             // 
             // mbp_part_label
             // 
             this.mbp_part_label.AutoSize = true;
             this.mbp_part_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.mbp_part_label.ForeColor = System.Drawing.Color.Black;
-            this.mbp_part_label.Location = new System.Drawing.Point(681, 430);
+            this.mbp_part_label.Location = new System.Drawing.Point(681, 603);
             this.mbp_part_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.mbp_part_label.Name = "mbp_part_label";
             this.mbp_part_label.Size = new System.Drawing.Size(110, 31);
             this.mbp_part_label.TabIndex = 105;
             this.mbp_part_label.Text = "不良零件";
+            this.mbp_part_label.Visible = false;
             // 
             // GetSNCode_Label
             // 
@@ -337,7 +341,7 @@
             // 
             this.checkBox1.AutoSize = true;
             this.checkBox1.Enabled = false;
-            this.checkBox1.Location = new System.Drawing.Point(753, 384);
+            this.checkBox1.Location = new System.Drawing.Point(889, 354);
             this.checkBox1.Margin = new System.Windows.Forms.Padding(4);
             this.checkBox1.Name = "checkBox1";
             this.checkBox1.Size = new System.Drawing.Size(178, 22);
@@ -463,6 +467,38 @@
             this.ms_prodcode_label.TabIndex = 149;
             this.ms_prodcode_label.Text = "产品编号";
             // 
+            // label1
+            // 
+            this.label1.AutoSize = true;
+            this.label1.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.label1.ForeColor = System.Drawing.Color.Black;
+            this.label1.Location = new System.Drawing.Point(247, 538);
+            this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(110, 31);
+            this.label1.TabIndex = 160;
+            this.label1.Text = "责任工序";
+            // 
+            // normalButton2
+            // 
+            this.normalButton2.AllPower = "ifall";
+            this.normalButton2.BackColor = System.Drawing.Color.Transparent;
+            this.normalButton2.DownImage = ((System.Drawing.Image)(resources.GetObject("normalButton2.DownImage")));
+            this.normalButton2.Image = null;
+            this.normalButton2.IsShowBorder = true;
+            this.normalButton2.Location = new System.Drawing.Point(620, 539);
+            this.normalButton2.Margin = new System.Windows.Forms.Padding(4);
+            this.normalButton2.MoveImage = ((System.Drawing.Image)(resources.GetObject("normalButton2.MoveImage")));
+            this.normalButton2.Name = "normalButton2";
+            this.normalButton2.NormalImage = ((System.Drawing.Image)(resources.GetObject("normalButton2.NormalImage")));
+            this.normalButton2.Power = null;
+            this.normalButton2.Size = new System.Drawing.Size(131, 36);
+            this.normalButton2.TabIndex = 159;
+            this.normalButton2.Tag = "IfRead";
+            this.normalButton2.Text = "责任复判";
+            this.normalButton2.UseVisualStyleBackColor = true;
+            this.normalButton2.Click += new System.EventHandler(this.normalButton2_Click);
+            // 
             // cd_stepcode
             // 
             this.cd_stepcode.AllPower = "ifall";
@@ -471,7 +507,7 @@
             this.cd_stepcode.DBTitle = "回流工序";
             this.cd_stepcode.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.cd_stepcode.FormName = null;
-            this.cd_stepcode.Location = new System.Drawing.Point(536, 87);
+            this.cd_stepcode.Location = new System.Drawing.Point(387, 542);
             this.cd_stepcode.Margin = new System.Windows.Forms.Padding(4);
             this.cd_stepcode.Name = "cd_stepcode";
             this.cd_stepcode.Power = "ifspecial";
@@ -662,7 +698,7 @@
             "FPC排线",
             "电池",
             "其他"});
-            this.mbc_component.Location = new System.Drawing.Point(402, 384);
+            this.mbc_component.Location = new System.Drawing.Point(391, 586);
             this.mbc_component.Margin = new System.Windows.Forms.Padding(4);
             this.mbc_component.Name = "mbc_component";
             this.mbc_component.Size = new System.Drawing.Size(180, 26);
@@ -738,7 +774,7 @@
             this.bd_soncode.Condition = null;
             this.bd_soncode.DBTitle = null;
             this.bd_soncode.FormName = null;
-            this.bd_soncode.Location = new System.Drawing.Point(792, 432);
+            this.bd_soncode.Location = new System.Drawing.Point(785, 602);
             this.bd_soncode.Name = "bd_soncode";
             this.bd_soncode.Power = null;
             this.bd_soncode.ReturnData = null;
@@ -749,6 +785,7 @@
             this.bd_soncode.TableName = null;
             this.bd_soncode.Tag = "bd_soncode";
             this.bd_soncode.TextBoxEnable = true;
+            this.bd_soncode.Visible = false;
             // 
             // mbp_partdgv
             // 
@@ -758,11 +795,12 @@
             this.mbp_part1,
             this.DeleteCom,
             this.mbp_id});
-            this.mbp_partdgv.Location = new System.Drawing.Point(687, 488);
+            this.mbp_partdgv.Location = new System.Drawing.Point(687, 662);
             this.mbp_partdgv.Name = "mbp_partdgv";
             this.mbp_partdgv.RowTemplate.Height = 27;
-            this.mbp_partdgv.Size = new System.Drawing.Size(393, 228);
+            this.mbp_partdgv.Size = new System.Drawing.Size(393, 54);
             this.mbp_partdgv.TabIndex = 121;
+            this.mbp_partdgv.Visible = false;
             this.mbp_partdgv.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.mbp_partdgv_CellContentClick);
             // 
             // mbp_part1
@@ -798,11 +836,12 @@
             this.mbl_loc1,
             this.DeletePos,
             this.mbl_id});
-            this.mbl_locdgv.Location = new System.Drawing.Point(249, 488);
+            this.mbl_locdgv.Location = new System.Drawing.Point(249, 662);
             this.mbl_locdgv.Name = "mbl_locdgv";
             this.mbl_locdgv.RowTemplate.Height = 27;
-            this.mbl_locdgv.Size = new System.Drawing.Size(393, 228);
+            this.mbl_locdgv.Size = new System.Drawing.Size(393, 54);
             this.mbl_locdgv.TabIndex = 120;
+            this.mbl_locdgv.Visible = false;
             this.mbl_locdgv.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.mbl_locdgv_CellContentClick);
             // 
             // mbl_loc1
@@ -928,7 +967,7 @@
             | System.Windows.Forms.AnchorStyles.Left)));
             this.mbl_loc.BackColor = System.Drawing.Color.White;
             this.mbl_loc.ID = null;
-            this.mbl_loc.Location = new System.Drawing.Point(393, 434);
+            this.mbl_loc.Location = new System.Drawing.Point(362, 610);
             this.mbl_loc.Margin = new System.Windows.Forms.Padding(4);
             this.mbl_loc.Name = "mbl_loc";
             this.mbl_loc.Power = null;
@@ -938,6 +977,7 @@
             this.mbl_loc.Str2 = null;
             this.mbl_loc.TabIndex = 104;
             this.mbl_loc.Tag = "Read";
+            this.mbl_loc.Visible = false;
             this.mbl_loc.KeyDown += new System.Windows.Forms.KeyEventHandler(this.mbl_loc_KeyDown);
             // 
             // bc_name
@@ -1037,7 +1077,7 @@
             this.SaveBadLocation.Enabled = false;
             this.SaveBadLocation.Image = null;
             this.SaveBadLocation.IsShowBorder = true;
-            this.SaveBadLocation.Location = new System.Drawing.Point(578, 430);
+            this.SaveBadLocation.Location = new System.Drawing.Point(573, 604);
             this.SaveBadLocation.Margin = new System.Windows.Forms.Padding(4);
             this.SaveBadLocation.MoveImage = ((System.Drawing.Image)(resources.GetObject("SaveBadLocation.MoveImage")));
             this.SaveBadLocation.Name = "SaveBadLocation";
@@ -1048,6 +1088,7 @@
             this.SaveBadLocation.Tag = "IfRead";
             this.SaveBadLocation.Text = "保存";
             this.SaveBadLocation.UseVisualStyleBackColor = true;
+            this.SaveBadLocation.Visible = false;
             this.SaveBadLocation.Click += new System.EventHandler(this.SaveBadLocation_Click);
             // 
             // Make_Repair
@@ -1055,6 +1096,8 @@
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(1350, 880);
+            this.Controls.Add(this.label1);
+            this.Controls.Add(this.normalButton2);
             this.Controls.Add(this.nr_code);
             this.Controls.Add(this.cd_stepcode);
             this.Controls.Add(this.ms_reworkcheckno);
@@ -1202,5 +1245,7 @@
         private CustomControl.ValueLabel.ValueLabel pr_detail;
         private CustomControl.ValueLabel.ValueLabel ms_prodcode;
         private CustomControl.ValueLabel.ValueLabel ms_makecode;
+        private System.Windows.Forms.Label label1;
+        private CustomControl.ButtonUtil.NormalButton normalButton2;
     }
 }

+ 56 - 3
UAS_MES_ZT/FunctionCode/Make/Make_Repair.cs

@@ -72,6 +72,9 @@ namespace UAS_MES_NEW.Make
             cd_stepcode.DBTitle = "回流工序";
             cd_stepcode.DbChange += Cd_stepcode_DbChange;
 
+
+
+
             bd_soncode.FormName = Name;
             bd_soncode.TableName = "bom left join bomdetail on bd_bomid=bo_id left join product on bd_soncode=pr_code";
             bd_soncode.SetValueField = new string[] { "bd_soncode" };
@@ -116,6 +119,8 @@ namespace UAS_MES_NEW.Make
             GetSNCode.Focus();
         }
 
+
+
         private void Prodcode_DbChange(object sender, EventArgs e)
         {
             Dbfind = bd_soncode.ReturnData;
@@ -384,6 +389,7 @@ namespace UAS_MES_NEW.Make
                 bc_code.Text = BadInf_1[mb_id]["mb_badcode"];
                 bg_name.Text = BadInf_1[mb_id]["bg_name"];
                 bg_code.Text = BadInf_1[mb_id]["mb_bgcode"];
+                cd_stepcode.Text = BadInf_1[mb_id]["mb_dutystepcode"];
                 //mb_badremark.Text = BadInf_1[mb_id]["mb_badremark"];
                 mbr_id = "";
                 SaveRepairInf.Enabled = true;
@@ -396,6 +402,7 @@ namespace UAS_MES_NEW.Make
                 bc_name.Text = BadInf_1[mb_id]["bc_name"];
                 bg_code.Text = BadInf_1[mb_id]["mb_bgcode"];
                 bg_name.Text = BadInf_1[mb_id]["bg_name"];
+                cd_stepcode.Text = BadInf_1[mb_id]["mb_dutystepcode"];
                 //展示子节点信息
                 mbr_id = e.Node.Tag.ToString();
                 nrg_code.Text = BadInf_2[mbr_id]["nrg_code"];
@@ -423,14 +430,14 @@ namespace UAS_MES_NEW.Make
             sql.Clear();
             //不是返工工单时的取当前工单
             sql.Append("select mb_id,mb_sncode,mb_badcode,mb_bgcode,nvl(bc_name,mb_badcode) bc_name,nvl(bg_name,mb_bgcode) bg_name,");
-            sql.Append("mb_badremark from makebad left join badcode on bc_code=mb_badcode left join badgroup ");
+            sql.Append("mb_badremark,mb_dutystepcode from makebad left join badcode on bc_code=mb_badcode left join badgroup ");
             sql.Append("on bg_code=mb_bgcode where mb_sncode='" + (GetSNCode.Text == "" ? ms_sncode.Text : GetSNCode.Text) + "' and mb_makecode='" + macode + "' and mb_status=0");
             dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
             if (dt.Rows.Count == 0)
             {
                 sql.Clear();
                 sql.Append("select mb_id,mb_sncode,mb_badcode,mb_bgcode,nvl(bc_name,mb_badcode) bc_name,nvl(bg_name,mb_bgcode) bg_name, ");
-                sql.Append("mb_badremark from makebad left join badcode on bc_code=mb_badcode left join badgroup on bg_code=mb_bgcode  ");
+                sql.Append("mb_badremark,mb_dutystepcode from makebad left join badcode on bc_code=mb_badcode left join badgroup on bg_code=mb_bgcode  ");
                 sql.Append("left join make on ma_code=mb_makecode where mb_sncode='" + (GetSNCode.Text == "" ? ms_sncode.Text : GetSNCode.Text) + "' and mb_makecode<>'" + macode + "' and mb_status=0");
                 dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
             }
@@ -441,6 +448,7 @@ namespace UAS_MES_NEW.Make
                 string bg_name = dt.Rows[i]["bg_name"].ToString();
                 string bc_name = dt.Rows[i]["bc_name"].ToString();
                 string mb_badcode = dt.Rows[i]["mb_badcode"].ToString();
+                string mb_dutystepcode = dt.Rows[i]["mb_dutystepcode"].ToString();
                 string mb_bgcode = dt.Rows[i]["mb_bgcode"].ToString();
                 tnode_0.Text = (bg_name == "" ? mb_bgcode : bg_name) + ":" + (bc_name == "" ? mb_bgcode : bc_name);
                 tnode_0.Name = dt.Rows[i]["mb_bgcode"].ToString();
@@ -451,6 +459,7 @@ namespace UAS_MES_NEW.Make
                 dic.Add("mb_id", mb_id);
                 dic.Add("mb_sncode", dt.Rows[i]["mb_sncode"].ToString());
                 dic.Add("mb_badcode", dt.Rows[i]["mb_badcode"].ToString());
+                dic.Add("mb_dutystepcode", dt.Rows[i]["mb_dutystepcode"].ToString());
                 dic.Add("mb_bgcode", dt.Rows[i]["mb_bgcode"].ToString());
                 dic.Add("bc_name", dt.Rows[i]["bc_name"].ToString());
                 dic.Add("bg_name", dt.Rows[i]["bg_name"].ToString());
@@ -903,6 +912,7 @@ namespace UAS_MES_NEW.Make
         {
             //cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and  ( cd_ifburnout <>0) order by cd_stepno";
             cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' order by cd_stepno";
+
         }
 
         private void Clean_Click(object sender, EventArgs e)
@@ -951,6 +961,7 @@ namespace UAS_MES_NEW.Make
             //设置工序的条件
             //cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and  ( cd_ifburnout <>0) order by cd_stepno";
             cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "'  order by cd_stepno";
+
         }
 
         public void RefreshData()
@@ -1013,7 +1024,8 @@ namespace UAS_MES_NEW.Make
                 bc_code.Text = BadInf_1[mb_id]["mb_badcode"];
                 bg_name.Text = BadInf_1[mb_id]["bg_name"];
                 bg_code.Text = BadInf_1[mb_id]["mb_bgcode"];
-               // mb_badremark.Text = BadInf_1[mb_id]["mb_badremark"];
+                cd_stepcode.Text = BadInf_1[mb_id]["mb_dutystepcode"];
+                // mb_badremark.Text = BadInf_1[mb_id]["mb_badremark"];
                 mbr_id = "";
                 SaveRepairInf.Enabled = true;
             }
@@ -1025,6 +1037,7 @@ namespace UAS_MES_NEW.Make
                 bc_name.Text = BadInf_1[mb_id]["bc_name"];
                 bg_code.Text = BadInf_1[mb_id]["mb_bgcode"];
                 bg_name.Text = BadInf_1[mb_id]["bg_name"];
+                cd_stepcode.Text = BadInf_1[mb_id]["mb_dutystepcode"];
                 //展示子节点信息
                 mbr_id = e.Node.Tag.ToString();
                 nrg_code.Text = BadInf_2[mbr_id]["nrg_code"];
@@ -1090,5 +1103,45 @@ namespace UAS_MES_NEW.Make
                 else OperatResult.AppendText(">>" + retsn.Text + "录入不可为空\n", Color.Red, retsn);
             }
         }
+
+        private void normalButton2_Click(object sender, EventArgs e)
+        {
+            if (mb_id != "")
+            {
+                dt = (DataTable)dh.ExecuteSql("select cr_id from craft where cr_statuscode='AUDITED' and cr_code='" + cr_code.Text + "'", "select");
+                if (dt.Rows.Count == 0)
+                    OperatResult.AppendText(">>责任工序不存在\n", Color.Red);
+                else
+                {
+                    string cr_id = dt.Rows[0]["cr_id"].ToString();
+                    dt = (DataTable)dh.ExecuteSql("select cd_ifinput from craftdetail left join step on st_code=cd_stepcode where cd_crid='" + cr_id + "' and cd_stepcode='" + cd_stepcode.Text + "' and st_statuscode='AUDITED'", "select");
+                    if (dt.Rows.Count == 0)
+                        OperatResult.AppendText(">>责任工序不在工艺中\n", Color.Red);
+                    else
+                    {
+                        dt = dh.getFieldsDataByCondition("makeserial", new string[] { "nvl(ms_ifrework,0) ms_ifrework", "ms_paststep" }, "ms_sncode='" + ms_sncode.Text + "' and ms_makecode='" + macode + "'");
+                        List<string> SQLS = new List<string>();
+                        if (dt.Rows.Count > 0)
+                        {
+                            string ms_ifrework = dt.Rows[0]["ms_ifrework"].ToString();
+                            string ms_paststep = dt.Rows[0]["ms_paststep"].ToString();
+                            //如果回流的执行过的工序为空
+                            if (!ms_paststep.Contains(cd_stepcode.Text) && ms_paststep != "")
+                            {
+                                OperatResult.AppendText(">>不允许判定到未执行的工序\n", Color.Red);
+                                return;
+                            }
+                            string ms_code = dh.getFieldDataByCondition("makeserial", "ms_code", "ms_sncode = '" + ms_sncode.Text + "' and ms_makecode = '" + macode + "' order by ms_id desc").ToString();
+                            string dutyemcode = dh.getFieldDataByCondition("steppassed","sp_inman","sp_sncode in ('"+ ms_code + "','"+ ms_sncode.Text + "') and  sp_stepcode = '"+cd_stepcode.Text+"' and sp_makecode = '"+ macode + "' order by sp_id desc").ToString();
+                            dh.UpdateByCondition("makebad", "MB_DUTYEMCODE = '"+ dutyemcode + "',MB_DUTYSTEPCODE = '"+ cd_stepcode.Text+"'", "mb_id = "+mb_id+"");
+                            OperatResult.AppendText(">>责任工序复判成功\n", Color.Green);
+                            GetSNCode_KeyDown(sender, new KeyEventArgs(Keys.Enter));
+                        }
+                       
+                    }
+                }
+            }
+            else OperatResult.AppendText(">>必须选择不良现象\n", Color.Red);
+        }
     }
 }

+ 38 - 12
UAS_MES_ZT/FunctionCode/Make/Make_Repair.resx

@@ -124,6 +124,44 @@
     <value>190, 17</value>
   </metadata>
   <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
+  <data name="normalButton2.DownImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+    <value>
+        iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFcSURBVFhH5di7UsJAFMbxtDT6QMI76IAFT0npIE0K
+        GcRORxHklpAIBHLfbILV8XxeNsMznJ35F5vu+82kWYuILD4N7oq75roCw27sb/x5WBdc27btntY64o/i
+        DnZjPxy4S6A0R6PHO1WUNHc9ep4uxIXd2D8eP/XZowWUThBG+n3p0stsKbbJ0qFDFFfscQuUbpzm9Pqx
+        Eh8c4PGLkuX0Nl+LDw4GJckUTRaO+OBQo+SKpitXfHAwKClfZuuN+OBgUDJV0NzxxAeHM5TFxhffGUpe
+        aFp5n+KDg0FRfHH8nfjgUKPoktztXnxwMCgFX7xdID441ChlRf7+ID44GBTNl21wFB8capSqot0xFB8c
+        /lE6Wa70IU5oH0Ziw/5cFebpoPUwHPbL04nCJKUgisWF3dgPB3gABc9v7fvBoBcnaVKdvkha2I39cPjx
+        oPrhusndcPinpIXd2N8gIusbTaFspKtR2SQAAAAASUVORK5CYII=
+</value>
+  </data>
+  <data name="normalButton2.MoveImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+    <value>
+        iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFzSURBVFhH5djNSgJRGMZxL2P2gTfQFbZvHSEZFBEW
+        CEIQBEIgVFiS9qXWoDmp4/fHzDmjM2a+vU/QqUVX0DvwXxxn9fwYXJwYEcXWNzIWt83dcq7AsBv7LXgA
+        ZI0r71/aaqjCJf8o7sFu7IcDFwdK4vimrv1oSZXRnArdQFzYjf3pQkOzRxIoVWc6X5X6M7ruBGIr9mbU
+        9MIVe9hAcXvBO125WnxwgMcXSpcPF20tPjgYlI5eUK6lxAcHg9Lmw3nTFx8cDEpLLSjr+OKDg0FpqojO
+        Gp744GBQ3vyITutT8cHBoDheRCe1ifjgYFBe+ZCxJ+KDg0GpT0NKv4zFBweDUpuEdFQdiQ8OBsXmw2Fl
+        JD44/KCM53TwNBQfHAzKMx/2Hgfig8M3SrXYUasUfz67DwOxYf9dV5urg+RWzta4aEnxn83OfV9c2I39
+        cIAHUOJceTNbUfmW94GX0sJu7IcDPH5fXCe4EvfXxe5/D7ux3yKi2CfkPhTy27lqkwAAAABJRU5ErkJg
+        gg==
+</value>
+  </data>
+  <data name="normalButton2.NormalImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+    <value>
+        iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAGVSURBVFhH5di7agJRFIXhDSKoYBQEC8FCECwEQRBE
+        4uUVEtTiPKVlom2wttM6IfF+15njXHRnL19jD/zFmanWV8zAEDNTp9OJS6/Sm2QUht3YH4cHtdvtF6k7
+        mUwG1tqd3FR3YTf2w0FKUVOu6XT68Xgw3+8PtWH/bDYbCkeLGo1Gz/d9JwzvrL0gCKx49KlerxtIBUGo
+        PjjAg2q1mqDc2fN99cEBHlStVk0oB+t56oMDPKhSqZggDNm1N/XBAR5ULpeNvGD46rrqgwM8qFQqGV8O
+        56ujPjjAg4rFosFL5ni5qA8O8KBCoWBuns/701l9cIAH5fN5QfF4dzipDw7woFwuZ+zN483+oD44wIOy
+        2azB52i13asPDvCgTCZjHGt5sdmqDw7woHQ6bRzX8ny1UR8c4EHJZNJc5fC7XKsPDvCgRCLR2x9Pzt9q
+        zT+Lpdqw/3A6W/HoUywWa32Nx8OL4zwffM8X6sJu7IcDPCgajaak7udoNNjsdgc81BZ2Yz8c4PH8cR2J
+        ROJSU3qXjMKwG/vjzEz/skOI3Zqgv7AAAAAASUVORK5CYII=
+</value>
+  </data>
   <data name="RepairComplete.DownImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
@@ -244,18 +282,6 @@
   <metadata name="DeleteCom.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="mbp_part1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="DeleteCom.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mbl_loc1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="DeletePos.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
   <metadata name="mbl_loc1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>

+ 25 - 5
UAS_MES_ZT/FunctionCode/Make/Make_RepairOk.cs

@@ -161,7 +161,10 @@ namespace UAS_MES_NEW.Make
                 if (GetSNCode.Text == "")
                 {
                     OperatResult.AppendText(">>序列号不允许为空\n", Color.Red);
+                    string cdstepcode = cd_stepcode.Text;
+                    //cd_stepcode.Enabled = true;
                     BaseUtil.CleanForm(this);
+                    cd_stepcode.Text = cdstepcode;
                     BadCodeTree.Nodes.Clear();
                     return;
                 }
@@ -189,14 +192,20 @@ namespace UAS_MES_NEW.Make
                         if (ms_status == "4")
                         {
                             OperatResult.AppendText(">>序列号:" + GetSNCode.Text + "已处于报废状态\n", Color.Red);
+                            string cdstepcode = cd_stepcode.Text;
+                            //cd_stepcode.Enabled = true;
                             BaseUtil.CleanForm(this);
+                            cd_stepcode.Text = cdstepcode;
                             BadCodeTree.Nodes.Clear();
                             return;
                         }
                         if (ms_status != "3")
                         {
                             OperatResult.AppendText(">>序列号:" + GetSNCode.Text + "不处于维修状态\n", Color.Red);
+                            string cdstepcode = cd_stepcode.Text;
+                            //cd_stepcode.Enabled = true;
                             BaseUtil.CleanForm(this);
+                            cd_stepcode.Text = cdstepcode;
                             BadCodeTree.Nodes.Clear();
                             return;
                         }
@@ -206,14 +215,20 @@ namespace UAS_MES_NEW.Make
                         if (reworkstatus == "4")
                         {
                             OperatResult.AppendText(">>序列号:" + GetSNCode.Text + "已处于报废状态\n", Color.Red);
+                            string cdstepcode = cd_stepcode.Text;
+                            //cd_stepcode.Enabled = true;
                             BaseUtil.CleanForm(this);
+                            cd_stepcode.Text = cdstepcode;
                             BadCodeTree.Nodes.Clear();
                             return;
                         }
                         if (reworkstatus != "0" && reworkstatus != "3")
                         {
                             OperatResult.AppendText(">>序列号:" + GetSNCode.Text + "不处于维修状态\n", Color.Red);
+                            string cdstepcode = cd_stepcode.Text;
+                            //cd_stepcode.Enabled = true;
                             BaseUtil.CleanForm(this);
+                            cd_stepcode.Text = cdstepcode;
                             BadCodeTree.Nodes.Clear();
                             return;
                         }
@@ -222,7 +237,10 @@ namespace UAS_MES_NEW.Make
                 else
                 {
                     OperatResult.AppendText(">>序列号:" + GetSNCode.Text + "不存在\n", Color.Red);
+                    string cdstepcode = cd_stepcode.Text;
+                    //cd_stepcode.Enabled = true;
                     BaseUtil.CleanForm(this);
+                    cd_stepcode.Text = cdstepcode;
                     BadCodeTree.Nodes.Clear();
                     return;
                 }
@@ -609,7 +627,7 @@ namespace UAS_MES_NEW.Make
                         else
                             SQLS.Add("update makeserial set ms_checkno='',ms_paststep = ms_paststep || case when instr(','||ms_paststep||',','" + User.CurrentStepCode + "')=0 then ','||'" + User.CurrentStepCode + "' end , ms_nextstepcode ='" + cd_stepcode.Text + "',ms_craftcode='" + cr_code.Text + "',ms_stepcode='" + User.CurrentStepCode + "',ms_reworkstatus=1 where ms_id='" + msid + "'");
                     }
-                    SQLS.Add("update makebad set mb_status=-1,mb_okman ='"+User.UserName+"' where mb_sncode='" + ms_sncode.Text + "' and mb_makecode='" + ms_makecode.Text + "'");
+                    SQLS.Add("update makebad set mb_status=-1,mb_okman ='"+User.UserName+"' where mb_sncode='" + ms_sncode.Text + "' and mb_makecode='" + ms_makecode.Text + "' and mb_status = 0");
                     //取消最近拆解部件
                     SQLS.Add("update craftmaterial set cm_lastdeco=0 where cm_sncode='" + ms_sncode.Text + "' and cm_makecode='" + ms_makecode.Text + "' and nvl(cm_lastdeco,0)<>0");
                     //if (checkBox1.Checked)
@@ -660,24 +678,26 @@ namespace UAS_MES_NEW.Make
                             string reworkcode = dt.Rows[0]["ms_reworkcode"].ToString();
                             if (ms_ifrework == "0")
                             {
-                                dh.UpdateByCondition("makeserial", "ms_paststep = ms_paststep ||'," + User.CurrentStepCode + "',ms_status=4,ms_nextstepcode='',ms_stepcode='" + User.CurrentStepCode + "'", "ms_sncode='" + ms_sncode.Text + "' and ms_makecode='" + macode + "'");
+                                dh.UpdateByCondition("makeserial", "ms_paststep = ms_paststep ||'," + User.CurrentStepCode + "',ms_status=4,ms_nextstepcode=''", "ms_sncode='" + ms_sncode.Text + "' and ms_makecode='" + macode + "'");
                             }
                             else
                             {
                                 sqls.Clear();
-                                sqls.Add("update makeserial set ms_paststep = ms_paststep ||'," + User.CurrentStepCode + "',ms_status=4,ms_reworkstatus= 4,ms_nextstepcode='',ms_stepcode='" + User.CurrentStepCode + "' where ms_sncode='" + ms_sncode.Text + "' and ms_makecode='" + macode + "'");
+                                sqls.Add("update makeserial set ms_paststep = ms_paststep ||'," + User.CurrentStepCode + "',ms_status=4,ms_reworkstatus= 4,ms_nextstepcode='' where ms_sncode='" + ms_sncode.Text + "' and ms_makecode='" + macode + "'");
                                 sqls.Add("update oqcbatch set ob_nowcheckqty=ob_nowcheckqty-1 where ob_checkno='" + ms_reworkcheckno.Text + "'");
                                 sqls.Add("delete from oqcbatchdetail where obd_sncode='" + ms_sncode.Text + "' and obd_checkno='" + ms_reworkcheckno.Text + "'");
                                 sqls.Add("update ReworkDetail set rd_rwstatus='报废' where rd_reid=(select re_id from rework where re_code='" + reworkcode + "') and rd_sncode='" + reworkcode + "'");
                                 dh.ExecuteSQLTran(sqls.ToArray());
                             }
                         }
+                        dh.ExecuteSql("update makebad set mb_status=-2,mb_okman ='" + User.UserName + "' where mb_sncode='" + ms_sncode.Text + "' and mb_makecode='" + ms_makecode.Text + "' and mb_status = 0","update");
                         dh.UpdateByCondition("makecraftdetail", "mcd_inqty=mcd_inqty-1,mcd_outqty=mcd_outqty-1", "mcd_macode='" + ms_makecode.Text + "' and mcd_stepcode='" + ms_stepcode + "'");
                         dh.UpdateByCondition("make", "MA_NGMADEQTY=nvl(MA_NGMADEQTY,0)+1", "ma_code='" + macode + "'");
                         LogicHandler.InsertMakeProcess(ms_sncode.Text, ms_makecode.Text, User.UserSourceCode, "报废", "序列号报废", User.UserCode);
                         LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, macode, User.UserLineCode, User.UserSourceCode, "报废", "序列号报废", ms_sncode.Text, ms_checkno.Text);
                         OperatResult.AppendText(">>报废成功\n", Color.Green);
                         GetSNCode.Clear();
+                        GetSNCode.Focus();
                         BaseUtil.CleanForm(this);
                         BadCodeTree.Nodes.Clear();
                     }
@@ -909,7 +929,7 @@ namespace UAS_MES_NEW.Make
         private void cr_code_UserControlTextChanged(object sender, EventArgs e)
         {
             //cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and  ( cd_ifburnout <>0) order by cd_stepno";
-            cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' order by cd_stepno";
+            cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and cd_ifoqc <> -1 order by cd_stepno";
         }
 
         private void Clean_Click(object sender, EventArgs e)
@@ -957,7 +977,7 @@ namespace UAS_MES_NEW.Make
             bd_soncode.Condition = "bd_mothercode='" + ms_prodcode.Text + "' and NVL(bd_usestatus,' ')<>'DISABLE'";
             //设置工序的条件
             //cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and  ( cd_ifburnout <>0) order by cd_stepno";
-            cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "'  order by cd_stepno";
+            cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "'  and cr_prodcode='" + ms_prodcode.Text + "' and cd_ifoqc <> -1  order by cd_stepno";
         }
 
         public void RefreshData()

+ 83 - 11
UAS_MES_ZT/FunctionCode/Make/Make_StepReport.Designer.cs

@@ -81,10 +81,15 @@
             this.ms_linecode = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.ms_sourcecode = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.ms_okqty = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ms_agokqty = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.ms_ngqty = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.AddBad = new System.Windows.Forms.DataGridViewImageColumn();
             this.ms_indate = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.DeleteRow = new System.Windows.Forms.DataGridViewImageColumn();
+            this.agoksum = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
+            this.label9 = new System.Windows.Forms.Label();
+            this.label10 = new System.Windows.Forms.Label();
+            this.agokqty = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.NumOnlyTextBox();
             ((System.ComponentModel.ISupportInitialize)(this.BatchProductDGV56)).BeginInit();
             this.SuspendLayout();
             // 
@@ -206,7 +211,7 @@
             // 
             this.label4.AutoSize = true;
             this.label4.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label4.Location = new System.Drawing.Point(387, 563);
+            this.label4.Location = new System.Drawing.Point(237, 563);
             this.label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label4.Name = "label4";
             this.label4.Size = new System.Drawing.Size(86, 31);
@@ -228,23 +233,23 @@
             // 
             this.label6.AutoSize = true;
             this.label6.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label6.Location = new System.Drawing.Point(43, 719);
+            this.label6.Location = new System.Drawing.Point(6, 721);
             this.label6.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label6.Name = "label6";
-            this.label6.Size = new System.Drawing.Size(134, 31);
+            this.label6.Size = new System.Drawing.Size(110, 31);
             this.label6.TabIndex = 236;
-            this.label6.Text = "良品录入";
+            this.label6.Text = "良品录入";
             // 
             // label7
             // 
             this.label7.AutoSize = true;
             this.label7.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label7.Location = new System.Drawing.Point(453, 718);
+            this.label7.Location = new System.Drawing.Point(721, 720);
             this.label7.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label7.Name = "label7";
-            this.label7.Size = new System.Drawing.Size(134, 31);
+            this.label7.Size = new System.Drawing.Size(110, 31);
             this.label7.TabIndex = 238;
-            this.label7.Text = "不良录入";
+            this.label7.Text = "不良录入";
             // 
             // label8
             // 
@@ -265,7 +270,7 @@
             this.normalButton2.DownImage = ((System.Drawing.Image)(resources.GetObject("normalButton2.DownImage")));
             this.normalButton2.Image = ((System.Drawing.Image)(resources.GetObject("normalButton2.Image")));
             this.normalButton2.IsShowBorder = true;
-            this.normalButton2.Location = new System.Drawing.Point(942, 718);
+            this.normalButton2.Location = new System.Drawing.Point(1062, 716);
             this.normalButton2.Margin = new System.Windows.Forms.Padding(4);
             this.normalButton2.MoveImage = ((System.Drawing.Image)(resources.GetObject("normalButton2.MoveImage")));
             this.normalButton2.Name = "normalButton2";
@@ -283,7 +288,7 @@
             this.ngqty.AllPower = null;
             this.ngqty.BackColor = System.Drawing.Color.White;
             this.ngqty.ID = null;
-            this.ngqty.Location = new System.Drawing.Point(570, 719);
+            this.ngqty.Location = new System.Drawing.Point(838, 721);
             this.ngqty.Name = "ngqty";
             this.ngqty.Negative = false;
             this.ngqty.Power = null;
@@ -298,7 +303,7 @@
             this.okqty.AllPower = null;
             this.okqty.BackColor = System.Drawing.Color.White;
             this.okqty.ID = null;
-            this.okqty.Location = new System.Drawing.Point(160, 720);
+            this.okqty.Location = new System.Drawing.Point(123, 722);
             this.okqty.Name = "okqty";
             this.okqty.Negative = false;
             this.okqty.Power = null;
@@ -326,7 +331,7 @@
             this.oksum.AutoSize = true;
             this.oksum.CutLength = null;
             this.oksum.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.oksum.Location = new System.Drawing.Point(481, 563);
+            this.oksum.Location = new System.Drawing.Point(331, 563);
             this.oksum.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.oksum.MaximumSize = new System.Drawing.Size(225, 0);
             this.oksum.Name = "oksum";
@@ -450,6 +455,7 @@
             this.ms_linecode,
             this.ms_sourcecode,
             this.ms_okqty,
+            this.ms_agokqty,
             this.ms_ngqty,
             this.AddBad,
             this.ms_indate,
@@ -665,6 +671,13 @@
             this.ms_okqty.Name = "ms_okqty";
             this.ms_okqty.ReadOnly = true;
             // 
+            // ms_agokqty
+            // 
+            this.ms_agokqty.DataPropertyName = "ms_agokqty";
+            this.ms_agokqty.HeaderText = "再次通过数";
+            this.ms_agokqty.Name = "ms_agokqty";
+            this.ms_agokqty.ReadOnly = true;
+            // 
             // ms_ngqty
             // 
             this.ms_ngqty.DataPropertyName = "ms_ngqty";
@@ -698,11 +711,65 @@
             this.DeleteRow.Name = "DeleteRow";
             this.DeleteRow.Width = 50;
             // 
+            // agoksum
+            // 
+            this.agoksum.AutoSize = true;
+            this.agoksum.CutLength = null;
+            this.agoksum.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.agoksum.Location = new System.Drawing.Point(584, 563);
+            this.agoksum.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.agoksum.MaximumSize = new System.Drawing.Size(225, 0);
+            this.agoksum.Name = "agoksum";
+            this.agoksum.Size = new System.Drawing.Size(0, 31);
+            this.agoksum.TabIndex = 242;
+            this.agoksum.Tag = "ma_prodcode";
+            // 
+            // label9
+            // 
+            this.label9.AutoSize = true;
+            this.label9.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.label9.Location = new System.Drawing.Point(450, 563);
+            this.label9.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label9.Name = "label9";
+            this.label9.Size = new System.Drawing.Size(134, 31);
+            this.label9.TabIndex = 241;
+            this.label9.Text = "再次通过数";
+            // 
+            // label10
+            // 
+            this.label10.AutoSize = true;
+            this.label10.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.label10.Location = new System.Drawing.Point(340, 719);
+            this.label10.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label10.Name = "label10";
+            this.label10.Size = new System.Drawing.Size(158, 31);
+            this.label10.TabIndex = 244;
+            this.label10.Text = "再次通过录入";
+            // 
+            // agokqty
+            // 
+            this.agokqty.AllPower = null;
+            this.agokqty.BackColor = System.Drawing.Color.White;
+            this.agokqty.ID = null;
+            this.agokqty.Location = new System.Drawing.Point(505, 722);
+            this.agokqty.Name = "agokqty";
+            this.agokqty.Negative = false;
+            this.agokqty.Power = null;
+            this.agokqty.Size = new System.Drawing.Size(196, 28);
+            this.agokqty.Str = null;
+            this.agokqty.Str1 = null;
+            this.agokqty.Str2 = null;
+            this.agokqty.TabIndex = 243;
+            // 
             // Make_StepReport
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(1383, 765);
+            this.Controls.Add(this.label10);
+            this.Controls.Add(this.agokqty);
+            this.Controls.Add(this.agoksum);
+            this.Controls.Add(this.label9);
             this.Controls.Add(this.label8);
             this.Controls.Add(this.normalButton2);
             this.Controls.Add(this.label7);
@@ -801,9 +868,14 @@
         private System.Windows.Forms.DataGridViewTextBoxColumn ms_linecode;
         private System.Windows.Forms.DataGridViewTextBoxColumn ms_sourcecode;
         private System.Windows.Forms.DataGridViewTextBoxColumn ms_okqty;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ms_agokqty;
         private System.Windows.Forms.DataGridViewTextBoxColumn ms_ngqty;
         private System.Windows.Forms.DataGridViewImageColumn AddBad;
         private System.Windows.Forms.DataGridViewTextBoxColumn ms_indate;
         private System.Windows.Forms.DataGridViewImageColumn DeleteRow;
+        private CustomControl.ValueLabel.ValueLabel agoksum;
+        private System.Windows.Forms.Label label9;
+        private System.Windows.Forms.Label label10;
+        private CustomControl.TextBoxWithIcon.NumOnlyTextBox agokqty;
     }
 }

+ 20 - 9
UAS_MES_ZT/FunctionCode/Make/Make_StepReport.cs

@@ -79,12 +79,12 @@ namespace UAS_MES_NEW.Make
         private void FillDataGridView()
         {
             sql.Clear();
-            sql.Append("select ms_id,ms_makecode,ms_prodcode,ms_stepcode,ms_linecode,ms_sourcecode,ms_man,ms_indate,ms_okqty,ms_ngqty from MES_STEPREPORT ");
-            sql.Append("where ms_makecode = '"+ma_code.Text+"' and ms_stepcode = '"+User.CurrentStepCode+"' and ms_status = 0");
+            sql.Append("select ms_id,ms_makecode,ms_prodcode,ms_stepcode,ms_linecode,ms_sourcecode,ms_man,ms_indate,ms_okqty,ms_ngqty,ms_agokqty from MES_STEPREPORT ");
+            sql.Append("where ms_makecode = '"+ma_code.Text+"' and ms_stepcode = '"+User.CurrentStepCode+"' and ms_status = 0 order by ms_id desc");
             DataTable dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
             BaseUtil.FillDgvWithDataTable(BatchProductDGV56, dt);
             sql.Clear();
-            sql.Append("select sum(ms_okqty)oksum,sum(ms_ngqty)ngsum from MES_STEPREPORT ");
+            sql.Append("select sum(ms_okqty)oksum,sum(ms_agokqty) agoksum,sum(ms_ngqty)ngsum from MES_STEPREPORT ");
             sql.Append("where ms_makecode = '" + ma_code.Text + "' and ms_stepcode = '" + User.CurrentStepCode + "' and ms_status = 0");
             dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
             BaseUtil.SetFormValue(this.Controls, dt);
@@ -238,7 +238,7 @@ namespace UAS_MES_NEW.Make
 
         private void normalButton2_Click(object sender, EventArgs e)
         {
-            if (okqty.Text == "" && ngqty.Text == "")
+            if (okqty.Text == "" && ngqty.Text == ""&&agokqty.Text == "")
             {
                 OperateResult.AppendText(">>录入信息不可为空\n", Color.Green);
                 return;
@@ -250,6 +250,17 @@ namespace UAS_MES_NEW.Make
             }
             int ok = int.Parse(okqty.Text == "" ? "0" : okqty.Text);
             int ng = int.Parse(ngqty.Text == "" ? "0" : ngqty.Text);
+            int agok = int.Parse(agokqty.Text == "" ? "0" : agokqty.Text);
+
+            int inagsum = int.Parse(agoksum.Text == "" ? "0" : agoksum.Text);
+            int inngsum = int.Parse(ngsum.Text == "" ? "0" : ngsum.Text);
+
+            if (agok + inagsum > inngsum)
+            {
+                OperateResult.AppendText(">>再次通过数:"+agok+"+已采集再次通过数:"+inagsum+"大于不良数:"+inngsum+",无法采集\n", Color.Red);
+                return;
+            }
+
             string msid = dh.GetSEQ("MES_STEPREPORT_seq");
 
             if (dh.CheckExist("step", "st_code ='" + User.CurrentStepCode + "' and st_ifinput = -1"))
@@ -305,20 +316,20 @@ namespace UAS_MES_NEW.Make
 
             }
 
+         
 
-            
 
             sql.Clear();
             sql.Append("insert into MES_STEPREPORT (MS_ID,MS_MAKECODE,MS_PRODCODE ,MS_STEPCODE,");
             sql.Append("MS_LINECODE,MS_SOURCECODE,MS_MAN,MS_INDATE,MS_OKQTY,MS_NGQTY,");
-            sql.Append("MS_REMARK,MS_STATUS) values("+ msid + ",'" + ma_code.Text + "','" + ma_prodcode.Text + "',");
+            sql.Append("MS_REMARK,MS_STATUS,MS_AGOKQTY) values(" + msid + ",'" + ma_code.Text + "','" + ma_prodcode.Text + "',");
             sql.Append("'" +User.CurrentStepCode + "','" + User.UserLineCode + "','" + User.UserSourceCode + "','" + User.UserName + "',");
-            sql.Append("sysdate,'" + ok + "','" + ng + "','" + Remark.Text + "','" + 0 + "')");
+            sql.Append("sysdate,'" + ok + "','" + ng + "','" + Remark.Text + "','" + 0 + "','"+agok+"')");
             dh.ExecuteSql(sql.GetString(), "insert");
-            LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ma_code.Text, User.UserLineCode, User.UserSourceCode, "工序报工", "良品:"+ok+",不良品:"+ng+"", "", "");
+            LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ma_code.Text, User.UserLineCode, User.UserSourceCode, "工序报工", "良品:"+ok+",再次通过:"+agok+",不良品:"+ng+"", "", "");
             //数据插入成功后加载Grid的数据
             FillDataGridView();
-            OperateResult.AppendText(">>工单"+ma_code.Text+",良品:" + ok + ",不良品:" + ng + "报工成功\n", Color.Green, okqty,ngqty);
+            OperateResult.AppendText(">>工单"+ma_code.Text+",良品:" + ok + ",再次通过:" + agok + ",不良品:" + ng + "报工成功\n", Color.Green, okqty,ngqty,agokqty);
             Remark.Text = "";
         }
     }

+ 3 - 0
UAS_MES_ZT/FunctionCode/Make/Make_StepReport.resx

@@ -398,6 +398,9 @@
   <metadata name="ms_okqty.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
+  <metadata name="ms_agokqty.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
   <metadata name="ms_ngqty.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>

+ 13 - 13
UAS_MES_ZT/FunctionCode/Make/Make_TestCollection.Designer.cs

@@ -84,7 +84,6 @@ namespace UAS_MES_NEW.Make
             this.ob_batchqty_label = new System.Windows.Forms.Label();
             this.ob_nowcheckqty_label = new System.Windows.Forms.Label();
             this.lastsn = new System.Windows.Forms.Label();
-            this.lastresult = new System.Windows.Forms.Label();
             this.ob_sendqty = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
             this.ob_batchqty = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
             this.ob_nowcheckqty = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
@@ -115,6 +114,7 @@ namespace UAS_MES_NEW.Make
             this.bc_remark = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.EnterTextBox();
             this.bc_groupcode = new UAS_MES_NEW.CustomControl.ComBoxWithFocus.ComBoxWithFocus();
             this.ms_sncode = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SnCollectionBox();
+            this.lastresult = new System.Windows.Forms.Button();
             ((System.ComponentModel.ISupportInitialize)(this.BadInfSource)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.XmlWatcher)).BeginInit();
             this.SuspendLayout();
@@ -636,21 +636,11 @@ namespace UAS_MES_NEW.Make
             // 
             this.lastsn.AutoSize = true;
             this.lastsn.Font = new System.Drawing.Font("宋体", 25F, System.Drawing.FontStyle.Bold);
-            this.lastsn.Location = new System.Drawing.Point(499, 291);
+            this.lastsn.Location = new System.Drawing.Point(496, 272);
             this.lastsn.Name = "lastsn";
             this.lastsn.Size = new System.Drawing.Size(0, 50);
             this.lastsn.TabIndex = 225;
             // 
-            // lastresult
-            // 
-            this.lastresult.AutoSize = true;
-            this.lastresult.Font = new System.Drawing.Font("宋体", 30F, System.Drawing.FontStyle.Bold);
-            this.lastresult.ForeColor = System.Drawing.Color.Red;
-            this.lastresult.Location = new System.Drawing.Point(681, 363);
-            this.lastresult.Name = "lastresult";
-            this.lastresult.Size = new System.Drawing.Size(0, 60);
-            this.lastresult.TabIndex = 226;
-            // 
             // ob_sendqty
             // 
             this.ob_sendqty.AutoSize = true;
@@ -1076,6 +1066,16 @@ namespace UAS_MES_NEW.Make
             this.ms_sncode.Tag = "IfRead";
             this.ms_sncode.KeyDown += new System.Windows.Forms.KeyEventHandler(this.ms_code_KeyDown);
             // 
+            // lastresult
+            // 
+            this.lastresult.BackColor = System.Drawing.SystemColors.Control;
+            this.lastresult.Font = new System.Drawing.Font("宋体", 25F, System.Drawing.FontStyle.Bold);
+            this.lastresult.Location = new System.Drawing.Point(528, 340);
+            this.lastresult.Name = "lastresult";
+            this.lastresult.Size = new System.Drawing.Size(406, 73);
+            this.lastresult.TabIndex = 226;
+            this.lastresult.UseVisualStyleBackColor = false;
+            // 
             // Make_TestCollection
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
@@ -1251,7 +1251,7 @@ namespace UAS_MES_NEW.Make
         private System.Windows.Forms.Label ob_batchqty_label;
         private CustomControl.ValueLabel.ValueLabel ob_nowcheckqty;
         private System.Windows.Forms.Label ob_nowcheckqty_label;
-        private System.Windows.Forms.Label lastresult;
         private System.Windows.Forms.Label lastsn;
+        private System.Windows.Forms.Button lastresult;
     }
 }

+ 2 - 2
UAS_MES_ZT/FunctionCode/Make/Make_TestCollection.cs

@@ -426,7 +426,7 @@ namespace UAS_MES_NEW.Make
                             LogicHandler.DoCommandLog(Tag.ToString(), biduisn.Text == "" ? User.UserCode : biduisn.Text, ma_code.Text, User.UserLineCode, User.UserSourceCode, "采集良品", "采集良品成功", LastSncode, ob_checkno.Text);
                             lastsn.Text = ms_sncode.Text;
                             lastresult.Text = "OK";
-                            lastresult.ForeColor = Color.Green;
+                            lastresult.BackColor = Color.Green;
                             OperateResult.AppendText(">>" + ms_sncode.Text + "良品采集成功\n", Color.Green, ms_sncode, biduisn);
                             //if (bidui.Checked)
                             //    biduisn.Focus();
@@ -615,7 +615,7 @@ namespace UAS_MES_NEW.Make
                     OperateResult.AppendText(">>" + ms_sncode.Text + "成功采集为不良\n", Color.OrangeRed);
                     lastsn.Text = ms_sncode.Text;
                     lastresult.Text = "FAILED";
-                    lastresult.ForeColor = Color.Red;
+                    lastresult.BackColor = Color.Red;
                     LastSncode = ms_sncode.Text;
                     //采集完不良,聚焦序列号
                     ms_sncode.Focus();

+ 2 - 2
UAS_MES_ZT/FunctionCode/OQC/OQC_SamplingDataCollection.cs

@@ -314,9 +314,9 @@ namespace UAS_MES_NEW.OQC
                             //插入MakeBad表
                             sql.Clear();
                             sql.Append("insert into makebad(mb_id,mb_makecode,mb_mscode,mb_sncode,mb_inman,mb_indate,mb_stepcode");
-                            sql.Append(",mb_sourcecode,mb_badcode,mb_bgcode,mb_badtable,mb_soncode,mb_badname,mb_status,mb_bgname,mb_type)");
+                            sql.Append(",mb_sourcecode,mb_badcode,mb_bgcode,mb_badtable,mb_soncode,mb_badname,mb_status,mb_bgname,mb_type,MB_DUTYSTEPCODE,MB_DUTYEMCODE)");
                             sql.Append("select makebad_seq.nextval,ma_code,ms_code,ms_sncode,'" + User.UserCode + "',sysdate,'" + User.CurrentStepCode + "',ms_sourcecode,:bc_code,:bg_code,'',");
-                            sql.Append("sp_soncode,:bc_name,'0',:bg_name,'Client' from make left join makeSerial on ms_makecode=ma_code left join stepProduct on ");
+                            sql.Append("sp_soncode,:bc_name,'0',:bg_name,'Client','"+User.CurrentStepCode+"','"+User.UserCode+"' from make left join makeSerial on ms_makecode=ma_code left join stepProduct on ");
                             sql.Append("sp_mothercode=ma_prodcode and sp_stepcode=ms_nextstepcode where ms_sncode='" + sncode.Text + "' and ms_makecode='" + ob_makecode.Text + "'");
                             dh.BatchInsert(sql.GetString(), new string[] { "bc_code", "bg_code", "bc_name", "bg_name" }, bc_code.ToArray(), bg_code.ToArray(), bc_name.ToArray(), bg_name.ToArray());
                             dh.ExecuteSql("update oqcbatchdetail set obd_ifng = -1 where obd_checkno='" + ob_checkno.Text + "' and obd_sncode='" + sncode.Text + "'", "update");

+ 218 - 165
UAS_MES_ZT/FunctionCode/Packing/Packing_PackageCollection.Designer.cs

@@ -117,9 +117,10 @@
             // 
             this.pa_makecode.AutoSize = true;
             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(831, 427);
+            this.pa_makecode.Location = new System.Drawing.Point(1246, 640);
+            this.pa_makecode.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_makecode.Name = "pa_makecode";
-            this.pa_makecode.Size = new System.Drawing.Size(0, 21);
+            this.pa_makecode.Size = new System.Drawing.Size(0, 31);
             this.pa_makecode.TabIndex = 76;
             this.pa_makecode.Visible = false;
             // 
@@ -128,9 +129,10 @@
             this.label13.AutoSize = true;
             this.label13.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.label13.ForeColor = System.Drawing.Color.Black;
-            this.label13.Location = new System.Drawing.Point(7, 554);
+            this.label13.Location = new System.Drawing.Point(10, 831);
+            this.label13.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label13.Name = "label13";
-            this.label13.Size = new System.Drawing.Size(58, 21);
+            this.label13.Size = new System.Drawing.Size(86, 31);
             this.label13.TabIndex = 105;
             this.label13.Text = "序列号";
             // 
@@ -138,9 +140,10 @@
             // 
             this.Cancel.AutoSize = true;
             this.Cancel.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.Cancel.Location = new System.Drawing.Point(279, 554);
+            this.Cancel.Location = new System.Drawing.Point(418, 831);
+            this.Cancel.Margin = new System.Windows.Forms.Padding(4);
             this.Cancel.Name = "Cancel";
-            this.Cancel.Size = new System.Drawing.Size(93, 25);
+            this.Cancel.Size = new System.Drawing.Size(136, 35);
             this.Cancel.TabIndex = 129;
             this.Cancel.Text = "取消装箱";
             this.Cancel.UseVisualStyleBackColor = true;
@@ -149,9 +152,10 @@
             // 
             this.pa_id.AutoSize = true;
             this.pa_id.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_id.Location = new System.Drawing.Point(799, 427);
+            this.pa_id.Location = new System.Drawing.Point(1198, 640);
+            this.pa_id.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_id.Name = "pa_id";
-            this.pa_id.Size = new System.Drawing.Size(0, 21);
+            this.pa_id.Size = new System.Drawing.Size(0, 31);
             this.pa_id.TabIndex = 153;
             this.pa_id.Visible = false;
             // 
@@ -159,9 +163,10 @@
             // 
             this.pr_packrule.AutoSize = true;
             this.pr_packrule.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_packrule.Location = new System.Drawing.Point(849, 418);
+            this.pr_packrule.Location = new System.Drawing.Point(1274, 627);
+            this.pr_packrule.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pr_packrule.Name = "pr_packrule";
-            this.pr_packrule.Size = new System.Drawing.Size(0, 21);
+            this.pr_packrule.Size = new System.Drawing.Size(0, 31);
             this.pr_packrule.TabIndex = 173;
             this.pr_packrule.Visible = false;
             // 
@@ -169,9 +174,10 @@
             // 
             this.pa_status.AutoSize = true;
             this.pa_status.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_status.Location = new System.Drawing.Point(780, 456);
+            this.pa_status.Location = new System.Drawing.Point(1170, 684);
+            this.pa_status.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_status.Name = "pa_status";
-            this.pa_status.Size = new System.Drawing.Size(0, 21);
+            this.pa_status.Size = new System.Drawing.Size(0, 31);
             this.pa_status.TabIndex = 174;
             this.pa_status.Visible = false;
             // 
@@ -179,9 +185,10 @@
             // 
             this.pa_sccode.AutoSize = true;
             this.pa_sccode.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_sccode.Location = new System.Drawing.Point(831, 456);
+            this.pa_sccode.Location = new System.Drawing.Point(1246, 684);
+            this.pa_sccode.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_sccode.Name = "pa_sccode";
-            this.pa_sccode.Size = new System.Drawing.Size(0, 21);
+            this.pa_sccode.Size = new System.Drawing.Size(0, 31);
             this.pa_sccode.TabIndex = 176;
             this.pa_sccode.Visible = false;
             // 
@@ -189,9 +196,10 @@
             // 
             this.pa_checkno.AutoSize = true;
             this.pa_checkno.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_checkno.Location = new System.Drawing.Point(825, 456);
+            this.pa_checkno.Location = new System.Drawing.Point(1238, 684);
+            this.pa_checkno.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_checkno.Name = "pa_checkno";
-            this.pa_checkno.Size = new System.Drawing.Size(0, 21);
+            this.pa_checkno.Size = new System.Drawing.Size(0, 31);
             this.pa_checkno.TabIndex = 177;
             this.pa_checkno.Visible = false;
             // 
@@ -199,9 +207,10 @@
             // 
             this.pa_downstatus.AutoSize = true;
             this.pa_downstatus.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_downstatus.Location = new System.Drawing.Point(837, 456);
+            this.pa_downstatus.Location = new System.Drawing.Point(1256, 684);
+            this.pa_downstatus.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_downstatus.Name = "pa_downstatus";
-            this.pa_downstatus.Size = new System.Drawing.Size(0, 21);
+            this.pa_downstatus.Size = new System.Drawing.Size(0, 31);
             this.pa_downstatus.TabIndex = 178;
             this.pa_downstatus.Visible = false;
             // 
@@ -209,9 +218,10 @@
             // 
             this.pa_standardqty.AutoSize = true;
             this.pa_standardqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_standardqty.Location = new System.Drawing.Point(849, 470);
+            this.pa_standardqty.Location = new System.Drawing.Point(1274, 705);
+            this.pa_standardqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_standardqty.Name = "pa_standardqty";
-            this.pa_standardqty.Size = new System.Drawing.Size(0, 21);
+            this.pa_standardqty.Size = new System.Drawing.Size(0, 31);
             this.pa_standardqty.TabIndex = 180;
             this.pa_standardqty.Visible = false;
             // 
@@ -219,9 +229,10 @@
             // 
             this.pr_sendchecktype.AutoSize = true;
             this.pr_sendchecktype.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_sendchecktype.Location = new System.Drawing.Point(709, 437);
+            this.pr_sendchecktype.Location = new System.Drawing.Point(1064, 656);
+            this.pr_sendchecktype.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pr_sendchecktype.Name = "pr_sendchecktype";
-            this.pr_sendchecktype.Size = new System.Drawing.Size(0, 21);
+            this.pr_sendchecktype.Size = new System.Drawing.Size(0, 31);
             this.pr_sendchecktype.TabIndex = 182;
             this.pr_sendchecktype.Visible = false;
             // 
@@ -229,9 +240,10 @@
             // 
             this.mcd_remainqty_label.AutoSize = true;
             this.mcd_remainqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.mcd_remainqty_label.Location = new System.Drawing.Point(435, 469);
+            this.mcd_remainqty_label.Location = new System.Drawing.Point(652, 704);
+            this.mcd_remainqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.mcd_remainqty_label.Name = "mcd_remainqty_label";
-            this.mcd_remainqty_label.Size = new System.Drawing.Size(74, 21);
+            this.mcd_remainqty_label.Size = new System.Drawing.Size(110, 31);
             this.mcd_remainqty_label.TabIndex = 196;
             this.mcd_remainqty_label.Text = "待采集数";
             // 
@@ -239,18 +251,20 @@
             // 
             this.mcd_remainqty.AutoSize = true;
             this.mcd_remainqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.mcd_remainqty.Location = new System.Drawing.Point(517, 469);
+            this.mcd_remainqty.Location = new System.Drawing.Point(776, 704);
+            this.mcd_remainqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.mcd_remainqty.Name = "mcd_remainqty";
-            this.mcd_remainqty.Size = new System.Drawing.Size(0, 21);
+            this.mcd_remainqty.Size = new System.Drawing.Size(0, 31);
             this.mcd_remainqty.TabIndex = 197;
             // 
             // mcd_inqty_label
             // 
             this.mcd_inqty_label.AutoSize = true;
             this.mcd_inqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.mcd_inqty_label.Location = new System.Drawing.Point(435, 437);
+            this.mcd_inqty_label.Location = new System.Drawing.Point(652, 656);
+            this.mcd_inqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.mcd_inqty_label.Name = "mcd_inqty_label";
-            this.mcd_inqty_label.Size = new System.Drawing.Size(74, 21);
+            this.mcd_inqty_label.Size = new System.Drawing.Size(110, 31);
             this.mcd_inqty_label.TabIndex = 194;
             this.mcd_inqty_label.Text = "已采集数";
             // 
@@ -258,27 +272,30 @@
             // 
             this.mcd_inqty.AutoSize = true;
             this.mcd_inqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.mcd_inqty.Location = new System.Drawing.Point(517, 437);
+            this.mcd_inqty.Location = new System.Drawing.Point(776, 656);
+            this.mcd_inqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.mcd_inqty.Name = "mcd_inqty";
-            this.mcd_inqty.Size = new System.Drawing.Size(0, 21);
+            this.mcd_inqty.Size = new System.Drawing.Size(0, 31);
             this.mcd_inqty.TabIndex = 195;
             // 
             // pa_remark_label
             // 
             this.pa_remark_label.AutoSize = true;
             this.pa_remark_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_remark_label.Location = new System.Drawing.Point(437, 501);
+            this.pa_remark_label.Location = new System.Drawing.Point(656, 752);
+            this.pa_remark_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_remark_label.Name = "pa_remark_label";
-            this.pa_remark_label.Size = new System.Drawing.Size(42, 21);
+            this.pa_remark_label.Size = new System.Drawing.Size(62, 31);
             this.pa_remark_label.TabIndex = 198;
             this.pa_remark_label.Text = "备注";
             // 
             // CollecRemark
             // 
             this.CollecRemark.AutoSize = true;
-            this.CollecRemark.Location = new System.Drawing.Point(524, 557);
+            this.CollecRemark.Location = new System.Drawing.Point(786, 836);
+            this.CollecRemark.Margin = new System.Windows.Forms.Padding(4);
             this.CollecRemark.Name = "CollecRemark";
-            this.CollecRemark.Size = new System.Drawing.Size(96, 16);
+            this.CollecRemark.Size = new System.Drawing.Size(142, 22);
             this.CollecRemark.TabIndex = 201;
             this.CollecRemark.Text = "采集备注信息";
             this.CollecRemark.UseVisualStyleBackColor = true;
@@ -287,9 +304,10 @@
             // 
             this.Port_label.AutoSize = true;
             this.Port_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.Port_label.Location = new System.Drawing.Point(692, 464);
+            this.Port_label.Location = new System.Drawing.Point(1038, 696);
+            this.Port_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.Port_label.Name = "Port_label";
-            this.Port_label.Size = new System.Drawing.Size(42, 21);
+            this.Port_label.Size = new System.Drawing.Size(62, 31);
             this.Port_label.TabIndex = 204;
             this.Port_label.Text = "端口";
             // 
@@ -297,18 +315,20 @@
             // 
             this.IP_label.AutoSize = true;
             this.IP_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.IP_label.Location = new System.Drawing.Point(692, 431);
+            this.IP_label.Location = new System.Drawing.Point(1038, 646);
+            this.IP_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.IP_label.Name = "IP_label";
-            this.IP_label.Size = new System.Drawing.Size(25, 21);
+            this.IP_label.Size = new System.Drawing.Size(36, 31);
             this.IP_label.TabIndex = 202;
             this.IP_label.Text = "IP";
             // 
             // AllowRepeat
             // 
             this.AllowRepeat.AutoSize = true;
-            this.AllowRepeat.Location = new System.Drawing.Point(629, 556);
+            this.AllowRepeat.Location = new System.Drawing.Point(944, 834);
+            this.AllowRepeat.Margin = new System.Windows.Forms.Padding(4);
             this.AllowRepeat.Name = "AllowRepeat";
-            this.AllowRepeat.Size = new System.Drawing.Size(96, 16);
+            this.AllowRepeat.Size = new System.Drawing.Size(142, 22);
             this.AllowRepeat.TabIndex = 208;
             this.AllowRepeat.Text = "允许重复备注";
             this.AllowRepeat.UseVisualStyleBackColor = true;
@@ -317,9 +337,10 @@
             // 
             this.label2.AutoSize = true;
             this.label2.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label2.Location = new System.Drawing.Point(437, 528);
+            this.label2.Location = new System.Drawing.Point(656, 792);
+            this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label2.Name = "label2";
-            this.label2.Size = new System.Drawing.Size(37, 20);
+            this.label2.Size = new System.Drawing.Size(54, 28);
             this.label2.TabIndex = 210;
             this.label2.Text = "前缀";
             // 
@@ -329,11 +350,11 @@
             this.Remark_PreFix.BackColor = System.Drawing.Color.White;
             this.Remark_PreFix.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.Remark_PreFix.ID = null;
-            this.Remark_PreFix.Location = new System.Drawing.Point(479, 526);
-            this.Remark_PreFix.Margin = new System.Windows.Forms.Padding(6, 7, 6, 7);
+            this.Remark_PreFix.Location = new System.Drawing.Point(718, 789);
+            this.Remark_PreFix.Margin = new System.Windows.Forms.Padding(9, 10, 9, 10);
             this.Remark_PreFix.Name = "Remark_PreFix";
             this.Remark_PreFix.Power = null;
-            this.Remark_PreFix.Size = new System.Drawing.Size(38, 23);
+            this.Remark_PreFix.Size = new System.Drawing.Size(55, 31);
             this.Remark_PreFix.Str = null;
             this.Remark_PreFix.Str1 = null;
             this.Remark_PreFix.Str2 = null;
@@ -347,12 +368,13 @@
             this.CloseServer.DownImage = ((System.Drawing.Image)(resources.GetObject("CloseServer.DownImage")));
             this.CloseServer.Image = null;
             this.CloseServer.IsShowBorder = true;
-            this.CloseServer.Location = new System.Drawing.Point(781, 502);
+            this.CloseServer.Location = new System.Drawing.Point(1172, 753);
+            this.CloseServer.Margin = new System.Windows.Forms.Padding(4);
             this.CloseServer.MoveImage = ((System.Drawing.Image)(resources.GetObject("CloseServer.MoveImage")));
             this.CloseServer.Name = "CloseServer";
             this.CloseServer.NormalImage = ((System.Drawing.Image)(resources.GetObject("CloseServer.NormalImage")));
             this.CloseServer.Power = null;
-            this.CloseServer.Size = new System.Drawing.Size(60, 24);
+            this.CloseServer.Size = new System.Drawing.Size(90, 36);
             this.CloseServer.TabIndex = 207;
             this.CloseServer.Text = "关闭服务";
             this.CloseServer.UseVisualStyleBackColor = true;
@@ -365,12 +387,13 @@
             this.BuildServer.DownImage = ((System.Drawing.Image)(resources.GetObject("BuildServer.DownImage")));
             this.BuildServer.Image = null;
             this.BuildServer.IsShowBorder = true;
-            this.BuildServer.Location = new System.Drawing.Point(700, 502);
+            this.BuildServer.Location = new System.Drawing.Point(1050, 753);
+            this.BuildServer.Margin = new System.Windows.Forms.Padding(4);
             this.BuildServer.MoveImage = ((System.Drawing.Image)(resources.GetObject("BuildServer.MoveImage")));
             this.BuildServer.Name = "BuildServer";
             this.BuildServer.NormalImage = ((System.Drawing.Image)(resources.GetObject("BuildServer.NormalImage")));
             this.BuildServer.Power = null;
-            this.BuildServer.Size = new System.Drawing.Size(60, 24);
+            this.BuildServer.Size = new System.Drawing.Size(90, 36);
             this.BuildServer.TabIndex = 206;
             this.BuildServer.Text = "开启服务";
             this.BuildServer.UseVisualStyleBackColor = true;
@@ -382,10 +405,11 @@
             this.Port.BackColor = System.Drawing.Color.White;
             this.Port.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.Port.ID = null;
-            this.Port.Location = new System.Drawing.Point(752, 466);
+            this.Port.Location = new System.Drawing.Point(1128, 699);
+            this.Port.Margin = new System.Windows.Forms.Padding(4);
             this.Port.Name = "Port";
             this.Port.Power = null;
-            this.Port.Size = new System.Drawing.Size(114, 23);
+            this.Port.Size = new System.Drawing.Size(169, 31);
             this.Port.Str = null;
             this.Port.Str1 = null;
             this.Port.Str2 = null;
@@ -397,11 +421,11 @@
             this.IP.BackColor = System.Drawing.Color.White;
             this.IP.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.IP.ID = null;
-            this.IP.Location = new System.Drawing.Point(752, 431);
-            this.IP.Margin = new System.Windows.Forms.Padding(6, 7, 6, 7);
+            this.IP.Location = new System.Drawing.Point(1128, 646);
+            this.IP.Margin = new System.Windows.Forms.Padding(9, 10, 9, 10);
             this.IP.Name = "IP";
             this.IP.Power = null;
-            this.IP.Size = new System.Drawing.Size(114, 23);
+            this.IP.Size = new System.Drawing.Size(169, 31);
             this.IP.Str = null;
             this.IP.Str1 = null;
             this.IP.Str2 = null;
@@ -412,12 +436,11 @@
             this.pa_remark.AllPower = null;
             this.pa_remark.BackColor = System.Drawing.Color.White;
             this.pa_remark.ID = null;
-            this.pa_remark.Location = new System.Drawing.Point(524, 502);
-            this.pa_remark.Margin = new System.Windows.Forms.Padding(2);
+            this.pa_remark.Location = new System.Drawing.Point(786, 753);
             this.pa_remark.Multiline = true;
             this.pa_remark.Name = "pa_remark";
             this.pa_remark.Power = null;
-            this.pa_remark.Size = new System.Drawing.Size(148, 46);
+            this.pa_remark.Size = new System.Drawing.Size(220, 67);
             this.pa_remark.Str = null;
             this.pa_remark.Str1 = null;
             this.pa_remark.Str2 = null;
@@ -446,11 +469,9 @@
             this.groupBoxWithBorder2.Controls.Add(this.PrintList_label);
             this.groupBoxWithBorder2.Controls.Add(this.PrintNum_label);
             this.groupBoxWithBorder2.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.groupBoxWithBorder2.Location = new System.Drawing.Point(424, 6);
-            this.groupBoxWithBorder2.Margin = new System.Windows.Forms.Padding(2);
+            this.groupBoxWithBorder2.Location = new System.Drawing.Point(636, 9);
             this.groupBoxWithBorder2.Name = "groupBoxWithBorder2";
-            this.groupBoxWithBorder2.Padding = new System.Windows.Forms.Padding(2);
-            this.groupBoxWithBorder2.Size = new System.Drawing.Size(446, 168);
+            this.groupBoxWithBorder2.Size = new System.Drawing.Size(669, 252);
             this.groupBoxWithBorder2.TabIndex = 172;
             this.groupBoxWithBorder2.TabStop = false;
             this.groupBoxWithBorder2.Text = "打印";
@@ -463,10 +484,11 @@
             this.PrintNum.Enabled = false;
             this.PrintNum.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.PrintNum.ID = null;
-            this.PrintNum.Location = new System.Drawing.Point(255, 130);
+            this.PrintNum.Location = new System.Drawing.Point(382, 195);
+            this.PrintNum.Margin = new System.Windows.Forms.Padding(4);
             this.PrintNum.Name = "PrintNum";
             this.PrintNum.Power = null;
-            this.PrintNum.Size = new System.Drawing.Size(31, 23);
+            this.PrintNum.Size = new System.Drawing.Size(44, 31);
             this.PrintNum.Str = null;
             this.PrintNum.Str1 = null;
             this.PrintNum.Str2 = null;
@@ -476,19 +498,20 @@
             // 
             this.label1.AutoSize = true;
             this.label1.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label1.Location = new System.Drawing.Point(264, 14);
+            this.label1.Location = new System.Drawing.Point(396, 21);
+            this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(74, 21);
+            this.label1.Size = new System.Drawing.Size(110, 31);
             this.label1.TabIndex = 181;
             this.label1.Text = "当前批号";
             // 
             // StepCount
             // 
             this.StepCount.LineCode = null;
-            this.StepCount.Location = new System.Drawing.Point(122, 18);
-            this.StepCount.Margin = new System.Windows.Forms.Padding(3, 7, 3, 7);
+            this.StepCount.Location = new System.Drawing.Point(183, 27);
+            this.StepCount.Margin = new System.Windows.Forms.Padding(4, 10, 4, 10);
             this.StepCount.Name = "StepCount";
-            this.StepCount.Size = new System.Drawing.Size(63, 23);
+            this.StepCount.Size = new System.Drawing.Size(94, 34);
             this.StepCount.Source = null;
             this.StepCount.StepCode = null;
             this.StepCount.TabIndex = 193;
@@ -498,37 +521,41 @@
             this.checkweightlabel.AutoSize = true;
             this.checkweightlabel.CutLength = null;
             this.checkweightlabel.ForeColor = System.Drawing.Color.Red;
-            this.checkweightlabel.Location = new System.Drawing.Point(26, 22);
-            this.checkweightlabel.MaximumSize = new System.Drawing.Size(200, 0);
+            this.checkweightlabel.Location = new System.Drawing.Point(39, 33);
+            this.checkweightlabel.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.checkweightlabel.MaximumSize = new System.Drawing.Size(300, 0);
             this.checkweightlabel.Name = "checkweightlabel";
-            this.checkweightlabel.Size = new System.Drawing.Size(0, 21);
+            this.checkweightlabel.Size = new System.Drawing.Size(0, 31);
             this.checkweightlabel.TabIndex = 180;
             // 
             // ob_nowcheckqty
             // 
             this.ob_nowcheckqty.AutoSize = true;
             this.ob_nowcheckqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_nowcheckqty.Location = new System.Drawing.Point(344, 86);
+            this.ob_nowcheckqty.Location = new System.Drawing.Point(516, 129);
+            this.ob_nowcheckqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ob_nowcheckqty.Name = "ob_nowcheckqty";
-            this.ob_nowcheckqty.Size = new System.Drawing.Size(0, 21);
+            this.ob_nowcheckqty.Size = new System.Drawing.Size(0, 31);
             this.ob_nowcheckqty.TabIndex = 178;
             // 
             // ob_batchqty
             // 
             this.ob_batchqty.AutoSize = true;
             this.ob_batchqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_batchqty.Location = new System.Drawing.Point(344, 48);
+            this.ob_batchqty.Location = new System.Drawing.Point(516, 72);
+            this.ob_batchqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ob_batchqty.Name = "ob_batchqty";
-            this.ob_batchqty.Size = new System.Drawing.Size(0, 21);
+            this.ob_batchqty.Size = new System.Drawing.Size(0, 31);
             this.ob_batchqty.TabIndex = 177;
             // 
             // ob_nowcheckqty_label
             // 
             this.ob_nowcheckqty_label.AutoSize = true;
             this.ob_nowcheckqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_nowcheckqty_label.Location = new System.Drawing.Point(264, 86);
+            this.ob_nowcheckqty_label.Location = new System.Drawing.Point(396, 129);
+            this.ob_nowcheckqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ob_nowcheckqty_label.Name = "ob_nowcheckqty_label";
-            this.ob_nowcheckqty_label.Size = new System.Drawing.Size(74, 21);
+            this.ob_nowcheckqty_label.Size = new System.Drawing.Size(110, 31);
             this.ob_nowcheckqty_label.TabIndex = 176;
             this.ob_nowcheckqty_label.Text = "当前批数";
             // 
@@ -536,9 +563,10 @@
             // 
             this.ob_batchqty_label.AutoSize = true;
             this.ob_batchqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_batchqty_label.Location = new System.Drawing.Point(264, 50);
+            this.ob_batchqty_label.Location = new System.Drawing.Point(396, 75);
+            this.ob_batchqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ob_batchqty_label.Name = "ob_batchqty_label";
-            this.ob_batchqty_label.Size = new System.Drawing.Size(74, 21);
+            this.ob_batchqty_label.Size = new System.Drawing.Size(110, 31);
             this.ob_batchqty_label.TabIndex = 175;
             this.ob_batchqty_label.Text = "标准批数";
             // 
@@ -546,9 +574,10 @@
             // 
             this.ob_checkno.AutoSize = true;
             this.ob_checkno.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ob_checkno.Location = new System.Drawing.Point(344, 14);
+            this.ob_checkno.Location = new System.Drawing.Point(516, 21);
+            this.ob_checkno.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ob_checkno.Name = "ob_checkno";
-            this.ob_checkno.Size = new System.Drawing.Size(0, 21);
+            this.ob_checkno.Size = new System.Drawing.Size(0, 31);
             this.ob_checkno.TabIndex = 175;
             this.ob_checkno.TextChanged += new System.EventHandler(this.ob_checkno_TextChanged);
             // 
@@ -561,12 +590,13 @@
             this.SendCheck.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.SendCheck.Image = null;
             this.SendCheck.IsShowBorder = true;
-            this.SendCheck.Location = new System.Drawing.Point(370, 130);
+            this.SendCheck.Location = new System.Drawing.Point(555, 195);
+            this.SendCheck.Margin = new System.Windows.Forms.Padding(4);
             this.SendCheck.MoveImage = ((System.Drawing.Image)(resources.GetObject("SendCheck.MoveImage")));
             this.SendCheck.Name = "SendCheck";
             this.SendCheck.NormalImage = ((System.Drawing.Image)(resources.GetObject("SendCheck.NormalImage")));
             this.SendCheck.Power = null;
-            this.SendCheck.Size = new System.Drawing.Size(45, 24);
+            this.SendCheck.Size = new System.Drawing.Size(68, 36);
             this.SendCheck.TabIndex = 174;
             this.SendCheck.Tag = "ifread";
             this.SendCheck.Text = "送检";
@@ -581,12 +611,13 @@
             this.Packing.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.Packing.Image = null;
             this.Packing.IsShowBorder = true;
-            this.Packing.Location = new System.Drawing.Point(15, 130);
+            this.Packing.Location = new System.Drawing.Point(22, 195);
+            this.Packing.Margin = new System.Windows.Forms.Padding(4);
             this.Packing.MoveImage = ((System.Drawing.Image)(resources.GetObject("Packing.MoveImage")));
             this.Packing.Name = "Packing";
             this.Packing.NormalImage = ((System.Drawing.Image)(resources.GetObject("Packing.NormalImage")));
             this.Packing.Power = null;
-            this.Packing.Size = new System.Drawing.Size(50, 24);
+            this.Packing.Size = new System.Drawing.Size(75, 36);
             this.Packing.TabIndex = 173;
             this.Packing.Text = "封箱";
             this.Packing.UseVisualStyleBackColor = true;
@@ -597,10 +628,9 @@
             this.PrintLabel.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
             this.PrintLabel.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.PrintLabel.FormattingEnabled = true;
-            this.PrintLabel.Location = new System.Drawing.Point(122, 87);
-            this.PrintLabel.Margin = new System.Windows.Forms.Padding(2);
+            this.PrintLabel.Location = new System.Drawing.Point(183, 130);
             this.PrintLabel.Name = "PrintLabel";
-            this.PrintLabel.Size = new System.Drawing.Size(136, 25);
+            this.PrintLabel.Size = new System.Drawing.Size(202, 32);
             this.PrintLabel.TabIndex = 159;
             this.PrintLabel.SelectedValueChanged += new System.EventHandler(this.PrintLabel_SelectedValueChanged);
             // 
@@ -608,28 +638,29 @@
             // 
             this.label3.AutoSize = true;
             this.label3.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label3.Location = new System.Drawing.Point(6, 88);
+            this.label3.Location = new System.Drawing.Point(9, 132);
+            this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label3.Name = "label3";
-            this.label3.Size = new System.Drawing.Size(74, 21);
+            this.label3.Size = new System.Drawing.Size(110, 31);
             this.label3.TabIndex = 160;
             this.label3.Text = "打印标签";
             // 
             // AutoPrint
             // 
             this.AutoPrint.Checked = false;
-            this.AutoPrint.Location = new System.Drawing.Point(83, 131);
-            this.AutoPrint.Margin = new System.Windows.Forms.Padding(3, 4, 3, 4);
+            this.AutoPrint.Location = new System.Drawing.Point(124, 196);
+            this.AutoPrint.Margin = new System.Windows.Forms.Padding(4, 6, 4, 6);
             this.AutoPrint.Name = "AutoPrint";
-            this.AutoPrint.Size = new System.Drawing.Size(90, 23);
+            this.AutoPrint.Size = new System.Drawing.Size(135, 34);
             this.AutoPrint.TabIndex = 166;
             // 
             // PrintList
             // 
             this.PrintList.Font = new System.Drawing.Font("微软雅黑", 9F);
-            this.PrintList.Location = new System.Drawing.Point(122, 50);
-            this.PrintList.Margin = new System.Windows.Forms.Padding(6, 7, 6, 7);
+            this.PrintList.Location = new System.Drawing.Point(183, 75);
+            this.PrintList.Margin = new System.Windows.Forms.Padding(9, 10, 9, 10);
             this.PrintList.Name = "PrintList";
-            this.PrintList.Size = new System.Drawing.Size(136, 28);
+            this.PrintList.Size = new System.Drawing.Size(204, 42);
             this.PrintList.TabIndex = 158;
             // 
             // Printing
@@ -640,12 +671,13 @@
             this.Printing.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.Printing.Image = null;
             this.Printing.IsShowBorder = true;
-            this.Printing.Location = new System.Drawing.Point(311, 130);
+            this.Printing.Location = new System.Drawing.Point(466, 195);
+            this.Printing.Margin = new System.Windows.Forms.Padding(4);
             this.Printing.MoveImage = ((System.Drawing.Image)(resources.GetObject("Printing.MoveImage")));
             this.Printing.Name = "Printing";
             this.Printing.NormalImage = ((System.Drawing.Image)(resources.GetObject("Printing.NormalImage")));
             this.Printing.Power = null;
-            this.Printing.Size = new System.Drawing.Size(45, 24);
+            this.Printing.Size = new System.Drawing.Size(68, 36);
             this.Printing.TabIndex = 150;
             this.Printing.Tag = "ifread";
             this.Printing.Text = "打印";
@@ -656,9 +688,10 @@
             // 
             this.PrintList_label.AutoSize = true;
             this.PrintList_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.PrintList_label.Location = new System.Drawing.Point(6, 48);
+            this.PrintList_label.Location = new System.Drawing.Point(9, 72);
+            this.PrintList_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.PrintList_label.Name = "PrintList_label";
-            this.PrintList_label.Size = new System.Drawing.Size(90, 21);
+            this.PrintList_label.Size = new System.Drawing.Size(134, 31);
             this.PrintList_label.TabIndex = 116;
             this.PrintList_label.Text = "打印机列表";
             // 
@@ -666,9 +699,10 @@
             // 
             this.PrintNum_label.AutoSize = true;
             this.PrintNum_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.PrintNum_label.Location = new System.Drawing.Point(206, 128);
+            this.PrintNum_label.Location = new System.Drawing.Point(309, 192);
+            this.PrintNum_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.PrintNum_label.Name = "PrintNum_label";
-            this.PrintNum_label.Size = new System.Drawing.Size(42, 21);
+            this.PrintNum_label.Size = new System.Drawing.Size(62, 31);
             this.PrintNum_label.TabIndex = 124;
             this.PrintNum_label.Text = "份数";
             // 
@@ -697,11 +731,9 @@
             this.groupBoxWithBorder1.Controls.Add(this.pr_code);
             this.groupBoxWithBorder1.Controls.Add(this.pa_code_label);
             this.groupBoxWithBorder1.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.groupBoxWithBorder1.Location = new System.Drawing.Point(4, 6);
-            this.groupBoxWithBorder1.Margin = new System.Windows.Forms.Padding(2);
+            this.groupBoxWithBorder1.Location = new System.Drawing.Point(6, 9);
             this.groupBoxWithBorder1.Name = "groupBoxWithBorder1";
-            this.groupBoxWithBorder1.Padding = new System.Windows.Forms.Padding(2);
-            this.groupBoxWithBorder1.Size = new System.Drawing.Size(411, 168);
+            this.groupBoxWithBorder1.Size = new System.Drawing.Size(616, 252);
             this.groupBoxWithBorder1.TabIndex = 171;
             this.groupBoxWithBorder1.TabStop = false;
             this.groupBoxWithBorder1.Text = "装箱信息";
@@ -712,9 +744,10 @@
             this.locksalecode.AutoSize = true;
             this.locksalecode.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.locksalecode.ForeColor = System.Drawing.Color.Red;
-            this.locksalecode.Location = new System.Drawing.Point(290, 16);
+            this.locksalecode.Location = new System.Drawing.Point(435, 24);
+            this.locksalecode.Margin = new System.Windows.Forms.Padding(4);
             this.locksalecode.Name = "locksalecode";
-            this.locksalecode.Size = new System.Drawing.Size(96, 16);
+            this.locksalecode.Size = new System.Drawing.Size(142, 22);
             this.locksalecode.TabIndex = 196;
             this.locksalecode.Text = "当前订单锁定";
             this.locksalecode.UseVisualStyleBackColor = true;
@@ -723,9 +756,10 @@
             // 
             this.PreFix_label.AutoSize = true;
             this.PreFix_label.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.PreFix_label.Location = new System.Drawing.Point(178, 14);
+            this.PreFix_label.Location = new System.Drawing.Point(267, 21);
+            this.PreFix_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.PreFix_label.Name = "PreFix_label";
-            this.PreFix_label.Size = new System.Drawing.Size(37, 20);
+            this.PreFix_label.Size = new System.Drawing.Size(54, 28);
             this.PreFix_label.TabIndex = 195;
             this.PreFix_label.Text = "前缀";
             // 
@@ -735,11 +769,11 @@
             this.PreFix.BackColor = System.Drawing.Color.White;
             this.PreFix.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.PreFix.ID = null;
-            this.PreFix.Location = new System.Drawing.Point(225, 15);
-            this.PreFix.Margin = new System.Windows.Forms.Padding(6, 7, 6, 7);
+            this.PreFix.Location = new System.Drawing.Point(338, 22);
+            this.PreFix.Margin = new System.Windows.Forms.Padding(9, 10, 9, 10);
             this.PreFix.Name = "PreFix";
             this.PreFix.Power = null;
-            this.PreFix.Size = new System.Drawing.Size(38, 23);
+            this.PreFix.Size = new System.Drawing.Size(55, 31);
             this.PreFix.Str = null;
             this.PreFix.Str1 = null;
             this.PreFix.Str2 = null;
@@ -750,9 +784,10 @@
             // 
             this.pa_salecode_label.AutoSize = true;
             this.pa_salecode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_salecode_label.Location = new System.Drawing.Point(208, 136);
+            this.pa_salecode_label.Location = new System.Drawing.Point(312, 204);
+            this.pa_salecode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_salecode_label.Name = "pa_salecode_label";
-            this.pa_salecode_label.Size = new System.Drawing.Size(74, 21);
+            this.pa_salecode_label.Size = new System.Drawing.Size(110, 31);
             this.pa_salecode_label.TabIndex = 185;
             this.pa_salecode_label.Text = "订单编号";
             // 
@@ -760,9 +795,10 @@
             // 
             this.ma_code_label.AutoSize = true;
             this.ma_code_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ma_code_label.Location = new System.Drawing.Point(4, 136);
+            this.ma_code_label.Location = new System.Drawing.Point(6, 204);
+            this.ma_code_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ma_code_label.Name = "ma_code_label";
-            this.ma_code_label.Size = new System.Drawing.Size(58, 21);
+            this.ma_code_label.Size = new System.Drawing.Size(86, 31);
             this.ma_code_label.TabIndex = 186;
             this.ma_code_label.Text = "工单号";
             // 
@@ -770,28 +806,31 @@
             // 
             this.ms_salecode.AutoSize = true;
             this.ms_salecode.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ms_salecode.Location = new System.Drawing.Point(290, 136);
+            this.ms_salecode.Location = new System.Drawing.Point(435, 204);
+            this.ms_salecode.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ms_salecode.Name = "ms_salecode";
-            this.ms_salecode.Size = new System.Drawing.Size(0, 21);
+            this.ms_salecode.Size = new System.Drawing.Size(0, 31);
             this.ms_salecode.TabIndex = 188;
             // 
             // ms_makecode
             // 
             this.ms_makecode.AutoSize = true;
             this.ms_makecode.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ms_makecode.Location = new System.Drawing.Point(90, 136);
-            this.ms_makecode.MaximumSize = new System.Drawing.Size(150, 0);
+            this.ms_makecode.Location = new System.Drawing.Point(135, 204);
+            this.ms_makecode.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ms_makecode.MaximumSize = new System.Drawing.Size(225, 0);
             this.ms_makecode.Name = "ms_makecode";
-            this.ms_makecode.Size = new System.Drawing.Size(0, 21);
+            this.ms_makecode.Size = new System.Drawing.Size(0, 31);
             this.ms_makecode.TabIndex = 187;
             // 
             // OutBoxLength_label
             // 
             this.OutBoxLength_label.AutoSize = true;
             this.OutBoxLength_label.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.OutBoxLength_label.Location = new System.Drawing.Point(80, 14);
+            this.OutBoxLength_label.Location = new System.Drawing.Point(120, 21);
+            this.OutBoxLength_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.OutBoxLength_label.Name = "OutBoxLength_label";
-            this.OutBoxLength_label.Size = new System.Drawing.Size(37, 20);
+            this.OutBoxLength_label.Size = new System.Drawing.Size(54, 28);
             this.OutBoxLength_label.TabIndex = 184;
             this.OutBoxLength_label.Text = "长度";
             // 
@@ -801,11 +840,11 @@
             this.OutBoxLength.BackColor = System.Drawing.Color.White;
             this.OutBoxLength.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.OutBoxLength.ID = null;
-            this.OutBoxLength.Location = new System.Drawing.Point(127, 15);
-            this.OutBoxLength.Margin = new System.Windows.Forms.Padding(6, 7, 6, 7);
+            this.OutBoxLength.Location = new System.Drawing.Point(190, 22);
+            this.OutBoxLength.Margin = new System.Windows.Forms.Padding(9, 10, 9, 10);
             this.OutBoxLength.Name = "OutBoxLength";
             this.OutBoxLength.Power = null;
-            this.OutBoxLength.Size = new System.Drawing.Size(38, 23);
+            this.OutBoxLength.Size = new System.Drawing.Size(55, 31);
             this.OutBoxLength.Str = null;
             this.OutBoxLength.Str1 = null;
             this.OutBoxLength.Str2 = null;
@@ -819,10 +858,11 @@
             this.pr_outboxinnerqty.Enabled = false;
             this.pr_outboxinnerqty.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.pr_outboxinnerqty.ID = null;
-            this.pr_outboxinnerqty.Location = new System.Drawing.Point(90, 74);
+            this.pr_outboxinnerqty.Location = new System.Drawing.Point(135, 111);
+            this.pr_outboxinnerqty.Margin = new System.Windows.Forms.Padding(4);
             this.pr_outboxinnerqty.Name = "pr_outboxinnerqty";
             this.pr_outboxinnerqty.Power = null;
-            this.pr_outboxinnerqty.Size = new System.Drawing.Size(104, 23);
+            this.pr_outboxinnerqty.Size = new System.Drawing.Size(154, 31);
             this.pr_outboxinnerqty.Str = null;
             this.pr_outboxinnerqty.Str1 = null;
             this.pr_outboxinnerqty.Str2 = null;
@@ -836,12 +876,13 @@
             this.DeleteAll.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.DeleteAll.Image = null;
             this.DeleteAll.IsShowBorder = true;
-            this.DeleteAll.Location = new System.Drawing.Point(355, 42);
+            this.DeleteAll.Location = new System.Drawing.Point(532, 63);
+            this.DeleteAll.Margin = new System.Windows.Forms.Padding(4);
             this.DeleteAll.MoveImage = ((System.Drawing.Image)(resources.GetObject("DeleteAll.MoveImage")));
             this.DeleteAll.Name = "DeleteAll";
             this.DeleteAll.NormalImage = ((System.Drawing.Image)(resources.GetObject("DeleteAll.NormalImage")));
             this.DeleteAll.Power = "ifspecial";
-            this.DeleteAll.Size = new System.Drawing.Size(45, 24);
+            this.DeleteAll.Size = new System.Drawing.Size(68, 36);
             this.DeleteAll.TabIndex = 181;
             this.DeleteAll.Text = "拆箱";
             this.DeleteAll.UseVisualStyleBackColor = true;
@@ -852,10 +893,9 @@
             this.AutoGenBoxCode.AutoSize = true;
             this.AutoGenBoxCode.Checked = true;
             this.AutoGenBoxCode.CheckState = System.Windows.Forms.CheckState.Checked;
-            this.AutoGenBoxCode.Location = new System.Drawing.Point(246, 44);
-            this.AutoGenBoxCode.Margin = new System.Windows.Forms.Padding(2);
+            this.AutoGenBoxCode.Location = new System.Drawing.Point(369, 66);
             this.AutoGenBoxCode.Name = "AutoGenBoxCode";
-            this.AutoGenBoxCode.Size = new System.Drawing.Size(93, 25);
+            this.AutoGenBoxCode.Size = new System.Drawing.Size(136, 35);
             this.AutoGenBoxCode.TabIndex = 171;
             this.AutoGenBoxCode.Text = "自动生成";
             this.AutoGenBoxCode.UseVisualStyleBackColor = true;
@@ -865,9 +905,10 @@
             // 
             this.pa_currentqty_label.AutoSize = true;
             this.pa_currentqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_currentqty_label.Location = new System.Drawing.Point(210, 76);
+            this.pa_currentqty_label.Location = new System.Drawing.Point(315, 114);
+            this.pa_currentqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_currentqty_label.Name = "pa_currentqty_label";
-            this.pa_currentqty_label.Size = new System.Drawing.Size(74, 21);
+            this.pa_currentqty_label.Size = new System.Drawing.Size(110, 31);
             this.pa_currentqty_label.TabIndex = 95;
             this.pa_currentqty_label.Text = "已装数量";
             // 
@@ -875,11 +916,12 @@
             // 
             this.pr_detail_label.AutoSize = true;
             this.pr_detail_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_detail_label.Location = new System.Drawing.Point(208, 104);
+            this.pr_detail_label.Location = new System.Drawing.Point(312, 156);
+            this.pr_detail_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pr_detail_label.Name = "pr_detail_label";
-            this.pr_detail_label.Size = new System.Drawing.Size(74, 21);
+            this.pr_detail_label.Size = new System.Drawing.Size(62, 31);
             this.pr_detail_label.TabIndex = 80;
-            this.pr_detail_label.Text = "产品名称";
+            this.pr_detail_label.Text = "型号";
             // 
             // pa_outboxcode
             // 
@@ -888,11 +930,11 @@
             this.pa_outboxcode.Font = new System.Drawing.Font("微软雅黑", 12F);
             this.pa_outboxcode.ForeColor = System.Drawing.Color.Black;
             this.pa_outboxcode.ID = null;
-            this.pa_outboxcode.Location = new System.Drawing.Point(90, 42);
-            this.pa_outboxcode.Margin = new System.Windows.Forms.Padding(6, 7, 6, 7);
+            this.pa_outboxcode.Location = new System.Drawing.Point(135, 63);
+            this.pa_outboxcode.Margin = new System.Windows.Forms.Padding(9, 10, 9, 10);
             this.pa_outboxcode.Name = "pa_outboxcode";
             this.pa_outboxcode.Power = null;
-            this.pa_outboxcode.Size = new System.Drawing.Size(145, 29);
+            this.pa_outboxcode.Size = new System.Drawing.Size(216, 39);
             this.pa_outboxcode.Str = null;
             this.pa_outboxcode.Str1 = null;
             this.pa_outboxcode.Str2 = null;
@@ -903,18 +945,20 @@
             // 
             this.pa_currentqty.AutoSize = true;
             this.pa_currentqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_currentqty.Location = new System.Drawing.Point(288, 74);
+            this.pa_currentqty.Location = new System.Drawing.Point(432, 111);
+            this.pa_currentqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_currentqty.Name = "pa_currentqty";
-            this.pa_currentqty.Size = new System.Drawing.Size(0, 21);
+            this.pa_currentqty.Size = new System.Drawing.Size(0, 31);
             this.pa_currentqty.TabIndex = 169;
             // 
             // pr_code_label
             // 
             this.pr_code_label.AutoSize = true;
             this.pr_code_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_code_label.Location = new System.Drawing.Point(4, 104);
+            this.pr_code_label.Location = new System.Drawing.Point(6, 156);
+            this.pr_code_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pr_code_label.Name = "pr_code_label";
-            this.pr_code_label.Size = new System.Drawing.Size(74, 21);
+            this.pr_code_label.Size = new System.Drawing.Size(110, 31);
             this.pr_code_label.TabIndex = 81;
             this.pr_code_label.Text = "产品编号";
             // 
@@ -922,18 +966,20 @@
             // 
             this.pr_detail.AutoSize = true;
             this.pr_detail.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_detail.Location = new System.Drawing.Point(290, 104);
+            this.pr_detail.Location = new System.Drawing.Point(374, 156);
+            this.pr_detail.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pr_detail.Name = "pr_detail";
-            this.pr_detail.Size = new System.Drawing.Size(0, 21);
+            this.pr_detail.Size = new System.Drawing.Size(0, 31);
             this.pr_detail.TabIndex = 168;
             // 
             // pr_outboxinnerqty_label
             // 
             this.pr_outboxinnerqty_label.AutoSize = true;
             this.pr_outboxinnerqty_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_outboxinnerqty_label.Location = new System.Drawing.Point(4, 72);
+            this.pr_outboxinnerqty_label.Location = new System.Drawing.Point(6, 108);
+            this.pr_outboxinnerqty_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pr_outboxinnerqty_label.Name = "pr_outboxinnerqty_label";
-            this.pr_outboxinnerqty_label.Size = new System.Drawing.Size(74, 21);
+            this.pr_outboxinnerqty_label.Size = new System.Drawing.Size(110, 31);
             this.pr_outboxinnerqty_label.TabIndex = 97;
             this.pr_outboxinnerqty_label.Text = "箱内容量";
             // 
@@ -941,10 +987,11 @@
             // 
             this.pr_code.AutoSize = true;
             this.pr_code.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pr_code.Location = new System.Drawing.Point(90, 104);
-            this.pr_code.MaximumSize = new System.Drawing.Size(150, 0);
+            this.pr_code.Location = new System.Drawing.Point(135, 156);
+            this.pr_code.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pr_code.MaximumSize = new System.Drawing.Size(225, 0);
             this.pr_code.Name = "pr_code";
-            this.pr_code.Size = new System.Drawing.Size(0, 21);
+            this.pr_code.Size = new System.Drawing.Size(0, 31);
             this.pr_code.TabIndex = 167;
             this.pr_code.TextChanged += new System.EventHandler(this.pr_code_TextChanged);
             // 
@@ -952,18 +999,20 @@
             // 
             this.pa_code_label.AutoSize = true;
             this.pa_code_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.pa_code_label.Location = new System.Drawing.Point(4, 42);
+            this.pa_code_label.Location = new System.Drawing.Point(6, 63);
+            this.pa_code_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pa_code_label.Name = "pa_code_label";
-            this.pa_code_label.Size = new System.Drawing.Size(42, 21);
+            this.pa_code_label.Size = new System.Drawing.Size(62, 31);
             this.pa_code_label.TabIndex = 113;
             this.pa_code_label.Text = "箱号";
             // 
             // OperateResult
             // 
             this.OperateResult.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.OperateResult.Location = new System.Drawing.Point(4, 427);
+            this.OperateResult.Location = new System.Drawing.Point(6, 640);
+            this.OperateResult.Margin = new System.Windows.Forms.Padding(4);
             this.OperateResult.Name = "OperateResult";
-            this.OperateResult.Size = new System.Drawing.Size(427, 120);
+            this.OperateResult.Size = new System.Drawing.Size(638, 178);
             this.OperateResult.TabIndex = 155;
             this.OperateResult.Text = "";
             // 
@@ -974,12 +1023,13 @@
             this.Clean.DownImage = ((System.Drawing.Image)(resources.GetObject("Clean.DownImage")));
             this.Clean.Image = null;
             this.Clean.IsShowBorder = true;
-            this.Clean.Location = new System.Drawing.Point(371, 553);
+            this.Clean.Location = new System.Drawing.Point(556, 830);
+            this.Clean.Margin = new System.Windows.Forms.Padding(4);
             this.Clean.MoveImage = ((System.Drawing.Image)(resources.GetObject("Clean.MoveImage")));
             this.Clean.Name = "Clean";
             this.Clean.NormalImage = ((System.Drawing.Image)(resources.GetObject("Clean.NormalImage")));
             this.Clean.Power = null;
-            this.Clean.Size = new System.Drawing.Size(60, 24);
+            this.Clean.Size = new System.Drawing.Size(90, 36);
             this.Clean.TabIndex = 148;
             this.Clean.Text = "清除";
             this.Clean.UseVisualStyleBackColor = true;
@@ -990,10 +1040,11 @@
             this.sn_code.AllPower = "ifall";
             this.sn_code.BackColor = System.Drawing.Color.White;
             this.sn_code.ID = null;
-            this.sn_code.Location = new System.Drawing.Point(74, 554);
+            this.sn_code.Location = new System.Drawing.Point(111, 831);
+            this.sn_code.Margin = new System.Windows.Forms.Padding(4);
             this.sn_code.Name = "sn_code";
             this.sn_code.Power = "ifread";
-            this.sn_code.Size = new System.Drawing.Size(173, 21);
+            this.sn_code.Size = new System.Drawing.Size(258, 28);
             this.sn_code.Str = null;
             this.sn_code.Str1 = null;
             this.sn_code.Str2 = null;
@@ -1015,11 +1066,12 @@
             this.pa_indate,
             this.pd_id});
             this.PackageDetail.EnableContentClick = true;
-            this.PackageDetail.Location = new System.Drawing.Point(4, 179);
+            this.PackageDetail.Location = new System.Drawing.Point(6, 268);
+            this.PackageDetail.Margin = new System.Windows.Forms.Padding(4);
             this.PackageDetail.Name = "PackageDetail";
             this.PackageDetail.ReadOnly = true;
             this.PackageDetail.RowTemplate.Height = 23;
-            this.PackageDetail.Size = new System.Drawing.Size(862, 240);
+            this.PackageDetail.Size = new System.Drawing.Size(1293, 360);
             this.PackageDetail.TabIndex = 134;
             // 
             // pd_barcode
@@ -1079,10 +1131,10 @@
             // 
             // Packing_PackageCollection
             // 
-            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
+            this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
-            this.ClientSize = new System.Drawing.Size(879, 593);
+            this.ClientSize = new System.Drawing.Size(1318, 890);
             this.Controls.Add(this.label2);
             this.Controls.Add(this.Remark_PreFix);
             this.Controls.Add(this.AllowRepeat);
@@ -1117,6 +1169,7 @@
             this.Controls.Add(this.label13);
             this.Controls.Add(this.pa_makecode);
             this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
+            this.Margin = new System.Windows.Forms.Padding(4);
             this.Name = "Packing_PackageCollection";
             this.Tag = "Packing!PackageCollection";
             this.Text = "包装采集";

+ 3 - 1
UAS_MES_ZT/FunctionCode/Packing/Packing_PackageCollection.cs

@@ -112,7 +112,7 @@ namespace UAS_MES_NEW.Packing
         {
             //加载表单数据
             sql.Clear();
-            sql.Append("select pr_code,nvl(pr_sendchecktype,'LineCode')pr_sendchecktype,pa_remark,pa_outboxcode,pa_prodcode,pa_salecode,pa_makecode,pa_sccode,nvl(pa_downstatus,0) pa_downstatus,pa_checkno,pa_status,pr_packrule,nvl(PR_CHECKCARTONW,'0') PR_CHECKCARTONW,pr_detail,pa_packageqty,nvl(pa_standardqty,0) pa_standardqty,nvl(pr_outboxinnerqty,0)pr_outboxinnerqty,pa_currentqty from package left join product on pa_prodcode=");
+            sql.Append("select pr_code,nvl(pr_sendchecktype,'LineCode')pr_sendchecktype,pa_remark,pa_outboxcode,pa_prodcode,pa_salecode,pa_makecode,pa_sccode,nvl(pa_downstatus,0) pa_downstatus,pa_checkno,pa_status,pr_packrule,nvl(PR_CHECKCARTONW,'0') PR_CHECKCARTONW,pr_detail||'-'||pr_orispeccode pr_detail,pa_packageqty,nvl(pa_standardqty,0) pa_standardqty,nvl(pr_outboxinnerqty,0)pr_outboxinnerqty,pa_currentqty from package left join product on pa_prodcode=");
             sql.Append("pr_code where pa_outboxcode='" + pa_outboxcode.Text + "'");
             dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
             if (dt.Rows.Count > 0)
@@ -633,6 +633,8 @@ namespace UAS_MES_NEW.Packing
                     {
                         OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red);
                     }
+                    if (AutoPrint.Checked)
+                        Print_Click(new object(), new EventArgs());
                     LoadCheckQTY();
                 }
             }

+ 48 - 50
UAS_MES_ZT/FunctionCode/Packing/Packing_PackageCollectionWeigh.Designer.cs

@@ -30,9 +30,9 @@
         {
             this.components = new System.ComponentModel.Container();
             System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Packing_PackageCollectionWeigh));
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle();
             this.pa_makecode = new System.Windows.Forms.Label();
             this.label13 = new System.Windows.Forms.Label();
             this.Cancel = new System.Windows.Forms.CheckBox();
@@ -85,7 +85,7 @@
             this.label3 = new System.Windows.Forms.Label();
             this.PrintList_label = new System.Windows.Forms.Label();
             this.PrintNum_label = new System.Windows.Forms.Label();
-            this.AutoPrint = new System.Windows.Forms.CheckBox();
+            this.getwei = new System.Windows.Forms.CheckBox();
             this.StepCount = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SourceStepCount();
             this.PrintNum = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.EnterTextBox();
             this.PrintLabel = new UAS_MES_NEW.CustomControl.ComBoxWithFocus.ComboxWithTip(this.components);
@@ -111,7 +111,7 @@
             this.pd_innerqty = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.pa_indate = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.pd_id = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.getwei = new System.Windows.Forms.CheckBox();
+            this.AutoPrint = new UAS_MES_NEW.CustomControl.CustomCheckBox.AutoPrintCheckBox();
             ((System.ComponentModel.ISupportInitialize)(this.PackageDetail)).BeginInit();
             this.SuspendLayout();
             // 
@@ -689,15 +689,17 @@
             this.PrintNum_label.TabIndex = 235;
             this.PrintNum_label.Text = "份数";
             // 
-            // AutoPrint
+            // getwei
             // 
-            this.AutoPrint.AutoSize = true;
-            this.AutoPrint.Location = new System.Drawing.Point(759, 184);
-            this.AutoPrint.Name = "AutoPrint";
-            this.AutoPrint.Size = new System.Drawing.Size(106, 22);
-            this.AutoPrint.TabIndex = 247;
-            this.AutoPrint.Text = "自动打印";
-            this.AutoPrint.UseVisualStyleBackColor = true;
+            this.getwei.AutoSize = true;
+            this.getwei.Checked = true;
+            this.getwei.CheckState = System.Windows.Forms.CheckState.Checked;
+            this.getwei.Location = new System.Drawing.Point(959, 271);
+            this.getwei.Name = "getwei";
+            this.getwei.Size = new System.Drawing.Size(106, 22);
+            this.getwei.TabIndex = 248;
+            this.getwei.Text = "采集重量";
+            this.getwei.UseVisualStyleBackColor = true;
             // 
             // StepCount
             // 
@@ -1000,14 +1002,14 @@
             this.PackageDetail.AllowUserToAddRows = false;
             this.PackageDetail.AllowUserToDeleteRows = false;
             this.PackageDetail.BackgroundColor = System.Drawing.SystemColors.ButtonFace;
-            dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
-            dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
-            dataGridViewCellStyle1.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
-            dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
-            dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
-            dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
-            this.PackageDetail.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
+            dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
+            dataGridViewCellStyle4.BackColor = System.Drawing.SystemColors.Control;
+            dataGridViewCellStyle4.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            dataGridViewCellStyle4.ForeColor = System.Drawing.SystemColors.WindowText;
+            dataGridViewCellStyle4.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+            dataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+            dataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+            this.PackageDetail.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle4;
             this.PackageDetail.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
             this.PackageDetail.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
             this.pd_barcode,
@@ -1016,27 +1018,27 @@
             this.pd_innerqty,
             this.pa_indate,
             this.pd_id});
-            dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
-            dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window;
-            dataGridViewCellStyle2.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.ControlText;
-            dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight;
-            dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
-            dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
-            this.PackageDetail.DefaultCellStyle = dataGridViewCellStyle2;
+            dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
+            dataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Window;
+            dataGridViewCellStyle5.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            dataGridViewCellStyle5.ForeColor = System.Drawing.SystemColors.ControlText;
+            dataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+            dataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+            dataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
+            this.PackageDetail.DefaultCellStyle = dataGridViewCellStyle5;
             this.PackageDetail.EnableContentClick = true;
             this.PackageDetail.Location = new System.Drawing.Point(17, 257);
             this.PackageDetail.Margin = new System.Windows.Forms.Padding(4);
             this.PackageDetail.Name = "PackageDetail";
             this.PackageDetail.ReadOnly = true;
-            dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
-            dataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Control;
-            dataGridViewCellStyle3.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            dataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.WindowText;
-            dataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight;
-            dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
-            dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
-            this.PackageDetail.RowHeadersDefaultCellStyle = dataGridViewCellStyle3;
+            dataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
+            dataGridViewCellStyle6.BackColor = System.Drawing.SystemColors.Control;
+            dataGridViewCellStyle6.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            dataGridViewCellStyle6.ForeColor = System.Drawing.SystemColors.WindowText;
+            dataGridViewCellStyle6.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+            dataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+            dataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+            this.PackageDetail.RowHeadersDefaultCellStyle = dataGridViewCellStyle6;
             this.PackageDetail.RowTemplate.Height = 23;
             this.PackageDetail.Size = new System.Drawing.Size(932, 360);
             this.PackageDetail.TabIndex = 134;
@@ -1096,25 +1098,22 @@
             this.pd_id.ReadOnly = true;
             this.pd_id.Visible = false;
             // 
-            // getwei
+            // AutoPrint
             // 
-            this.getwei.AutoSize = true;
-            this.getwei.Checked = true;
-            this.getwei.CheckState = System.Windows.Forms.CheckState.Checked;
-            this.getwei.Location = new System.Drawing.Point(959, 271);
-            this.getwei.Name = "getwei";
-            this.getwei.Size = new System.Drawing.Size(106, 22);
-            this.getwei.TabIndex = 248;
-            this.getwei.Text = "采集重量";
-            this.getwei.UseVisualStyleBackColor = true;
+            this.AutoPrint.Checked = false;
+            this.AutoPrint.Location = new System.Drawing.Point(752, 178);
+            this.AutoPrint.Margin = new System.Windows.Forms.Padding(4, 6, 4, 6);
+            this.AutoPrint.Name = "AutoPrint";
+            this.AutoPrint.Size = new System.Drawing.Size(135, 34);
+            this.AutoPrint.TabIndex = 249;
             // 
             // Packing_PackageCollectionWeigh
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(1314, 873);
-            this.Controls.Add(this.getwei);
             this.Controls.Add(this.AutoPrint);
+            this.Controls.Add(this.getwei);
             this.Controls.Add(this.StepCount);
             this.Controls.Add(this.PrintNum);
             this.Controls.Add(this.label1);
@@ -1190,7 +1189,6 @@
             this.Margin = new System.Windows.Forms.Padding(4);
             this.Name = "Packing_PackageCollectionWeigh";
             this.Tag = "Packing!PackageCollectionWeigh";
-            this.Text = "Z";
             this.Activated += new System.EventHandler(this.Make_PackageCollectionWeigh_Activated);
             this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.Make_PackageCollectionWeigh_FormClosing);
             this.Load += new System.EventHandler(this.Make_PackageCollectionWeigh_Load);
@@ -1280,7 +1278,7 @@
         private CustomControl.ComBoxWithFocus.PrinterCombox PrintList;
         private System.Windows.Forms.Label PrintList_label;
         private System.Windows.Forms.Label PrintNum_label;
-        private System.Windows.Forms.CheckBox AutoPrint;
         private System.Windows.Forms.CheckBox getwei;
+        private CustomControl.CustomCheckBox.AutoPrintCheckBox AutoPrint;
     }
 }

+ 5 - 5
UAS_MES_ZT/FunctionCode/Special/Special_ResetCheck.cs

@@ -38,7 +38,7 @@ namespace UAS_MES_NEW.Special
             cd_stepcode.TableName = "craftdetail left join step on st_code=cd_stepcode left join craft on cd_crid=cr_id";
             cd_stepcode.SetValueField = new string[] { "cd_stepcode", "cd_stepno" };
             cd_stepcode.SelectField = "cd_stepname # 工序名称 ,cd_stepcode # 工序编号,cd_stepno # 执行顺序";
-            cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' order by cd_stepno";
+            cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and cd_ifoqc <> -1 order by cd_stepno";
             cd_stepcode.DBTitle = "回流工序";
             cd_stepcode.DbChange += Cd_stepcode_DbChange;
         }
@@ -181,7 +181,7 @@ namespace UAS_MES_NEW.Special
 
         private void cr_code_TextChanged(object sender, EventArgs e)
         {
-            cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' order by cd_stepno";
+            cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and cd_ifoqc <> -1 order by cd_stepno";
         }
 
         private void input_KeyDown(object sender, KeyEventArgs e)
@@ -217,7 +217,7 @@ namespace UAS_MES_NEW.Special
                         WeighRecord.Items.Add(dt.Rows[0]["ms_sncode"].ToString());
                         sb.Add(dt.Rows[0]["ms_sncode"].ToString());
                         OperatResult.AppendText("SN:" + input.Text + "采集\n", Color.Green, input);
-                        cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' order by cd_stepno";
+                        cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and cd_ifoqc <> -1 order by cd_stepno";
                     }
                     else
                     {
@@ -249,7 +249,7 @@ namespace UAS_MES_NEW.Special
                         WeighRecord.Items.Add(dt.Rows[0]["pa_outboxcode"].ToString());
                         sb.Add(dt.Rows[0]["pa_outboxcode"].ToString());
                         OperatResult.AppendText("卡通箱:" + input.Text + "采集\n", Color.Green, input);
-                        cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' order by cd_stepno";
+                        cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and cd_ifoqc <> -1 order by cd_stepno";
                     }
                     else
                     {
@@ -276,7 +276,7 @@ namespace UAS_MES_NEW.Special
                         WeighRecord.Items.Add(dt.Rows[0]["ob_checkno"].ToString());
                         sb.Add(dt.Rows[0]["ob_checkno"].ToString());
                         OperatResult.AppendText("抽检批:" + input.Text + "采集\n", Color.Green, input);
-                        cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' order by cd_stepno";
+                        cd_stepcode.Condition = "ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and cd_ifoqc <> -1 order by cd_stepno";
                     }
                     else
                     {

+ 2 - 2
UAS_MES_ZT/FunctionCode/SystemSetting/SystemSetting_PrinterTest.cs

@@ -66,7 +66,7 @@ namespace UAS_MES_NEW.SystemSetting
                         switch (format.SubStrings[j].Name)
                         {
                             case "SN":
-                                format.SubStrings[j].Value = (ma_code.Text +lpad(2, Date.Value.Year.ToString())+ lpad(2, Date.Value.Month.ToString()) + lpad(2, Date.Value.Day.ToString()) + lpad(4, (temp).ToString()));
+                                format.SubStrings[j].Value = (ma_code.Text +lpad(2, Date.Value.Year.ToString())+ lpad(2, Date.Value.Month.ToString()) + lpad(2, Date.Value.Day.ToString()) + lpad(5, (temp).ToString()));
                                 //if (!dh.CheckExist("makesnlist", "msl_sncode='" + format.SubStrings[j].Value + "'"))
                                 //{
                                 //    dh.ExecuteSql("insert into makesnlist(msl_id,msl_indate,msl_makecode,msl_sncode,msl_type)values(makesnlist_seq.nextval,sysdate,'" + ma_code.Text + "','" + format.SubStrings[j].Value + "','before')", "insert");
@@ -87,7 +87,7 @@ namespace UAS_MES_NEW.SystemSetting
                                 //};
                                 break;
                             case "NUM":
-                                format.SubStrings[j].Value = lpad(4, (temp).ToString());
+                                format.SubStrings[j].Value = lpad(5, (temp).ToString());
                                 //if (!dh.CheckExist("makesnlist", "msl_sncode='" + format.SubStrings[j].Value + "'"))
                                 //{
                                 //    dh.ExecuteSql("insert into makesnlist(msl_id,msl_indate,msl_makecode,msl_sncode,msl_type)values(makesnlist_seq.nextval,sysdate,'" + ma_code.Text + "','" + format.SubStrings[j].Value + "','before')", "insert");

+ 8 - 2
UAS_MES_ZT/PublicMethod/LogicHandler.cs

@@ -819,11 +819,17 @@ namespace UAS_MES_NEW.PublicMethod
             {
                 AutoPassJudge(iSnCode, iMakeCode, iSourceCode, "", LineCode, "", "-1");
             }
+            string dutystepcode = dh.getFieldDataByCondition("step", "nvl(ST_DUTYSTEPCODE,st_code)", "st_code = '" + StepCode + "'").ToString();
+            string dutyemcode = dh.getFieldDataByCondition("steppassed", "sp_inman", "sp_sncode  = '" + iSnCode + "' and  sp_stepcode = '" + dutystepcode + "' and sp_makecode = '" + iMakeCode + "' order by sp_id desc").ToString();
+            if (dutyemcode == "")
+            {
+                dutyemcode = iUserCode;
+            }
             sql.Clear();
             sql.Append("insert into makebad(mb_id,mb_makecode,mb_mscode,mb_sncode,mb_inman,mb_indate,mb_stepcode");
-            sql.Append(",mb_sourcecode,mb_badcode,mb_bgcode,mb_badtable,mb_status,mb_badremark,mb_bgname,mb_badname,mb_type)");
+            sql.Append(",mb_sourcecode,mb_badcode,mb_bgcode,mb_badtable,mb_status,mb_badremark,mb_bgname,mb_badname,mb_type,MB_DUTYSTEPCODE,MB_DUTYEMCODE)");
             sql.Append("select makebad_seq.nextval,ma_code,ms_code,ms_sncode,'" + iUserCode + "',sysdate,'" + StepCode + "','" + iSourceCode + "',:bc_code,:bg_code,'',");
-            sql.Append("'0',:bc_remark,:bg_name,:bc_name,'Client' from make left join makeSerial on ms_makecode=ma_code  ");
+            sql.Append("'0',:bc_remark,:bg_name,:bc_name,'Client','"+ dutystepcode + "','"+ dutyemcode + "' from make left join makeSerial on ms_makecode=ma_code  ");
             sql.Append(" where ms_sncode='" + iSnCode + "' and ms_makecode='" + iMakeCode + "'");
             if (iBadGroupCode.Length > 0)
             {