Forráskód Böngészése

添加不良计数

章政 8 éve
szülő
commit
66e4eb6aed

+ 17 - 3
UAS-MES/FunctionCode/Make/Make_TestCollection.Designer.cs

@@ -446,9 +446,11 @@
             // mcd_remainqty
             // 
             this.mcd_remainqty.AutoSize = true;
+            this.mcd_remainqty.CutLength = null;
             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(145, 16);
             this.mcd_remainqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.mcd_remainqty.MaximumSize = new System.Drawing.Size(200, 0);
             this.mcd_remainqty.Name = "mcd_remainqty";
             this.mcd_remainqty.Size = new System.Drawing.Size(0, 27);
             this.mcd_remainqty.TabIndex = 57;
@@ -457,9 +459,11 @@
             // pr_detail
             // 
             this.pr_detail.AutoSize = true;
+            this.pr_detail.CutLength = "qweqwe";
             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(506, 123);
             this.pr_detail.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pr_detail.MaximumSize = new System.Drawing.Size(200, 0);
             this.pr_detail.Name = "pr_detail";
             this.pr_detail.Size = new System.Drawing.Size(0, 27);
             this.pr_detail.TabIndex = 56;
@@ -467,9 +471,11 @@
             // ma_qty
             // 
             this.ma_qty.AutoSize = true;
+            this.ma_qty.CutLength = null;
             this.ma_qty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.ma_qty.Location = new System.Drawing.Point(505, 60);
             this.ma_qty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ma_qty.MaximumSize = new System.Drawing.Size(200, 0);
             this.ma_qty.Name = "ma_qty";
             this.ma_qty.Size = new System.Drawing.Size(0, 27);
             this.ma_qty.TabIndex = 55;
@@ -477,9 +483,11 @@
             // mcd_inqty
             // 
             this.mcd_inqty.AutoSize = true;
+            this.mcd_inqty.CutLength = null;
             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(331, 16);
             this.mcd_inqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.mcd_inqty.MaximumSize = new System.Drawing.Size(200, 0);
             this.mcd_inqty.Name = "mcd_inqty";
             this.mcd_inqty.Size = new System.Drawing.Size(0, 27);
             this.mcd_inqty.TabIndex = 54;
@@ -488,9 +496,11 @@
             // ma_prodcode
             // 
             this.ma_prodcode.AutoSize = true;
+            this.ma_prodcode.CutLength = null;
             this.ma_prodcode.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.ma_prodcode.Location = new System.Drawing.Point(126, 123);
             this.ma_prodcode.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ma_prodcode.MaximumSize = new System.Drawing.Size(200, 0);
             this.ma_prodcode.Name = "ma_prodcode";
             this.ma_prodcode.Size = new System.Drawing.Size(0, 27);
             this.ma_prodcode.TabIndex = 53;
@@ -647,10 +657,12 @@
             // ob_batchqty
             // 
             this.ob_batchqty.AutoSize = true;
+            this.ob_batchqty.CutLength = null;
             this.ob_batchqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.ob_batchqty.ForeColor = System.Drawing.Color.Black;
             this.ob_batchqty.Location = new System.Drawing.Point(145, 65);
             this.ob_batchqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_batchqty.MaximumSize = new System.Drawing.Size(200, 0);
             this.ob_batchqty.Name = "ob_batchqty";
             this.ob_batchqty.Size = new System.Drawing.Size(0, 27);
             this.ob_batchqty.TabIndex = 75;
@@ -671,10 +683,12 @@
             // ob_nowcheckqty
             // 
             this.ob_nowcheckqty.AutoSize = true;
+            this.ob_nowcheckqty.CutLength = null;
             this.ob_nowcheckqty.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.ob_nowcheckqty.ForeColor = System.Drawing.Color.Black;
             this.ob_nowcheckqty.Location = new System.Drawing.Point(331, 65);
             this.ob_nowcheckqty.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ob_nowcheckqty.MaximumSize = new System.Drawing.Size(200, 0);
             this.ob_nowcheckqty.Name = "ob_nowcheckqty";
             this.ob_nowcheckqty.Size = new System.Drawing.Size(0, 27);
             this.ob_nowcheckqty.TabIndex = 73;
@@ -750,11 +764,11 @@
             this.Text = " ";
             this.Load += new System.EventHandler(this.TestCollection_Load);
             this.SizeChanged += new System.EventHandler(this.测试采集_SizeChanged);
-            this.panel2.ResumeLayout(true);
+            this.panel2.ResumeLayout(false);
             this.panel2.PerformLayout();
-            this.panel1.ResumeLayout(true);
+            this.panel1.ResumeLayout(false);
             this.panel1.PerformLayout();
-            this.ResumeLayout(true);
+            this.ResumeLayout(false);
             this.PerformLayout();
 
         }

+ 1 - 0
UAS-MES/FunctionCode/OQC/OQC_SamplingDataCollection.cs

@@ -256,6 +256,7 @@ namespace UAS_MES.OQC
                         }
                         if (bc_name.Count > 0)
                         {
+                            dh.UpdateByCondition("makeserial", "ms_badtimes=ms_badtimes+1", "ms_sncode='"+sncode.Text+"'");
                             dh.ExecuteSql("delete from OQCNGReason where or_sncode='" + sncode.Text + "' and or_checkno='" + ob_checkno.Text + "'", "delete");
                             sql.Clear();
                             sql.Append("insert into OQCNGReason(or_id, or_checkno, or_makecode, or_sncode, or_reasoncode, oi_description, oi_remark)");

+ 2 - 2
UAS-MES/PublicMethod/LogicHandler.cs

@@ -730,7 +730,7 @@ namespace UAS_MES.PublicMethod
                     break;
                 case "OQCPLANMAINTAIN":
                     sql.Clear();
-                    sql.Append("select ob_prodcode,ob_id,ob_checkno,ob_projectcode,ob_batchqty,ob_source,ob_remark,");
+                    sql.Append("select ob_prodcode,ob_id,ob_checkno,ob_projectcode,ob_nowcheckqty,ob_source,ob_remark,");
                     sql.Append("ob_status,pr_id,pr_detail,pr_kind,pr_manutype,pr_qualmethod,nvl(ob_aqlcode,pr_aql)ob_aqlcode from OQCBatch left join product on ");
                     sql.Append("pr_code=ob_prodcode where ob_checkno='" + iCheckNo + "'");
                     Form = (DataTable)dh.ExecuteSql(sql.ToString(), "select");
@@ -1013,7 +1013,7 @@ namespace UAS_MES.PublicMethod
             sql.Append("sp_mothercode=ma_prodcode and sp_stepcode=ms_nextstepcode where ms_sncode='" + iSnCode + "'");
             dh.BatchInsert(sql.ToString(), new string[] { "bc_code", "bg_code", "bc_remark" }, iBadCode, iBadGroupCode, iBadRemark);
             //更新序列号已经采集的工序 ms_paststep 已采集数据,更新下一工序
-            dh.UpdateByCondition("makeserial", "ms_paststep = ms_paststep ||'," + StepCode + "',ms_status=3", "ms_sncode='" + iSnCode + "'");
+            dh.UpdateByCondition("makeserial", "ms_paststep = ms_paststep ||'," + StepCode + "',ms_status=3,ms_badtimes=ms_badtimes+1", "ms_sncode='" + iSnCode + "'");
             //如果存在送检批号则进行删除
             if (dh.CheckExist("oqcbatchdetail", "obd_sncode='"+iSnCode+"'"))
             {