2 Komitmen 7a92811953 ... abf07c4f8e

Pembuat SHA1 Pesan Tanggal
  caosy abf07c4f8e Merge branch 'master' of repos.ubtob.net:usoft/mes-client 1 Minggu lalu
  caosy 4fb8f5eff7 正通仁禾MES项目修改提交 1 Minggu lalu

File diff ditekan karena terlalu besar
+ 305 - 258
UAS_MES_ZT/FunctionCode/Make/Make_FeedingCollection.Designer.cs


+ 53 - 55
UAS_MES_ZT/FunctionCode/Make/Make_FeedingCollection.cs

@@ -75,16 +75,16 @@ namespace UAS_MES_NEW.Make
             asc.controllInitializeSize(this);
             LockMakeCode.GetMakeCodeCtl(ma_code);
             ma_code.SetLockCheckBox(LockMakeCode);
-            InitPrint = new Thread(InPrint);
-            SetLoadingWindow stw = new SetLoadingWindow(InitPrint, "初始化打印程序");
-            BaseUtil.SetFormCenter(stw);
-            stw.ShowDialog();
+            //InitPrint = new Thread(InPrint);
+            //SetLoadingWindow stw = new SetLoadingWindow(InitPrint, "初始化打印程序");
+            //BaseUtil.SetFormCenter(stw);
+            //stw.ShowDialog();
             //工单号放大镜配置
             ma_code.TableName = "make left join product on ma_prodcode=pr_code";
             ma_code.SelectField = "ma_code # 工单号,ma_prodcode # 产品编号,ma_qty # 工单数量,ma_craftcode # 途程编号,pr_spec # 产品规格,ma_bomversion # Bom版本,ma_softversion # 软件版本";
             ma_code.FormName = Name;
             ma_code.DBTitle = "工单查询";
-            ma_code.SetValueField = new string[] { "ma_code", "ma_prodcode", "ma_qty", "pr_spec", "ma_craftcode", "ma_bomversion", "ma_softversion" };
+            ma_code.SetValueField = new string[] { "ma_code", "ma_prodcode", "ma_qty", "pr_orispeccode pr_spec", "ma_craftcode", "ma_bomversion", "ma_softversion" };
             ma_code.Condition = "ma_statuscode='STARTED'";
             ma_code.DbChange += Ma_code_DBChange;
             code.Focus();
@@ -301,7 +301,7 @@ namespace UAS_MES_NEW.Make
                 //将录入框的值给序列号
                 sn_code.Text = code.Text;
                 sql.Clear();
-                sql.Append("select ma_prodcode,ma_ecncode,ma_softversion,ms_firstsn,ma_bomversion,ma_qty,ma_code,pr_spec,ms_status,ms_id,ms_craftcode,ms_nextstepcode");
+                sql.Append("select ma_prodcode,ma_ecncode,ma_softversion,ms_firstsn,ma_bomversion,ma_qty,ma_code,pr_orispeccode pr_spec,ms_status,ms_id,ms_craftcode,ms_nextstepcode");
                 sql.Append(",ms_prodcode,ms_makecode,ms_code,ms_stepname  from makeserial left join make on ma_code=ms_makecode ");
                 sql.Append("left join product on ms_prodcode=pr_code where ms_sncode='" + code.Text + "' order by ms_id desc");
                 dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
@@ -377,7 +377,7 @@ namespace UAS_MES_NEW.Make
                         ms_status = dt.Rows[0]["ms_status"].ToString();
                         sn_code.Text = code.Text;
                         sql.Clear();
-                        sql.Append("select ma_code,ma_softversion,ma_ecncode,ma_prodcode,pr_spec,ma_qty from makeserial left join product ");
+                        sql.Append("select ma_code,ma_softversion,ma_ecncode,ma_prodcode,pr_orispeccode pr_spec,ma_qty from makeserial left join product ");
                         sql.Append(" on ms_prodcode=pr_code left join make on ms_makecode=ma_code  ");
                         sql.Append(" where ms_id='" + oMsid + "'");
                         dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
@@ -403,7 +403,7 @@ namespace UAS_MES_NEW.Make
             sql.Clear();
             sql.Append("select max(sp_id)sp_id,max(sp_detno)sp_detno,min(sp_ifrepeat)sp_ifrepeat,min(sp_iflabelcheck) sp_iflabelcheck,max(sp_checkbarcode)sp_checkbarcode,min(sp_checksalecode)sp_checksalecode,");
             sql.Append("sp_fsoncode,max(sp_barcoderule)sp_barcoderule,wm_concat(sp_soncode) sp_soncode,max(sp_ifuseregex)sp_ifuseregex,max(sp_ifforsn)");
-            sql.Append("sp_ifforsn,max(sp_length)sp_length,max(sp_type)sp_type,replace(wm_concat(sp_prefix),',','|')sp_prefix,max(sp_regex)");
+            sql.Append("sp_ifforsn,max(sp_length)sp_length,max(sp_type)sp_type,replace(wm_concat(pr_oriname),',','|')sp_prefix,max(sp_regex)");
             sql.Append("sp_regex,max(pr_detail)pr_detail from stepproduct left join product on pr_code=sp_fsoncode where ");
             sql.Append("sp_bomversion='" + ma_bomversion.Text + "' and sp_craftcode='" + ms_craftcode.Text + "' and sp_stepcode='" + User.CurrentStepCode + "' ");
             sql.Append("And sp_mothercode ='" + ma_prodcode.Text + "' and sp_tracekind=1 and not exists(select 1 from craftmaterial where ");
@@ -501,19 +501,19 @@ namespace UAS_MES_NEW.Make
                 }
                 //更新序列号半成品已被使用
                 //dh.BatchInsert("update makeserial set ms_nextmacode='" + ma_code + "' where ms_id=(select max(ms_id) from makeserial where ms_sncode=:sncode and ms_nextmacode is null and ms_makecode<>'" + ma_code + "')", new string[] { "sncode" }, TSN.ToArray());
-                if (ma_ecncode_label.Checked || ma_softversion_label.Checked)
-                {
-                    string ecnText = ma_ecncode_label.Checked ? ma_ecncode.Text : "";
-                    string softversionText = ma_softversion_label.Checked ? ma_softversion.Text : "";
-                    string remark = sir_remark_label.Checked ? sir_remark.Text : "";
-                    sql.Clear();
-                    sql.Append("insert into SNRELATIONINFORECORD(SIR_ID,SIR_SNCODE,SIR_MSCODE,SIR_ECNCODE,SIR_SOFTVER,");
-                    sql.Append("SIR_LINECODE,SIR_SOURCECODE,SIR_STEPCODE,SIR_MACODE,SIR_PRODCODE,SIR_INMAN,SIR_INDATE,sir_firstsn,sir_remark) select ");
-                    sql.Append("SNRELATIONINFORECORD_SEQ.nextval,'" + sn_code.Text + "',ms_code,'" + ecnText + "','" + softversionText + "',");
-                    sql.Append("'" + User.UserLineCode + "','" + User.UserSourceCode + "','" + User.CurrentStepCode + "','" + ma_code + "','" + ma_prodcode.Text + "',");
-                    sql.Append("'" + User.UserCode + "',sysdate,ms_firstsn,'" + remark + "' from makeserial where ms_sncode='" + sn_code.Text + "' and ms_makecode='" + ma_code + "'");
-                    dh.ExecuteSql(sql.GetString(), "insert");
-                }
+                //if (ma_ecncode_label.Checked || ma_softversion_label.Checked)
+                //{
+                //    string ecnText = ma_ecncode_label.Checked ? ma_ecncode.Text : "";
+                //    string softversionText = ma_softversion_label.Checked ? ma_softversion.Text : "";
+                //    string remark = sir_remark_label.Checked ? sir_remark.Text : "";
+                //    sql.Clear();
+                //    sql.Append("insert into SNRELATIONINFORECORD(SIR_ID,SIR_SNCODE,SIR_MSCODE,SIR_ECNCODE,SIR_SOFTVER,");
+                //    sql.Append("SIR_LINECODE,SIR_SOURCECODE,SIR_STEPCODE,SIR_MACODE,SIR_PRODCODE,SIR_INMAN,SIR_INDATE,sir_firstsn,sir_remark) select ");
+                //    sql.Append("SNRELATIONINFORECORD_SEQ.nextval,'" + sn_code.Text + "',ms_code,'" + ecnText + "','" + softversionText + "',");
+                //    sql.Append("'" + User.UserLineCode + "','" + User.UserSourceCode + "','" + User.CurrentStepCode + "','" + ma_code + "','" + ma_prodcode.Text + "',");
+                //    sql.Append("'" + User.UserCode + "',sysdate,ms_firstsn,'" + remark + "' from makeserial where ms_sncode='" + sn_code.Text + "' and ms_makecode='" + ma_code + "'");
+                //    dh.ExecuteSql(sql.GetString(), "insert");
+                //}
                 CollectData.Clear();
                 TSN.Clear();
                 SPID.Clear();
@@ -528,18 +528,18 @@ namespace UAS_MES_NEW.Make
                     //提示正确返回时传递的信息
                     if (ErrorMessage.Contains("AFTERSUCCESS"))
                         OperateResult.AppendText(">>" + ErrorMessage + "\n");
-                    if (checkBox1.Checked)
-                    {
-                        if (Print.SinglePrint(Tag.ToString(), engine, PrintLabel.Text, PrintLabel.SelectedValue.ToString(), Printer.Text, sn_code.Text, int.Parse(PrintNum.Text), oMakeCode, ma_prodcode.Text, "机身标", "-1", out ErrorMessage))
-                        {
-                            //提示用户打印成功
-                            OperateResult.AppendText(">>序列号:" + sn_code.Text + "打印成功\n", Color.Green);
-                        }
-                        else
-                        {
-                            OperateResult.AppendText(ErrorMessage + "\n", Color.Red);
-                        }
-                    }
+                    //if (checkBox1.Checked)
+                    //{
+                    //    if (Print.SinglePrint(Tag.ToString(), engine, PrintLabel.Text, PrintLabel.SelectedValue.ToString(), Printer.Text, sn_code.Text, int.Parse(PrintNum.Text), oMakeCode, ma_prodcode.Text, "机身标", "-1", out ErrorMessage))
+                    //    {
+                    //        //提示用户打印成功
+                    //        OperateResult.AppendText(">>序列号:" + sn_code.Text + "打印成功\n", Color.Green);
+                    //    }
+                    //    else
+                    //    {
+                    //        OperateResult.AppendText(ErrorMessage + "\n", Color.Red);
+                    //    }
+                    //}
 
                     sn_code.Text = "";
                     //刷新数据
@@ -570,41 +570,39 @@ namespace UAS_MES_NEW.Make
 
         private void ma_code_UserControlTextChanged(object sender, EventArgs e)
         {
-            if (ma_code.Text.Length > 5)
+            if (ma_code.Text.Length > 4)
             {
-                string ErrMessage = "";
-                if (LogicHandler.CheckMakeStatus(ma_code.Text, out ErrMessage))
+                if (ma_code.Text.Length > 4)
                 {
-                    mcd_inqty.Text = "";
-                    mcd_remainqty.Text = "";
-                    sql.Clear();
-                    sql.Append("select mcd_inqty,ma_qty-mcd_inqty mcd_remainqty ");
-                    sql.Append("from make left join makecraftdetail_view on mcd_macode=ma_code where ");
-                    sql.Append("ma_code='" + ma_code.Text + "' and mcd_stepcode='" + User.CurrentStepCode + "'");
-                    DataTable dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
-                    if (dt.Rows.Count > 0)
-                        BaseUtil.SetFormValue(Controls, dt);
+                    BaseUtil.CleanControlsText(mcd_inqty, mcd_remainqty);
+                    LoadCollectedNum();
                 }
             }
         }
 
+        private void LoadCollectedNum()
+        {
+            dt = (DataTable)dh.ExecuteSql("select mcd_inqty,ma_qty-mcd_inqty mcd_remainqty,mcd_ngqty,mcd_okqty,mcd_totalng from make left join makecraftdetail_view on mcd_macode=ma_code where ma_code='" + ma_code.Text + "' and mcd_stepcode='" + User.CurrentStepCode + "'", "select");
+            BaseUtil.SetFormValue(Controls, dt);
+        }
+
         private void Make_FeedingCollection_FormClosing(object sender, FormClosingEventArgs e)
         {
-            if (engine != null)
-                engine.Quit(BarTender.BtSaveOptions.btDoNotSaveChanges);
+            //if (engine != null)
+            //    engine.Quit(BarTender.BtSaveOptions.btDoNotSaveChanges);
             dh.Dispose();
         }
 
         private void ma_prodcode_TextChanged(object sender, EventArgs e)
         {
-            DataTable dt = (DataTable)dh.ExecuteSql("select la_id,la_url,la_isdefault from label where la_prodcode='" + ma_prodcode.Text + "' and la_templatetype='机身标' and la_statuscode='AUDITED' order by la_isdefault", "select");
-            if (dt.Rows.Count == 0)
-            {
-                return;
-            }
-            PrintLabel.DataSource = dt;
-            PrintLabel.DisplayMember = "la_url";
-            PrintLabel.ValueMember = "la_id";
+            //DataTable dt = (DataTable)dh.ExecuteSql("select la_id,la_url,la_isdefault from label where la_prodcode='" + ma_prodcode.Text + "' and la_templatetype='机身标' and la_statuscode='AUDITED' order by la_isdefault", "select");
+            //if (dt.Rows.Count == 0)
+            //{
+            //    return;
+            //}
+            //PrintLabel.DataSource = dt;
+            //PrintLabel.DisplayMember = "la_url";
+            //PrintLabel.ValueMember = "la_id";
         }
     }
 }

+ 128 - 14
UAS_MES_ZT/FunctionCode/Make/Make_FeedingCollection.resx

@@ -117,40 +117,118 @@
   <resheader name="writer">
     <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
   </resheader>
-  <metadata name="序号.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="mcd_restqty_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="cm_makecode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="mcd_inqty_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="pr_detail_.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="ma_qty_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="cm_soncode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="ms_makecode_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="cm_barcode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="ma_prodcode_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="BarCode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="Loading.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="序号.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="UnLoading.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="cm_makecode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="sn_code_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="pr_detail_.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="code_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="cm_soncode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="iflastsn.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="cm_barcode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="ma_softversion_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="BarCode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="ma_ecncode_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ClearSn_code.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ms_craftcode.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ma_bomversion.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ma_bomversion_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ma_craftcode.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="sir_remark_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="NoteForChange.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="label2.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="label1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="label4.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="checkBox1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="pr_detail_label.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="pr_spec.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="PrintLabel.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="Printer.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="PrintNum.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="sir_remark.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="StepCount.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ma_code.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="LockMakeCode.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ma_prodcode.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="mcd_remainqty.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="mcd_inqty.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ma_qty.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="OperateResult.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="Clean.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
   <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
@@ -213,7 +291,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALEwAACxMBAJqcGAAACfBJREFUeF7t3dtuFFcC
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDwAACw8BkvkDpQAACfBJREFUeF7t3dtuFFcC
         heFc5VWQRsrL5T0iRcrDkJAjJOADNjbdbvD5iE9tu302RIq0Z6+ynWkmS6oZrlys/+KT8FJX3f2bcmPa
         X5RSAISyI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0BZLAjgAx2BJDBjgAy2BFABjsCyGBHABnsCCCD
         HQFksCOADHYEkMGOADLYEUAGOwLIYEcAGewIIIMdAWSwI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0B
@@ -285,6 +363,15 @@
         ROJSU3qXjMKwG/vjzEz/skOI3Zqgv7AAAAAASUVORK5CYII=
 </value>
   </data>
+  <metadata name="ma_softversion.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ma_ecncode.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="Confirm.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
   <data name="Confirm.DownImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
@@ -344,7 +431,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALEwAACxMBAJqcGAAACfBJREFUeF7t3dtuFFcC
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDwAACw8BkvkDpQAACfBJREFUeF7t3dtuFFcC
         heFc5VWQRsrL5T0iRcrDkJAjJOADNjbdbvD5iE9tu302RIq0Z6+ynWkmS6oZrlys/+KT8FJX3f2bcmPa
         X5RSAISyI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0BZLAjgAx2BJDBjgAy2BFABjsCyGBHABnsCCCD
         HQFksCOADHYEkMGOADLYEUAGOwLIYEcAGewIIIMdAWSwI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0B
@@ -416,4 +503,31 @@
         ROJSU3qXjMKwG/vjzEz/skOI3Zqgv7AAAAAASUVORK5CYII=
 </value>
   </data>
+  <metadata name="code.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="sn_code.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="序号.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="cm_makecode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="pr_detail_.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="cm_soncode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="cm_barcode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="BarCode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="$this.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
 </root>

+ 2 - 44
UAS_MES_ZT/FunctionCode/Make/Make_PositionStockNew.resx

@@ -215,7 +215,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALEwAACxMBAJqcGAAACfBJREFUeF7t3dtuFFcC
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALEgAACxIB0t1+/AAACfBJREFUeF7t3dtuFFcC
         heFc5VWQRsrL5T0iRcrDkJAjJOADNjbdbvD5iE9tu302RIq0Z6+ynWkmS6oZrlys/+KT8FJX3f2bcmPa
         X5RSAISyI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0BZLAjgAx2BJDBjgAy2BFABjsCyGBHABnsCCCD
         HQFksCOADHYEkMGOADLYEUAGOwLIYEcAGewIIIMdAWSwI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0B
@@ -329,48 +329,6 @@
   <metadata name="DeleteRow.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="sp_soncode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mss_linecode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mss_makecode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mss_id.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mss_prodcode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mss_barcode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="sp_oneuseqty.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mss_qty.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mm_qty.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mss_remain.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mss_useqty.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="pr_orispeccode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="pr_detail1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="DeleteRow.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
   <data name="Screen.DownImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
@@ -430,7 +388,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALEwAACxMBAJqcGAAACfBJREFUeF7t3dtuFFcC
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALEgAACxIB0t1+/AAACfBJREFUeF7t3dtuFFcC
         heFc5VWQRsrL5T0iRcrDkJAjJOADNjbdbvD5iE9tu302RIq0Z6+ynWkmS6oZrlys/+KT8FJX3f2bcmPa
         X5RSAISyI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0BZLAjgAx2BJDBjgAy2BFABjsCyGBHABnsCCCD
         HQFksCOADHYEkMGOADLYEUAGOwLIYEcAGewIIIMdAWSwI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0B

File diff ditekan karena terlalu besar
+ 198 - 184
UAS_MES_ZT/FunctionCode/Make/Make_RepairOk.Designer.cs


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

@@ -434,7 +434,7 @@ namespace UAS_MES_NEW.Make
                 //加载两个Grid的数据源
                 DataTable dt = (DataTable)dh.ExecuteSql("select mbp_id,mbp_part from makebadrspart where mbp_mbrid=" + mbr_id, "select");
                 BaseUtil.FillDgvWithDataTable(mbp_partdgv, dt);
-                dt = (DataTable)dh.ExecuteSql("select mbl_id,mbl_loc from makebadrsloc where mbl_mbrid=" + mbr_id, "select");
+                dt = (DataTable)dh.ExecuteSql("select mbl_id,mbl_loc,mbl_orispeccode from makebadrsloc where mbl_mbrid=" + mbr_id, "select");
                 BaseUtil.FillDgvWithDataTable(mbl_locdgv, dt);
                 SaveRepairInf.Enabled = false;
             }
@@ -628,7 +628,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 + "' and mb_status = 0");
+                    SQLS.Add("update makebad set mb_status=-1,mb_okman ='"+User.UserName+ "',MB_OKTIME = sysdate 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)
@@ -855,40 +855,34 @@ namespace UAS_MES_NEW.Make
                 {
                     if (mbr_id != "")
                     {
-                        if (!dh.CheckExist("makebadrsloc", "mbl_mbrid='" + mbr_id + "' and mbl_sncode='" + GetSNCode.Text + "' and mbl_loc='" + mbl_loc.Text.ToUpper() + "'"))
+                        if (!dh.CheckExist("makebadrsloc", "mbl_mbrid='" + mbr_id + "' and mbl_sncode='" + GetSNCode.Text + "' and mbl_loc='" + mbl_loc.Text + "'"))
                         {
-                            sql.Clear();
-                            sql.Append("insert into makebadrsloc(mbl_id,mbl_mbrid,mbl_loc,mbl_badcode,mbl_brcode,");
-                            sql.Append("mbl_sncode,mbl_makecode,mbl_indate ,mbl_inman) select makebadrsloc_seq.nextval," + mbr_id);
-                            sql.Append(",'" + mbl_loc.Text.ToUpper() + "','" + bc_code.Text + "','" + nr_code.Text + "','" + GetSNCode.Text + "','" + macode + "',");
-                            sql.Append("sysdate,'" + User.UserCode + "' from dual");
-                            dh.ExecuteSql(sql.GetString(), "insert");
-                            dt = (DataTable)dh.ExecuteSql("select mbl_id,mbl_loc from makebadrsloc where mbl_mbrid=" + mbr_id, "select");
-                            BaseUtil.FillDgvWithDataTable(mbl_locdgv, dt);
-                            sql.Clear();
-                            sql.Append("with temp1 as (select bd_soncode,bd_location from bomdetail,bom where bo_id=bd_bomid ");
-                            sql.Append(" start with bo_mothercode='" + ms_prodcode.Text + "' connect by bo_mothercode= prior bd_soncode) ");
-                            sql.Append("select bd_soncode from temp1 where instr(','||bd_location||',','," + mbl_loc.Text.ToUpper() + ",')>0");
-                            dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
-                            if (dt.Rows.Count > 0)
+                            if (dh.CheckExist("barcode", "bar_code = '" + mbl_loc.Text + "'"))
                             {
-                                sql.Clear();
-                                sql.Append("insert into makebadrspart(mbp_id,mbp_mbrid,mbp_part,mbp_badcode,");
-                                sql.Append("mbp_brcode,mbp_sncode,mbp_makecode,mbp_indate,mbp_inman)");
-                                sql.Append("select makebadrspart_seq.nextval," + mbr_id + ",'" + dt.Rows[0][0].ToString() + "',");
-                                sql.Append("'" + bc_code.Text + "','" + nr_code.Text + "','" + GetSNCode.Text + "','" + macode + "',");
-                                sql.Append("sysdate,'" + User.UserCode + "' from dual");
-                                dh.ExecuteSql(sql.GetString(), "insert");
-                                dt = (DataTable)dh.ExecuteSql("select mbp_id,mbp_part from makebadrspart where mbp_mbrid=" + mbr_id, "select");
-                                BaseUtil.FillDgvWithDataTable(mbp_partdgv, dt);
-                                mbl_loc.Clear();
+                                string MBL_PRODCODE = dh.getFieldDataByCondition("barcode", "bar_prodcode", "bar_code = '" + mbl_loc.Text + "'").ToString();
+                                string orpspeccode = dh.getFieldDataByCondition("product", "pr_orispeccode", "pr_code = '" + MBL_PRODCODE + "'").ToString();
+                                if (dh.CheckExist("MAKEMATERIAL", "mm_code = '"+ macode + "' and mm_prodcode||mm_repprodcode  like '%" + MBL_PRODCODE + "%'"))
+                                {
+                                    sql.Clear();
+                                    sql.Append("insert into makebadrsloc(mbl_id,mbl_mbrid,mbl_loc,mbl_badcode,mbl_brcode,");
+                                    sql.Append("mbl_sncode,mbl_makecode,mbl_indate ,mbl_inman,MBL_PRODCODE,MBL_ORISPECCODE) select makebadrsloc_seq.nextval," + mbr_id);
+                                    sql.Append(",'" + mbl_loc.Text + "','" + bc_code.Text + "','" + nr_code.Text + "','" + GetSNCode.Text + "','" + macode + "',");
+                                    sql.Append("sysdate,'" + User.UserCode + "','"+ MBL_PRODCODE + "','"+ orpspeccode + "' from dual");
+                                    dh.ExecuteSql(sql.GetString(), "insert");
+                                    dt = (DataTable)dh.ExecuteSql("select mbl_id,mbl_loc,mbl_orispeccode from makebadrsloc where mbl_mbrid=" + mbr_id, "select");
+                                    BaseUtil.FillDgvWithDataTable(mbl_locdgv, dt);
+                                }else
+                                    OperatResult.AppendText(">>该维修条码对应物料" + MBL_PRODCODE + "不属于此工单可用物料\n", Color.Red, mbl_loc);
                             }
+                            else
+                                OperatResult.AppendText(">>该维修条码"+mbl_loc.Text+"系统不存在\n", Color.Red, mbl_loc);
+
                         }
-                        else OperatResult.AppendText(">>已存在该不良位置\n", Color.Red);
+                        else OperatResult.AppendText(">>已存在该维修条码\n", Color.Red, mbl_loc);
                     }
                     else OperatResult.AppendText(">>请先选择不良原因\n", Color.Red);
                 }
-                else OperatResult.AppendText(">>不良位置不能为空\n", Color.Red);
+                else OperatResult.AppendText(">>维修条码不能为空\n", Color.Red);
             }
             else OperatResult.AppendText(">>" + GetSNCode.Text + "序列号错误,不存在或者不处于维修状态\n", Color.Red);
         }
@@ -949,7 +943,7 @@ namespace UAS_MES_NEW.Make
                 if (mbl_locdgv.Columns[e.ColumnIndex].Name == "DeletePos")
                 {
                     dh.ExecuteSql("delete from makebadrsloc where mbl_id='" + mbl_locdgv.Rows[e.RowIndex].Cells["mbl_id"].Value.ToString() + "'", "insert");
-                    dt = (DataTable)dh.ExecuteSql("select mbl_id,mbl_loc from makebadrsloc where mbl_mbrid=" + mbr_id, "select");
+                    dt = (DataTable)dh.ExecuteSql("select mbl_id,mbl_loc,mbl_orispeccode from makebadrsloc where mbl_mbrid=" + mbr_id, "select");
                     BaseUtil.FillDgvWithDataTable(mbl_locdgv, dt);
                 }
             }
@@ -1072,7 +1066,7 @@ namespace UAS_MES_NEW.Make
                 //加载两个Grid的数据源
                 DataTable dt = (DataTable)dh.ExecuteSql("select mbp_id,mbp_part from makebadrspart where mbp_mbrid=" + mbr_id, "select");
                 BaseUtil.FillDgvWithDataTable(mbp_partdgv, dt);
-                dt = (DataTable)dh.ExecuteSql("select mbl_id,mbl_loc from makebadrsloc where mbl_mbrid=" + mbr_id, "select");
+                dt = (DataTable)dh.ExecuteSql("select mbl_id,mbl_loc,mbl_orispeccode from makebadrsloc where mbl_mbrid=" + mbr_id, "select");
                 BaseUtil.FillDgvWithDataTable(mbl_locdgv, dt);
                 SaveRepairInf.Enabled = false;
             }

+ 1 - 4
UAS_MES_ZT/FunctionCode/Make/Make_RepairOk.resx

@@ -256,10 +256,7 @@
   <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">
+  <metadata name="mbl_orispeccode1.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">

+ 16 - 3
UAS_MES_ZT/FunctionCode/Make/Make_SeqTransform.Designer.cs

@@ -65,6 +65,7 @@
             this.ma_salecode = new System.Windows.Forms.Label();
             this.mcd_inqty = new System.Windows.Forms.Label();
             this.label5 = new System.Windows.Forms.Label();
+            this.ma_endremark = new System.Windows.Forms.Label();
             ((System.ComponentModel.ISupportInitialize)(this.ClearSn_code)).BeginInit();
             this.SuspendLayout();
             // 
@@ -483,18 +484,19 @@
             this.label4.Font = new System.Drawing.Font("微软雅黑", 12F);
             this.label4.Location = new System.Drawing.Point(825, 76);
             this.label4.Name = "label4";
-            this.label4.Size = new System.Drawing.Size(86, 31);
+            this.label4.Size = new System.Drawing.Size(110, 31);
             this.label4.TabIndex = 227;
-            this.label4.Text = "合同号";
+            this.label4.Text = "客户代码";
             // 
             // ma_salecode
             // 
             this.ma_salecode.AutoSize = true;
             this.ma_salecode.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.ma_salecode.Location = new System.Drawing.Point(936, 76);
+            this.ma_salecode.Location = new System.Drawing.Point(1095, 167);
             this.ma_salecode.Name = "ma_salecode";
             this.ma_salecode.Size = new System.Drawing.Size(0, 31);
             this.ma_salecode.TabIndex = 228;
+            this.ma_salecode.Visible = false;
             // 
             // mcd_inqty
             // 
@@ -515,11 +517,21 @@
             this.label5.TabIndex = 229;
             this.label5.Text = "采集数";
             // 
+            // ma_endremark
+            // 
+            this.ma_endremark.AutoSize = true;
+            this.ma_endremark.Font = new System.Drawing.Font("微软雅黑", 12F);
+            this.ma_endremark.Location = new System.Drawing.Point(935, 76);
+            this.ma_endremark.Name = "ma_endremark";
+            this.ma_endremark.Size = new System.Drawing.Size(0, 31);
+            this.ma_endremark.TabIndex = 231;
+            // 
             // Make_SeqTransform
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(1274, 700);
+            this.Controls.Add(this.ma_endremark);
             this.Controls.Add(this.mcd_inqty);
             this.Controls.Add(this.label5);
             this.Controls.Add(this.ma_salecode);
@@ -608,5 +620,6 @@
         private System.Windows.Forms.Label ma_salecode;
         private System.Windows.Forms.Label mcd_inqty;
         private System.Windows.Forms.Label label5;
+        private System.Windows.Forms.Label ma_endremark;
     }
 }

+ 1 - 1
UAS_MES_ZT/FunctionCode/Make/Make_SeqTransform.cs

@@ -133,7 +133,7 @@ namespace UAS_MES_NEW.Make
                             {
                                 //按照out出的工单号查出工单相关信息,并赋值到相关控件
                                 sql.Clear();
-                                sql.Append("select ma_code,ma_softversion,ma_prodcode,pr_orispeccode pr_detail,ma_salecode,ma_qty,ma_qty-mcd_inqty as remain_qty ");
+                                sql.Append("select ma_code,ma_softversion,ma_prodcode,pr_orispeccode pr_detail,ma_endremark,ma_salecode,ma_qty,ma_qty-mcd_inqty as remain_qty ");
                                 sql.Append("from makeserial left join make on ms_makecode=ma_code left join product on ");
                                 sql.Append("ms_prodcode=pr_code left join makecraftdetail_view on ms_makecode=mcd_macode where ms_id='" + oMsId + "' and mcd_stepcode='" + User.CurrentStepCode + "'");
                                 dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");

+ 105 - 92
UAS_MES_ZT/FunctionCode/Make/Make_SeqTransform2.Designer.cs

@@ -66,6 +66,7 @@
             this.mcd_inqty = new System.Windows.Forms.Label();
             this.label5 = new System.Windows.Forms.Label();
             this.checkBox1 = new System.Windows.Forms.CheckBox();
+            this.ma_endremark = new System.Windows.Forms.Label();
             ((System.ComponentModel.ISupportInitialize)(this.ClearSn_code)).BeginInit();
             this.SuspendLayout();
             // 
@@ -73,20 +74,20 @@
             // 
             this.ms_makecode_label.AutoSize = true;
             this.ms_makecode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ms_makecode_label.Location = new System.Drawing.Point(20, 22);
+            this.ms_makecode_label.Location = new System.Drawing.Point(22, 26);
             this.ms_makecode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ms_makecode_label.Name = "ms_makecode_label";
-            this.ms_makecode_label.Size = new System.Drawing.Size(0, 27);
+            this.ms_makecode_label.Size = new System.Drawing.Size(0, 31);
             this.ms_makecode_label.TabIndex = 61;
             // 
             // pr_detail_label
             // 
             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(733, 18);
+            this.pr_detail_label.Location = new System.Drawing.Point(825, 22);
             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(92, 27);
+            this.pr_detail_label.Size = new System.Drawing.Size(110, 31);
             this.pr_detail_label.TabIndex = 62;
             this.pr_detail_label.Text = "产品型号";
             // 
@@ -94,10 +95,10 @@
             // 
             this.ma_prodcode_label.AutoSize = true;
             this.ma_prodcode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ma_prodcode_label.Location = new System.Drawing.Point(409, 18);
+            this.ma_prodcode_label.Location = new System.Drawing.Point(460, 22);
             this.ma_prodcode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.ma_prodcode_label.Name = "ma_prodcode_label";
-            this.ma_prodcode_label.Size = new System.Drawing.Size(92, 27);
+            this.ma_prodcode_label.Size = new System.Drawing.Size(110, 31);
             this.ma_prodcode_label.TabIndex = 63;
             this.ma_prodcode_label.Text = "产品编号";
             // 
@@ -105,10 +106,10 @@
             // 
             this.sncode_label.AutoSize = true;
             this.sncode_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.sncode_label.Location = new System.Drawing.Point(23, 538);
+            this.sncode_label.Location = new System.Drawing.Point(26, 646);
             this.sncode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.sncode_label.Name = "sncode_label";
-            this.sncode_label.Size = new System.Drawing.Size(72, 27);
+            this.sncode_label.Size = new System.Drawing.Size(86, 31);
             this.sncode_label.TabIndex = 68;
             this.sncode_label.Text = "录入框";
             // 
@@ -116,10 +117,10 @@
             // 
             this.beforeTransSNLength_checkBox.AutoSize = true;
             this.beforeTransSNLength_checkBox.Font = new System.Drawing.Font("微软雅黑", 10F);
-            this.beforeTransSNLength_checkBox.Location = new System.Drawing.Point(25, 102);
+            this.beforeTransSNLength_checkBox.Location = new System.Drawing.Point(28, 122);
             this.beforeTransSNLength_checkBox.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.beforeTransSNLength_checkBox.Name = "beforeTransSNLength_checkBox";
-            this.beforeTransSNLength_checkBox.Size = new System.Drawing.Size(100, 27);
+            this.beforeTransSNLength_checkBox.Size = new System.Drawing.Size(117, 31);
             this.beforeTransSNLength_checkBox.TabIndex = 81;
             this.beforeTransSNLength_checkBox.Text = "TSN长度";
             this.beforeTransSNLength_checkBox.UseVisualStyleBackColor = true;
@@ -128,10 +129,10 @@
             // 
             this.afterTransSNLength_checkBox.AutoSize = true;
             this.afterTransSNLength_checkBox.Font = new System.Drawing.Font("微软雅黑", 10F);
-            this.afterTransSNLength_checkBox.Location = new System.Drawing.Point(25, 142);
+            this.afterTransSNLength_checkBox.Location = new System.Drawing.Point(28, 170);
             this.afterTransSNLength_checkBox.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.afterTransSNLength_checkBox.Name = "afterTransSNLength_checkBox";
-            this.afterTransSNLength_checkBox.Size = new System.Drawing.Size(90, 27);
+            this.afterTransSNLength_checkBox.Size = new System.Drawing.Size(106, 31);
             this.afterTransSNLength_checkBox.TabIndex = 82;
             this.afterTransSNLength_checkBox.Text = "SN长度";
             this.afterTransSNLength_checkBox.UseVisualStyleBackColor = true;
@@ -140,10 +141,10 @@
             // 
             this.beforeTransSNPre_checkBox.AutoSize = true;
             this.beforeTransSNPre_checkBox.Font = new System.Drawing.Font("微软雅黑", 10F);
-            this.beforeTransSNPre_checkBox.Location = new System.Drawing.Point(562, 102);
+            this.beforeTransSNPre_checkBox.Location = new System.Drawing.Point(632, 122);
             this.beforeTransSNPre_checkBox.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.beforeTransSNPre_checkBox.Name = "beforeTransSNPre_checkBox";
-            this.beforeTransSNPre_checkBox.Size = new System.Drawing.Size(100, 27);
+            this.beforeTransSNPre_checkBox.Size = new System.Drawing.Size(117, 31);
             this.beforeTransSNPre_checkBox.TabIndex = 83;
             this.beforeTransSNPre_checkBox.Text = "TSN前缀";
             this.beforeTransSNPre_checkBox.UseVisualStyleBackColor = true;
@@ -152,10 +153,10 @@
             // 
             this.afterTransSNPre_checkBox.AutoSize = true;
             this.afterTransSNPre_checkBox.Font = new System.Drawing.Font("微软雅黑", 10F);
-            this.afterTransSNPre_checkBox.Location = new System.Drawing.Point(562, 142);
+            this.afterTransSNPre_checkBox.Location = new System.Drawing.Point(632, 170);
             this.afterTransSNPre_checkBox.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.afterTransSNPre_checkBox.Name = "afterTransSNPre_checkBox";
-            this.afterTransSNPre_checkBox.Size = new System.Drawing.Size(90, 27);
+            this.afterTransSNPre_checkBox.Size = new System.Drawing.Size(106, 31);
             this.afterTransSNPre_checkBox.TabIndex = 84;
             this.afterTransSNPre_checkBox.Text = "SN前缀";
             this.afterTransSNPre_checkBox.UseVisualStyleBackColor = true;
@@ -164,9 +165,9 @@
             // 
             this.label1.AutoSize = true;
             this.label1.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.label1.Location = new System.Drawing.Point(20, 18);
+            this.label1.Location = new System.Drawing.Point(22, 22);
             this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(92, 27);
+            this.label1.Size = new System.Drawing.Size(110, 31);
             this.label1.TabIndex = 93;
             this.label1.Text = "工单编号";
             // 
@@ -174,9 +175,9 @@
             // 
             this.ma_code.AutoSize = true;
             this.ma_code.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.ma_code.Location = new System.Drawing.Point(121, 18);
+            this.ma_code.Location = new System.Drawing.Point(136, 22);
             this.ma_code.Name = "ma_code";
-            this.ma_code.Size = new System.Drawing.Size(0, 27);
+            this.ma_code.Size = new System.Drawing.Size(0, 31);
             this.ma_code.TabIndex = 95;
             this.ma_code.TextChanged += new System.EventHandler(this.ms_makecode_UserControlTextChanged);
             // 
@@ -184,9 +185,9 @@
             // 
             this.changenum.AutoSize = true;
             this.changenum.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.changenum.Location = new System.Drawing.Point(1001, 533);
+            this.changenum.Location = new System.Drawing.Point(1126, 640);
             this.changenum.Name = "changenum";
-            this.changenum.Size = new System.Drawing.Size(24, 27);
+            this.changenum.Size = new System.Drawing.Size(28, 31);
             this.changenum.TabIndex = 100;
             this.changenum.Text = "0";
             this.changenum.Visible = false;
@@ -195,18 +196,18 @@
             // 
             this.remain_qty.AutoSize = true;
             this.remain_qty.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.remain_qty.Location = new System.Drawing.Point(124, 63);
+            this.remain_qty.Location = new System.Drawing.Point(140, 76);
             this.remain_qty.Name = "remain_qty";
-            this.remain_qty.Size = new System.Drawing.Size(0, 27);
+            this.remain_qty.Size = new System.Drawing.Size(0, 31);
             this.remain_qty.TabIndex = 99;
             // 
             // PrintNum_label
             // 
             this.PrintNum_label.AutoSize = true;
             this.PrintNum_label.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.PrintNum_label.Location = new System.Drawing.Point(903, 533);
+            this.PrintNum_label.Location = new System.Drawing.Point(1016, 640);
             this.PrintNum_label.Name = "PrintNum_label";
-            this.PrintNum_label.Size = new System.Drawing.Size(52, 27);
+            this.PrintNum_label.Size = new System.Drawing.Size(62, 31);
             this.PrintNum_label.TabIndex = 98;
             this.PrintNum_label.Text = "计数";
             this.PrintNum_label.Visible = false;
@@ -215,9 +216,9 @@
             // 
             this.remain_qty_label.AutoSize = true;
             this.remain_qty_label.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.remain_qty_label.Location = new System.Drawing.Point(24, 63);
+            this.remain_qty_label.Location = new System.Drawing.Point(27, 76);
             this.remain_qty_label.Name = "remain_qty_label";
-            this.remain_qty_label.Size = new System.Drawing.Size(72, 27);
+            this.remain_qty_label.Size = new System.Drawing.Size(86, 31);
             this.remain_qty_label.TabIndex = 97;
             this.remain_qty_label.Text = "剩余数";
             // 
@@ -225,10 +226,10 @@
             // 
             this.ClearSn_code.Cursor = System.Windows.Forms.Cursors.Hand;
             this.ClearSn_code.Image = global::UAS_MES_NEW.Properties.Resources.bindingNavigatorDeleteItem_Image;
-            this.ClearSn_code.Location = new System.Drawing.Point(373, 498);
-            this.ClearSn_code.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.ClearSn_code.Location = new System.Drawing.Point(420, 598);
+            this.ClearSn_code.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.ClearSn_code.Name = "ClearSn_code";
-            this.ClearSn_code.Size = new System.Drawing.Size(21, 20);
+            this.ClearSn_code.Size = new System.Drawing.Size(24, 24);
             this.ClearSn_code.TabIndex = 141;
             this.ClearSn_code.TabStop = false;
             this.ClearSn_code.Click += new System.EventHandler(this.ReCall_Click);
@@ -237,20 +238,20 @@
             // 
             this.sn_code_label.AutoSize = true;
             this.sn_code_label.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.sn_code_label.Location = new System.Drawing.Point(23, 495);
+            this.sn_code_label.Location = new System.Drawing.Point(26, 594);
             this.sn_code_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.sn_code_label.Name = "sn_code_label";
-            this.sn_code_label.Size = new System.Drawing.Size(72, 27);
+            this.sn_code_label.Size = new System.Drawing.Size(86, 31);
             this.sn_code_label.TabIndex = 139;
             this.sn_code_label.Text = "序列号";
             // 
             // StepCount
             // 
             this.StepCount.LineCode = null;
-            this.StepCount.Location = new System.Drawing.Point(931, 142);
+            this.StepCount.Location = new System.Drawing.Point(1047, 170);
             this.StepCount.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.StepCount.Name = "StepCount";
-            this.StepCount.Size = new System.Drawing.Size(117, 28);
+            this.StepCount.Size = new System.Drawing.Size(132, 34);
             this.StepCount.Source = null;
             this.StepCount.StepCode = null;
             this.StepCount.TabIndex = 196;
@@ -260,11 +261,11 @@
             this.ChangeResult.AllPower = "ifall";
             this.ChangeResult.AutoSize = true;
             this.ChangeResult.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.ChangeResult.Location = new System.Drawing.Point(373, 533);
+            this.ChangeResult.Location = new System.Drawing.Point(420, 640);
             this.ChangeResult.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.ChangeResult.Name = "ChangeResult";
             this.ChangeResult.Power = "ifspecial";
-            this.ChangeResult.Size = new System.Drawing.Size(114, 31);
+            this.ChangeResult.Size = new System.Drawing.Size(136, 35);
             this.ChangeResult.TabIndex = 146;
             this.ChangeResult.Text = "重新转换";
             this.ChangeResult.UseVisualStyleBackColor = true;
@@ -277,11 +278,11 @@
             this.show_sncode.Enabled = false;
             this.show_sncode.Font = new System.Drawing.Font("微软雅黑", 10F);
             this.show_sncode.ID = null;
-            this.show_sncode.Location = new System.Drawing.Point(130, 495);
-            this.show_sncode.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.show_sncode.Location = new System.Drawing.Point(146, 594);
+            this.show_sncode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.show_sncode.Name = "show_sncode";
             this.show_sncode.Power = null;
-            this.show_sncode.Size = new System.Drawing.Size(212, 29);
+            this.show_sncode.Size = new System.Drawing.Size(238, 34);
             this.show_sncode.Str = null;
             this.show_sncode.Str1 = null;
             this.show_sncode.Str2 = null;
@@ -292,10 +293,10 @@
             this.pr_detail.AutoSize = true;
             this.pr_detail.CutLength = null;
             this.pr_detail.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.pr_detail.Location = new System.Drawing.Point(830, 18);
-            this.pr_detail.MaximumSize = new System.Drawing.Size(178, 0);
+            this.pr_detail.Location = new System.Drawing.Point(934, 22);
+            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.Size = new System.Drawing.Size(0, 31);
             this.pr_detail.TabIndex = 96;
             // 
             // ma_prodcode
@@ -303,30 +304,30 @@
             this.ma_prodcode.AutoSize = true;
             this.ma_prodcode.CutLength = null;
             this.ma_prodcode.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.ma_prodcode.Location = new System.Drawing.Point(512, 22);
+            this.ma_prodcode.Location = new System.Drawing.Point(576, 26);
             this.ma_prodcode.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
-            this.ma_prodcode.MaximumSize = new System.Drawing.Size(178, 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.Size = new System.Drawing.Size(0, 31);
             this.ma_prodcode.TabIndex = 94;
             // 
             // afterTransSNLength
             // 
             this.afterTransSNLength.Font = new System.Drawing.Font("微软雅黑", 10F);
-            this.afterTransSNLength.Location = new System.Drawing.Point(148, 143);
+            this.afterTransSNLength.Location = new System.Drawing.Point(166, 172);
             this.afterTransSNLength.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.afterTransSNLength.Name = "afterTransSNLength";
-            this.afterTransSNLength.Size = new System.Drawing.Size(223, 29);
+            this.afterTransSNLength.Size = new System.Drawing.Size(250, 34);
             this.afterTransSNLength.TabIndex = 90;
             this.afterTransSNLength.Text = "0";
             // 
             // beforeTransSNLength
             // 
             this.beforeTransSNLength.Font = new System.Drawing.Font("微软雅黑", 10F);
-            this.beforeTransSNLength.Location = new System.Drawing.Point(148, 102);
+            this.beforeTransSNLength.Location = new System.Drawing.Point(166, 122);
             this.beforeTransSNLength.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.beforeTransSNLength.Name = "beforeTransSNLength";
-            this.beforeTransSNLength.Size = new System.Drawing.Size(223, 29);
+            this.beforeTransSNLength.Size = new System.Drawing.Size(250, 34);
             this.beforeTransSNLength.TabIndex = 89;
             this.beforeTransSNLength.Text = "0";
             // 
@@ -336,11 +337,11 @@
             this.afterTransSNPre.BackColor = System.Drawing.Color.White;
             this.afterTransSNPre.Font = new System.Drawing.Font("微软雅黑", 10F);
             this.afterTransSNPre.ID = null;
-            this.afterTransSNPre.Location = new System.Drawing.Point(684, 142);
+            this.afterTransSNPre.Location = new System.Drawing.Point(770, 170);
             this.afterTransSNPre.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.afterTransSNPre.Name = "afterTransSNPre";
             this.afterTransSNPre.Power = null;
-            this.afterTransSNPre.Size = new System.Drawing.Size(223, 29);
+            this.afterTransSNPre.Size = new System.Drawing.Size(250, 34);
             this.afterTransSNPre.Str = null;
             this.afterTransSNPre.Str1 = null;
             this.afterTransSNPre.Str2 = null;
@@ -352,11 +353,11 @@
             this.beforeTransSNPre.BackColor = System.Drawing.Color.White;
             this.beforeTransSNPre.Font = new System.Drawing.Font("微软雅黑", 10F);
             this.beforeTransSNPre.ID = null;
-            this.beforeTransSNPre.Location = new System.Drawing.Point(684, 98);
+            this.beforeTransSNPre.Location = new System.Drawing.Point(770, 118);
             this.beforeTransSNPre.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
             this.beforeTransSNPre.Name = "beforeTransSNPre";
             this.beforeTransSNPre.Power = null;
-            this.beforeTransSNPre.Size = new System.Drawing.Size(223, 29);
+            this.beforeTransSNPre.Size = new System.Drawing.Size(250, 34);
             this.beforeTransSNPre.Str = null;
             this.beforeTransSNPre.Str1 = null;
             this.beforeTransSNPre.Str2 = null;
@@ -365,10 +366,10 @@
             // OperateResult
             // 
             this.OperateResult.Font = new System.Drawing.Font("微软雅黑", 15F);
-            this.OperateResult.Location = new System.Drawing.Point(25, 183);
-            this.OperateResult.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.OperateResult.Location = new System.Drawing.Point(28, 220);
+            this.OperateResult.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.OperateResult.Name = "OperateResult";
-            this.OperateResult.Size = new System.Drawing.Size(1081, 287);
+            this.OperateResult.Size = new System.Drawing.Size(1216, 344);
             this.OperateResult.TabIndex = 78;
             this.OperateResult.Text = "";
             // 
@@ -378,11 +379,11 @@
             this.sncode.BackColor = System.Drawing.Color.White;
             this.sncode.Font = new System.Drawing.Font("微软雅黑", 10F);
             this.sncode.ID = null;
-            this.sncode.Location = new System.Drawing.Point(130, 537);
-            this.sncode.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.sncode.Location = new System.Drawing.Point(146, 644);
+            this.sncode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.sncode.Name = "sncode";
             this.sncode.Power = "ifread";
-            this.sncode.Size = new System.Drawing.Size(212, 29);
+            this.sncode.Size = new System.Drawing.Size(238, 34);
             this.sncode.Str = null;
             this.sncode.Str1 = null;
             this.sncode.Str2 = null;
@@ -395,12 +396,12 @@
             this.Remark.AllPower = null;
             this.Remark.BackColor = System.Drawing.Color.White;
             this.Remark.ID = null;
-            this.Remark.Location = new System.Drawing.Point(619, 480);
-            this.Remark.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.Remark.Location = new System.Drawing.Point(696, 576);
+            this.Remark.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.Remark.Multiline = true;
             this.Remark.Name = "Remark";
             this.Remark.Power = null;
-            this.Remark.Size = new System.Drawing.Size(210, 62);
+            this.Remark.Size = new System.Drawing.Size(236, 74);
             this.Remark.Str = null;
             this.Remark.Str1 = null;
             this.Remark.Str2 = null;
@@ -415,11 +416,11 @@
             this.Seq_Remark_PreFix.AllPower = null;
             this.Seq_Remark_PreFix.BackColor = System.Drawing.Color.White;
             this.Seq_Remark_PreFix.ID = null;
-            this.Seq_Remark_PreFix.Location = new System.Drawing.Point(552, 510);
-            this.Seq_Remark_PreFix.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.Seq_Remark_PreFix.Location = new System.Drawing.Point(621, 612);
+            this.Seq_Remark_PreFix.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.Seq_Remark_PreFix.Name = "Seq_Remark_PreFix";
             this.Seq_Remark_PreFix.Power = null;
-            this.Seq_Remark_PreFix.Size = new System.Drawing.Size(57, 25);
+            this.Seq_Remark_PreFix.Size = new System.Drawing.Size(64, 28);
             this.Seq_Remark_PreFix.Str = null;
             this.Seq_Remark_PreFix.Str1 = null;
             this.Seq_Remark_PreFix.Str2 = null;
@@ -430,10 +431,10 @@
             // SameReamrk
             // 
             this.SameReamrk.AutoSize = true;
-            this.SameReamrk.Location = new System.Drawing.Point(619, 550);
-            this.SameReamrk.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.SameReamrk.Location = new System.Drawing.Point(696, 660);
+            this.SameReamrk.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.SameReamrk.Name = "SameReamrk";
-            this.SameReamrk.Size = new System.Drawing.Size(119, 19);
+            this.SameReamrk.Size = new System.Drawing.Size(142, 22);
             this.SameReamrk.TabIndex = 224;
             this.SameReamrk.Text = "固定录入备注";
             this.SameReamrk.UseVisualStyleBackColor = true;
@@ -444,10 +445,10 @@
             // 
             this.label3.AutoSize = true;
             this.label3.Font = new System.Drawing.Font("微软雅黑", 10.5F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label3.Location = new System.Drawing.Point(494, 512);
+            this.label3.Location = new System.Drawing.Point(556, 614);
             this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label3.Name = "label3";
-            this.label3.Size = new System.Drawing.Size(46, 24);
+            this.label3.Size = new System.Drawing.Size(54, 28);
             this.label3.TabIndex = 223;
             this.label3.Text = "前缀";
             this.label3.Visible = false;
@@ -455,10 +456,10 @@
             // IFONLY
             // 
             this.IFONLY.AutoSize = true;
-            this.IFONLY.Location = new System.Drawing.Point(499, 550);
-            this.IFONLY.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.IFONLY.Location = new System.Drawing.Point(561, 660);
+            this.IFONLY.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.IFONLY.Name = "IFONLY";
-            this.IFONLY.Size = new System.Drawing.Size(104, 19);
+            this.IFONLY.Size = new System.Drawing.Size(124, 22);
             this.IFONLY.TabIndex = 222;
             this.IFONLY.Text = "不允许重复";
             this.IFONLY.UseVisualStyleBackColor = true;
@@ -469,10 +470,10 @@
             // 
             this.CollectRemark.AutoSize = true;
             this.CollectRemark.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.CollectRemark.Location = new System.Drawing.Point(755, 550);
-            this.CollectRemark.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.CollectRemark.Location = new System.Drawing.Point(849, 660);
+            this.CollectRemark.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.CollectRemark.Name = "CollectRemark";
-            this.CollectRemark.Size = new System.Drawing.Size(89, 19);
+            this.CollectRemark.Size = new System.Drawing.Size(106, 22);
             this.CollectRemark.TabIndex = 221;
             this.CollectRemark.Text = "采集备注";
             this.CollectRemark.UseVisualStyleBackColor = true;
@@ -483,37 +484,38 @@
             // 
             this.label4.AutoSize = true;
             this.label4.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.label4.Location = new System.Drawing.Point(733, 63);
+            this.label4.Location = new System.Drawing.Point(825, 76);
             this.label4.Name = "label4";
-            this.label4.Size = new System.Drawing.Size(72, 27);
+            this.label4.Size = new System.Drawing.Size(110, 31);
             this.label4.TabIndex = 227;
-            this.label4.Text = "合同号";
+            this.label4.Text = "客户代码";
             // 
             // ma_salecode
             // 
             this.ma_salecode.AutoSize = true;
             this.ma_salecode.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.ma_salecode.Location = new System.Drawing.Point(832, 63);
+            this.ma_salecode.Location = new System.Drawing.Point(1078, 292);
             this.ma_salecode.Name = "ma_salecode";
-            this.ma_salecode.Size = new System.Drawing.Size(0, 27);
+            this.ma_salecode.Size = new System.Drawing.Size(0, 31);
             this.ma_salecode.TabIndex = 228;
+            this.ma_salecode.Visible = false;
             // 
             // mcd_inqty
             // 
             this.mcd_inqty.AutoSize = true;
             this.mcd_inqty.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.mcd_inqty.Location = new System.Drawing.Point(509, 63);
+            this.mcd_inqty.Location = new System.Drawing.Point(573, 76);
             this.mcd_inqty.Name = "mcd_inqty";
-            this.mcd_inqty.Size = new System.Drawing.Size(0, 27);
+            this.mcd_inqty.Size = new System.Drawing.Size(0, 31);
             this.mcd_inqty.TabIndex = 230;
             // 
             // label5
             // 
             this.label5.AutoSize = true;
             this.label5.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.label5.Location = new System.Drawing.Point(409, 63);
+            this.label5.Location = new System.Drawing.Point(460, 76);
             this.label5.Name = "label5";
-            this.label5.Size = new System.Drawing.Size(72, 27);
+            this.label5.Size = new System.Drawing.Size(86, 31);
             this.label5.TabIndex = 229;
             this.label5.Text = "采集数";
             // 
@@ -524,19 +526,29 @@
             this.checkBox1.CheckState = System.Windows.Forms.CheckState.Checked;
             this.checkBox1.Enabled = false;
             this.checkBox1.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.checkBox1.Location = new System.Drawing.Point(908, 499);
-            this.checkBox1.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.checkBox1.Location = new System.Drawing.Point(1022, 599);
+            this.checkBox1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.checkBox1.Name = "checkBox1";
-            this.checkBox1.Size = new System.Drawing.Size(89, 19);
+            this.checkBox1.Size = new System.Drawing.Size(106, 22);
             this.checkBox1.TabIndex = 231;
             this.checkBox1.Text = "直接完工";
             this.checkBox1.UseVisualStyleBackColor = true;
             // 
+            // ma_endremark
+            // 
+            this.ma_endremark.AutoSize = true;
+            this.ma_endremark.Font = new System.Drawing.Font("微软雅黑", 12F);
+            this.ma_endremark.Location = new System.Drawing.Point(935, 76);
+            this.ma_endremark.Name = "ma_endremark";
+            this.ma_endremark.Size = new System.Drawing.Size(0, 31);
+            this.ma_endremark.TabIndex = 232;
+            // 
             // Make_SeqTransform2
             // 
-            this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
+            this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.ClientSize = new System.Drawing.Size(1132, 583);
+            this.ClientSize = new System.Drawing.Size(1274, 700);
+            this.Controls.Add(this.ma_endremark);
             this.Controls.Add(this.checkBox1);
             this.Controls.Add(this.mcd_inqty);
             this.Controls.Add(this.label5);
@@ -576,7 +588,7 @@
             this.Controls.Add(this.pr_detail_label);
             this.Controls.Add(this.ma_prodcode_label);
             this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
-            this.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.Name = "Make_SeqTransform2";
             this.Tag = "Make!SeqTransform2";
             this.Text = " ";
@@ -627,5 +639,6 @@
         private System.Windows.Forms.Label mcd_inqty;
         private System.Windows.Forms.Label label5;
         private System.Windows.Forms.CheckBox checkBox1;
+        private System.Windows.Forms.Label ma_endremark;
     }
 }

+ 1 - 1
UAS_MES_ZT/FunctionCode/Make/Make_SeqTransform2.cs

@@ -135,7 +135,7 @@ namespace UAS_MES_NEW.Make
                             {
                                 //按照out出的工单号查出工单相关信息,并赋值到相关控件
                                 sql.Clear();
-                                sql.Append("select ma_code,ma_softversion,ma_prodcode,pr_orispeccode pr_detail,ma_salecode,ma_qty,ma_qty-mcd_inqty as remain_qty ");
+                                sql.Append("select ma_code,ma_softversion,ma_prodcode,pr_orispeccode pr_detail,ma_endremark,ma_salecode,ma_qty,ma_qty-mcd_inqty as remain_qty ");
                                 sql.Append("from makeserial left join make on ms_makecode=ma_code left join product on ");
                                 sql.Append("ms_prodcode=pr_code left join makecraftdetail_view on ms_makecode=mcd_macode where ms_id='" + oMsId + "' and mcd_stepcode='" + User.CurrentStepCode + "'");
                                 dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");

File diff ditekan karena terlalu besar
+ 237 - 174
UAS_MES_ZT/FunctionCode/Make/Make_TestCollection.Designer.cs


+ 89 - 24
UAS_MES_ZT/FunctionCode/Make/Make_TestCollection.cs

@@ -83,9 +83,9 @@ namespace UAS_MES_NEW.Make
 
             //工单号放大镜配置
             ma_code.TableName = "make left join product on ma_prodcode=pr_code";
-            ma_code.SelectField = "ma_code # 工单号,ma_prodcode # 产品编号,ma_qty # 工单数量, pr_orispeccode # 型号, ma_wccode # 车间,ma_inqty # 投入数,pr_spec # 产品规格";
+            ma_code.SelectField = "ma_code # 工单号,ma_prodcode # 产品编号,ma_qty # 工单数量, pr_orispeccode # 型号, ma_wccode # 车间,ma_inqty # 投入数,pr_spec # 产品规格,ma_endremark # 客户代码";
             ma_code.FormName = Name;
-            ma_code.SetValueField = new string[] { "ma_code", "ma_prodcode", "ma_qty", "pr_orispeccode pr_spec"};
+            ma_code.SetValueField = new string[] { "ma_code", "ma_prodcode", "ma_qty", "pr_orispeccode pr_spec", "ma_endremark" };
             ma_code.Condition = "ma_statuscode='STARTED' order by ma_date desc";
             ma_code.DbChange += Ma_code_DbChange;
             dh = SystemInf.dh;
@@ -241,7 +241,7 @@ namespace UAS_MES_NEW.Make
                         }
                         if (ma_code.Text != oMakeCode && oMakeCode != null)
                         {
-                            dt = (DataTable)dh.ExecuteSql("select ma_code,ma_prodcode,ma_softversion,ma_salecode,pr_orispeccode pr_spec,nvl(pr_sendchecktype,'LineCode')pr_sendchecktype,ma_qty from make left join product on ma_prodcode=pr_code where ma_code='" + oMakeCode + "'", "select");
+                            dt = (DataTable)dh.ExecuteSql("select ma_code,ma_prodcode,ma_softversion,ma_salecode,pr_orispeccode pr_spec,nvl(pr_sendchecktype,'LineCode')pr_sendchecktype,ma_qty,ma_endremark from make left join product on ma_prodcode=pr_code where ma_code='" + oMakeCode + "'", "select");
                             if (dt.Rows.Count > 0)
                             {
                                 BaseUtil.SetFormValue(this.Controls, dt);
@@ -281,9 +281,9 @@ namespace UAS_MES_NEW.Make
                         }
                         SetCollectResult();
                     }
-                    else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode,biduisn);
+                    else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode, oth);
                 }
-                else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode, biduisn);
+                else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode, oth);
             }
         }
 
@@ -424,21 +424,58 @@ namespace UAS_MES_NEW.Make
                     }
                     else
                     {
-                        if (AutoBadCode.Checked)
+                        //if (AutoBadCode.Checked)
+                        //{
+                        //    string str = BaseUtil.GetDataFromDevice("DEVICES");
+                        //    str = str.Replace("LIST OF DEVICES ATTACHED", "").Replace("\n", "");
+                        //    if (!(str.Length == 0))
+                        //    {
+                        //        Console.WriteLine("有链接");
+                        //        BaseUtil.GetDataFromDevice("RESET");
+                        //    }
+                        //    else
+                        //    {
+                        //        OperateResult.AppendText(">>无设备链接,无法恢复出厂设置,采集失败\n", Color.Red, ms_sncode);
+                        //        return;
+                        //    }
+                        //}
+
+                        if (khcheck.Checked)
                         {
-                            string str = BaseUtil.GetDataFromDevice("DEVICES");
-                            str = str.Replace("LIST OF DEVICES ATTACHED", "").Replace("\n", "");
-                            if (!(str.Length == 0))
+
+                            String priex = dh.getFieldDataByCondition("product", "pr_usetype", "pr_code = '" + ma_prodcode.Text + "'").ToString();
+                            if (priex == "")
                             {
-                                Console.WriteLine("有链接");
-                                BaseUtil.GetDataFromDevice("RESET");
+                                OperateResult.AppendText(">>产品编号" + ma_prodcode.Text + "未维护客户码防呆要求\n", Color.Red, ms_sncode);
+                                return;
                             }
-                            else
+
+                            string[] pres = priex.Split('|');
+                            bool f = false;
+                            for (int i = 0; i < pres.Length; i++)
                             {
-                                OperateResult.AppendText(">>无设备链接,无法恢复出厂设置,采集失败\n", Color.Red, ms_sncode);
+                                if (pres[i] == "" ? true : oth.Text.Contains(pres[i]))
+                                {
+                                    //满足其中一条即可
+                                    f = true;
+                                    break;
+                                }
+                            }
+                            if (!f)
+                            {
+                                OperateResult.AppendText(">>客户码" + oth.Text + "不符合防呆要求\n", Color.Red, oth);
+                                oth.Focus();
+                                oth.SelectAll();
                                 return;
                             }
                         }
+                        else
+                        {
+                            if (oth.Text != "")
+                            {
+                                OperateResult.AppendText(">>客户码" + oth.Text + "不需要采集\n", Color.Black, oth);
+                            }
+                        }
                         //良品信息采集
                         if (LogicHandler.SetStepResult(ma_code.Text, User.UserSourceCode, ms_sncode.Text, "良品采集", "检测合格", biduisn.Text==""?User.UserCode: biduisn.Text, out ErrorMessage))
                         {
@@ -453,18 +490,24 @@ namespace UAS_MES_NEW.Make
                             ////恢复出厂设置
                             //if (AutoBadCode.Checked)
                             //    BaseUtil.GetDataFromDevice("RESET");
+                            if (oth.Text != "")
+                            {
+                                dh.ExecuteSql(" update makeserial set MS_OTHCODE1 = '"+oth.Text+"' where ms_sncode = '"+ms_sncode.Text+"' ", "update");
+                            }
                             LastSncode = ms_sncode.Text;
                             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.BackColor = Color.Green;
-                            OperateResult.AppendText(">>" + ms_sncode.Text + "良品采集成功\n", Color.Green, ms_sncode, biduisn);
-                            //if (bidui.Checked)
-                            //    biduisn.Focus();
+                            OperateResult.AppendText(">>" + ms_sncode.Text + "良品采集成功\n", Color.Green, ms_sncode, oth);
+                            if (khcheck.Checked)
+                            {
+                                oth.Focus();
+                            }
                             //记录操作日志
-                         
+
                         }
-                        else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode, biduisn);
+                        else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode, oth);
                     }
                 }
                 else
@@ -477,11 +520,11 @@ namespace UAS_MES_NEW.Make
                             if (ErrorMessage.Contains("AFTERSUCCESS"))
                                 OperateResult.AppendText(">>" + ErrorMessage + "\n");
                             LastSncode = ms_sncode.Text;
-                            OperateResult.AppendText(">>" + ms_sncode.Text + "成功采集为良品\n", Color.Green, ms_sncode, biduisn);
+                            OperateResult.AppendText(">>" + ms_sncode.Text + "成功采集为良品\n", Color.Green, ms_sncode, oth);
                             //记录操作日志
                             LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ma_code.Text, User.UserLineCode, User.UserSourceCode, "采集良品", "采集良品成功", LastSncode, ob_checkno.Text);
                         }
-                        else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode, biduisn);
+                        else OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode, oth);
                     }
                     else
                     {
@@ -655,10 +698,7 @@ namespace UAS_MES_NEW.Make
                     //清除不良信息
                     bc_code.Text = "";
                     biduisn.Text = "";
-                    if (bidui.Checked)
-                    {
-                        biduisn.Focus();
-                    }
+                    oth.Text = "";
                     ChoosedRejectList.Items.Clear();
                     LoadCollectedNum();
                     WaitList.Clear();
@@ -773,6 +813,10 @@ namespace UAS_MES_NEW.Make
             {
                 ms_sncode.Focus();
             }
+            if (khcheck.Checked&& GoodProduct.Checked)
+            {
+                oth.Focus();
+            }
         }
 
         private void SendCheck_Click(object sender, EventArgs e)
@@ -829,9 +873,18 @@ namespace UAS_MES_NEW.Make
             dh.Dispose();
         }
 
+     
+
         private void ma_prodcode_TextChanged(object sender, EventArgs e)
         {
             LoadBadGroupData();
+            if (dh.CheckExist("product", "pr_code = '" + ma_prodcode.Text + "' and pr_trydays = -1")&&dh.CheckExist("step","st_code = '"+User.CurrentStepCode+ "' and st_ifspc = -1"))
+            {
+                khcheck.Checked = true;
+            }else
+                {
+                khcheck.Checked = false;
+            }
         }
 
         private void Filter_UserControlTextChanged(object sender, EventArgs e)
@@ -1117,5 +1170,17 @@ namespace UAS_MES_NEW.Make
                 bc_code.Clear();
             }
         }
+
+        private void oth_KeyDown(object sender, KeyEventArgs e)
+        {
+            if (e.KeyCode == Keys.Enter)
+            {
+                if (oth.Text != "")
+                {
+                    ms_sncode.Focus();
+                    ms_sncode.SelectAll();
+                }
+            }
+        }
     }
 }

+ 1 - 1
UAS_MES_ZT/FunctionCode/Make/Make_TestCollection.resx

@@ -300,7 +300,7 @@
         RudN65tdA8sHzg46DF645Xrr8m2v29fvrLwzMBQydHc4cnjkLvvu5L2key/vZ9yff7DpIfph4SOpR+WP
         lR7X/aj3Y+uI5ciZUdfRvidBTx6Mscae/5T+04fx/Kfkp+UTqhONk2aTp6fcp24+W/1s/Hnq8/npgp+l
         f65+ofviu18cf+mbWTUz/pL/cuHX4lfyr468Xva6e9Z/9vGb5Dfzc4Vv5d8efcd41/s+7P3EfOYH7IeK
-        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALEgAACxIB0t1+/AAACfBJREFUeF7t3dtuFFcC
+        j3ofuz55f3q4kLyw8Bv3hPP74uYdwgAAAAlwSFlzAAALDgAACw4BQL7hQQAACfBJREFUeF7t3dtuFFcC
         heFc5VWQRsrL5T0iRcrDkJAjJOADNjbdbvD5iE9tu302RIq0Z6+ynWkmS6oZrlys/+KT8FJX3f2bcmPa
         X5RSAISyI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0BZLAjgAx2BJDBjgAy2BFABjsCyGBHABnsCCCD
         HQFksCOADHYEkMGOADLYEUAGOwLIYEcAGewIIIMdAWSwI4AMdgSQwY4AMtgRQAY7AshgRwAZ7Agggx0B

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

@@ -378,12 +378,13 @@ namespace UAS_MES_NEW.OQC
                         string ngqty = (dh.ExecuteSql(sql.GetString(), "select") as DataTable).Rows[0][0].ToString();
                         string checkqty = dh.getFieldDataByCondition("OQCItems", "max(oi_checkqty)", "oi_checkno ='" + ob_checkno.Text + "'").ToString();
                         dh.ExecuteSql("update OQCBATCH set ob_ngqty='" + ngqty + "',ob_actsampleqty='" + checkqty + "',ob_okqty=('" + checkqty + "'-'" + ngqty + "') where ob_checkno ='" + ob_checkno.Text + "'", "update");
+                        string endremark = dh.getFieldDataByCondition("makeserial", "ms_endremark", "ms_sncode = '"+sncode.Text+"' and ms_checkno = '"+ob_checkno.Text+"' ").ToString();
                         if (!IfContainNG)
                         {
-                            OperateResult.AppendText(">>序列号" + sncode.Text + "抽样良品\n", Color.Green);
+                            OperateResult.AppendText(">>序列号" + sncode.Text + ",客户代码:"+endremark+",抽样良品\n", Color.Green);
                         }
                         else {
-                            OperateResult.AppendText(">>序列号" + sncode.Text + "抽样不良\n", Color.OrangeRed);
+                            OperateResult.AppendText(">>序列号" + sncode.Text + ",客户代码:"+endremark+"抽样不良\n", Color.OrangeRed);
                         }
                         LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, "", User.UserLineCode, User.UserSourceCode, "抽样数据采集", "检验项目采集成功", sncode.Text, ob_checkno.Text);
                         dh.ExecuteSql("update oqcbatchdetail set obd_ifcheck = '-1',obd_checkdate = sysdate where obd_checkno='" + ob_checkno.Text + "' and obd_sncode='" + sncode.Text + "'", "update");

+ 35 - 1
UAS_MES_ZT/FunctionCode/Packing/Packing_PackageCollection.Designer.cs

@@ -106,6 +106,8 @@
             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.pa_endremark = new System.Windows.Forms.Label();
+            this.ms_endremark = new System.Windows.Forms.Label();
             ((System.ComponentModel.ISupportInitialize)(this.PackageDetail)).BeginInit();
             this.SuspendLayout();
             // 
@@ -474,7 +476,7 @@
             // StepCount
             // 
             this.StepCount.LineCode = null;
-            this.StepCount.Location = new System.Drawing.Point(833, 33);
+            this.StepCount.Location = new System.Drawing.Point(913, 36);
             this.StepCount.Margin = new System.Windows.Forms.Padding(3, 6, 3, 6);
             this.StepCount.Name = "StepCount";
             this.StepCount.Size = new System.Drawing.Size(60, 20);
@@ -615,6 +617,7 @@
             // 
             this.AutoPrint.Checked = false;
             this.AutoPrint.Location = new System.Drawing.Point(774, 202);
+            this.AutoPrint.Margin = new System.Windows.Forms.Padding(3, 4, 3, 4);
             this.AutoPrint.Name = "AutoPrint";
             this.AutoPrint.Size = new System.Drawing.Size(167, 35);
             this.AutoPrint.TabIndex = 166;
@@ -1002,6 +1005,7 @@
             this.PackageDetail.Margin = new System.Windows.Forms.Padding(4);
             this.PackageDetail.Name = "PackageDetail";
             this.PackageDetail.ReadOnly = true;
+            this.PackageDetail.RowHeadersWidth = 62;
             this.PackageDetail.RowTemplate.Height = 23;
             this.PackageDetail.Size = new System.Drawing.Size(1293, 360);
             this.PackageDetail.TabIndex = 134;
@@ -1030,14 +1034,17 @@
             // 
             this.pa_prodcode1.DataPropertyName = "pa_prodcode";
             this.pa_prodcode1.HeaderText = "产品编号";
+            this.pa_prodcode1.MinimumWidth = 8;
             this.pa_prodcode1.Name = "pa_prodcode1";
             this.pa_prodcode1.ReadOnly = true;
             this.pa_prodcode1.Visible = false;
+            this.pa_prodcode1.Width = 150;
             // 
             // pd_innerqty
             // 
             this.pd_innerqty.DataPropertyName = "pd_innerqty";
             this.pd_innerqty.HeaderText = "箱内数量";
+            this.pd_innerqty.MinimumWidth = 8;
             this.pd_innerqty.Name = "pd_innerqty";
             this.pd_innerqty.ReadOnly = true;
             this.pd_innerqty.Visible = false;
@@ -1057,9 +1064,32 @@
             // 
             this.pd_id.DataPropertyName = "pd_id";
             this.pd_id.HeaderText = "ID";
+            this.pd_id.MinimumWidth = 8;
             this.pd_id.Name = "pd_id";
             this.pd_id.ReadOnly = true;
             this.pd_id.Visible = false;
+            this.pd_id.Width = 150;
+            // 
+            // pa_endremark
+            // 
+            this.pa_endremark.AutoSize = true;
+            this.pa_endremark.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.pa_endremark.Location = new System.Drawing.Point(667, 479);
+            this.pa_endremark.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pa_endremark.Name = "pa_endremark";
+            this.pa_endremark.Size = new System.Drawing.Size(0, 31);
+            this.pa_endremark.TabIndex = 211;
+            this.pa_endremark.Visible = false;
+            // 
+            // ms_endremark
+            // 
+            this.ms_endremark.AutoSize = true;
+            this.ms_endremark.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.ms_endremark.Location = new System.Drawing.Point(667, 27);
+            this.ms_endremark.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ms_endremark.Name = "ms_endremark";
+            this.ms_endremark.Size = new System.Drawing.Size(0, 31);
+            this.ms_endremark.TabIndex = 212;
             // 
             // Packing_PackageCollection
             // 
@@ -1067,6 +1097,8 @@
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch;
             this.ClientSize = new System.Drawing.Size(1334, 988);
+            this.Controls.Add(this.ms_endremark);
+            this.Controls.Add(this.pa_endremark);
             this.Controls.Add(this.locksalecode);
             this.Controls.Add(this.PrintNum);
             this.Controls.Add(this.PreFix_label);
@@ -1230,5 +1262,7 @@
         private System.Windows.Forms.CheckBox AllowRepeat;
         private System.Windows.Forms.Label label2;
         private CustomControl.TextBoxWithIcon.SnCollectionBox Remark_PreFix;
+        private System.Windows.Forms.Label pa_endremark;
+        private System.Windows.Forms.Label ms_endremark;
     }
 }

+ 13 - 12
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||'-'||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("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,pa_endremark 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)
@@ -250,7 +250,7 @@ namespace UAS_MES_NEW.Packing
                         //获取序列号信息
                         sql.Clear();
                         sql.Append("select nvl(ms_iostatus,0) ms_iostatus,pa_salecode,ms_salecode,ms_outno,ms_makecode,ms_prodcode,nvl(pa_downstatus,0) pa_downstatus,pa_sccode,pa_checkno,pr_packrule,");
-                        sql.Append("nvl(pr_outboxinnerqty,0)pr_outboxinnerqty,nvl(pr_sendchecktype,'LineCode')pr_sendchecktype,pr_code from makeserial left join product on ms_prodcode=pr_code left join packagedetail ");
+                        sql.Append("nvl(pr_outboxinnerqty,0)pr_outboxinnerqty,nvl(pr_sendchecktype,'LineCode')pr_sendchecktype,pr_code,ms_endremark from makeserial left join product on ms_prodcode=pr_code left join packagedetail ");
                         sql.Append("on pd_barcode=ms_sncode left join package on pa_id =pd_paid where ms_id='" + oMsID + "'");
                         dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
                         string ms_makecode = "";
@@ -266,15 +266,16 @@ namespace UAS_MES_NEW.Packing
                             ms_iostatus = dt.Rows[0]["ms_iostatus"].ToString();
                             ms_outno = dt.Rows[0]["ms_outno"].ToString();
                             ms_salecode_text = dt.Rows[0]["ms_salecode"].ToString();
-                            if (locksalecode.Checked && ms_salecode.Text != "" && ms_salecode.Text != ms_salecode_text)
-                            {
-                                OperateResult.AppendText(">>序列号" + sn_code.Text + "所属订单号" + ms_salecode_text + "与界面订单号" + ms_salecode.Text + "不同,无法采集\n", Color.Red, sn_code);
-                                if (md.IsOpen)
-                                {
-                                    md.SendOrder("M502_ON");
-                                }
-                                return;
-                            }
+                            //if (locksalecode.Checked && ms_salecode.Text != "" && ms_salecode.Text != ms_salecode_text)
+                            //{
+                            //    OperateResult.AppendText(">>序列号" + sn_code.Text + "所属订单号" + ms_salecode_text + "与界面订单号" + ms_salecode.Text + "不同,无法采集\n", Color.Red, sn_code);
+                            //    if (md.IsOpen)
+                            //    {
+                            //        md.SendOrder("M502_ON");
+                            //    }
+                            //    return;
+                            //}
+
                             BaseUtil.SetFormValue(this.Controls, dt);
                         }
                         if (dt.Rows[0]["ms_outno"].ToString() != "")
@@ -867,7 +868,7 @@ namespace UAS_MES_NEW.Packing
                                 //删除箱的明细
                                 dh.ExecuteSql("delete from packagedetail where pd_outboxcode='" + pa_outboxcode.Text + "'", "delete");
                                 LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, pa_makecode.Text, User.UserLineCode, User.UserSourceCode, "卡通箱拆解", "成功", pa_outboxcode.Text, ob_checkno.Text);
-                                OperateResult.AppendText(">>箱号" + pa_outboxcode.Text + "成功拆解!\n", Color.Green);
+                                OperateResult.AppendText(">>箱号" + pa_outboxcode.Text + "成功拆解!\n", Color.Green, pa_outboxcode);
                                 LoadGridData();
                                 LoadCheckQTY();
                             }

+ 54 - 6
UAS_MES_ZT/FunctionCode/Query/Query_ExeProgress.Designer.cs

@@ -73,6 +73,8 @@
             this.pictureBox3 = new System.Windows.Forms.PictureBox();
             this.label2 = new System.Windows.Forms.Label();
             this.label3 = new System.Windows.Forms.Label();
+            this.ms_endremark = new System.Windows.Forms.TextBox();
+            this.label10 = new System.Windows.Forms.Label();
             ((System.ComponentModel.ISupportInitialize)(this.CraftmaterialData)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.CraftInfDgv)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox4)).BeginInit();
@@ -263,6 +265,7 @@
             this.CraftmaterialData.EnableContentClick = true;
             this.CraftmaterialData.Location = new System.Drawing.Point(18, 330);
             this.CraftmaterialData.Name = "CraftmaterialData";
+            this.CraftmaterialData.RowHeadersWidth = 62;
             this.CraftmaterialData.RowTemplate.Height = 27;
             this.CraftmaterialData.Size = new System.Drawing.Size(1422, 167);
             this.CraftmaterialData.TabIndex = 201;
@@ -271,6 +274,7 @@
             // 
             this.dataGridViewTextBoxColumn1.DataPropertyName = "cm_makecode";
             this.dataGridViewTextBoxColumn1.HeaderText = "工单号";
+            this.dataGridViewTextBoxColumn1.MinimumWidth = 8;
             this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
             this.dataGridViewTextBoxColumn1.Width = 120;
             // 
@@ -278,6 +282,7 @@
             // 
             this.dataGridViewTextBoxColumn2.DataPropertyName = "cm_soncode";
             this.dataGridViewTextBoxColumn2.HeaderText = "子件编号";
+            this.dataGridViewTextBoxColumn2.MinimumWidth = 8;
             this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
             this.dataGridViewTextBoxColumn2.Width = 120;
             // 
@@ -285,6 +290,7 @@
             // 
             this.dataGridViewTextBoxColumn3.DataPropertyName = "pr_detail";
             this.dataGridViewTextBoxColumn3.HeaderText = "子件名称";
+            this.dataGridViewTextBoxColumn3.MinimumWidth = 8;
             this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
             this.dataGridViewTextBoxColumn3.Width = 120;
             // 
@@ -292,6 +298,7 @@
             // 
             this.dataGridViewTextBoxColumn4.DataPropertyName = "cm_barcode";
             this.dataGridViewTextBoxColumn4.HeaderText = "子件批次号";
+            this.dataGridViewTextBoxColumn4.MinimumWidth = 8;
             this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4";
             this.dataGridViewTextBoxColumn4.Width = 120;
             // 
@@ -299,6 +306,7 @@
             // 
             this.dataGridViewTextBoxColumn5.DataPropertyName = "cm_stepcode";
             this.dataGridViewTextBoxColumn5.HeaderText = "工序编号";
+            this.dataGridViewTextBoxColumn5.MinimumWidth = 8;
             this.dataGridViewTextBoxColumn5.Name = "dataGridViewTextBoxColumn5";
             this.dataGridViewTextBoxColumn5.Width = 130;
             // 
@@ -306,6 +314,7 @@
             // 
             this.dataGridViewTextBoxColumn6.DataPropertyName = "cm_stepname";
             this.dataGridViewTextBoxColumn6.HeaderText = "工序名称";
+            this.dataGridViewTextBoxColumn6.MinimumWidth = 8;
             this.dataGridViewTextBoxColumn6.Name = "dataGridViewTextBoxColumn6";
             this.dataGridViewTextBoxColumn6.Width = 120;
             // 
@@ -313,6 +322,7 @@
             // 
             this.dataGridViewTextBoxColumn7.DataPropertyName = "cm_status";
             this.dataGridViewTextBoxColumn7.HeaderText = "上料状态";
+            this.dataGridViewTextBoxColumn7.MinimumWidth = 8;
             this.dataGridViewTextBoxColumn7.Name = "dataGridViewTextBoxColumn7";
             this.dataGridViewTextBoxColumn7.Width = 120;
             // 
@@ -320,6 +330,7 @@
             // 
             this.dataGridViewTextBoxColumn8.DataPropertyName = "cm_indate";
             this.dataGridViewTextBoxColumn8.HeaderText = "上料时间";
+            this.dataGridViewTextBoxColumn8.MinimumWidth = 8;
             this.dataGridViewTextBoxColumn8.Name = "dataGridViewTextBoxColumn8";
             this.dataGridViewTextBoxColumn8.Width = 120;
             // 
@@ -342,6 +353,7 @@
             this.CraftInfDgv.EnableContentClick = true;
             this.CraftInfDgv.Location = new System.Drawing.Point(18, 503);
             this.CraftInfDgv.Name = "CraftInfDgv";
+            this.CraftInfDgv.RowHeadersWidth = 62;
             this.CraftInfDgv.RowTemplate.Height = 27;
             this.CraftInfDgv.Size = new System.Drawing.Size(1436, 234);
             this.CraftInfDgv.TabIndex = 193;
@@ -350,6 +362,7 @@
             // 
             this.mp_sncode.DataPropertyName = "mp_sncode";
             this.mp_sncode.HeaderText = "序列号";
+            this.mp_sncode.MinimumWidth = 8;
             this.mp_sncode.Name = "mp_sncode";
             this.mp_sncode.Width = 120;
             // 
@@ -357,6 +370,7 @@
             // 
             this.mp_makecode.DataPropertyName = "mp_makecode";
             this.mp_makecode.HeaderText = "工单代码";
+            this.mp_makecode.MinimumWidth = 8;
             this.mp_makecode.Name = "mp_makecode";
             this.mp_makecode.Width = 120;
             // 
@@ -364,6 +378,7 @@
             // 
             this.ma_prodcode.DataPropertyName = "ma_prodcode";
             this.ma_prodcode.HeaderText = "产品代码";
+            this.ma_prodcode.MinimumWidth = 8;
             this.ma_prodcode.Name = "ma_prodcode";
             this.ma_prodcode.Width = 80;
             // 
@@ -371,6 +386,7 @@
             // 
             this.mp_sourcecode.DataPropertyName = "mp_sourcecode";
             this.mp_sourcecode.HeaderText = "资源编号";
+            this.mp_sourcecode.MinimumWidth = 8;
             this.mp_sourcecode.Name = "mp_sourcecode";
             this.mp_sourcecode.Width = 120;
             // 
@@ -378,6 +394,7 @@
             // 
             this.mp_stepname.DataPropertyName = "mp_stepname";
             this.mp_stepname.HeaderText = "工序名称";
+            this.mp_stepname.MinimumWidth = 8;
             this.mp_stepname.Name = "mp_stepname";
             this.mp_stepname.Width = 130;
             // 
@@ -385,6 +402,7 @@
             // 
             this.mp_indate.DataPropertyName = "mp_indate";
             this.mp_indate.HeaderText = "过站时间";
+            this.mp_indate.MinimumWidth = 8;
             this.mp_indate.Name = "mp_indate";
             this.mp_indate.Width = 120;
             // 
@@ -392,6 +410,7 @@
             // 
             this.ma_craftcode.DataPropertyName = "ma_craftcode";
             this.ma_craftcode.HeaderText = "途程代码";
+            this.ma_craftcode.MinimumWidth = 8;
             this.ma_craftcode.Name = "ma_craftcode";
             this.ma_craftcode.Width = 120;
             // 
@@ -399,6 +418,7 @@
             // 
             this.sc_linecode.DataPropertyName = "sc_linecode";
             this.sc_linecode.HeaderText = "产线";
+            this.sc_linecode.MinimumWidth = 8;
             this.sc_linecode.Name = "sc_linecode";
             this.sc_linecode.Width = 80;
             // 
@@ -406,13 +426,17 @@
             // 
             this.mp_inman.DataPropertyName = "mp_inman";
             this.mp_inman.HeaderText = "人员工号";
+            this.mp_inman.MinimumWidth = 8;
             this.mp_inman.Name = "mp_inman";
+            this.mp_inman.Width = 150;
             // 
             // em_name
             // 
             this.em_name.DataPropertyName = "em_name";
             this.em_name.HeaderText = "人员姓名";
+            this.em_name.MinimumWidth = 8;
             this.em_name.Name = "em_name";
+            this.em_name.Width = 150;
             // 
             // sn_code
             // 
@@ -435,7 +459,7 @@
             // 
             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(1172, 104);
+            this.label1.Location = new System.Drawing.Point(1017, 104);
             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);
@@ -445,7 +469,7 @@
             // pictureBox4
             // 
             this.pictureBox4.BackColor = System.Drawing.Color.White;
-            this.pictureBox4.Location = new System.Drawing.Point(1061, 101);
+            this.pictureBox4.Location = new System.Drawing.Point(906, 101);
             this.pictureBox4.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.pictureBox4.Name = "pictureBox4";
             this.pictureBox4.Size = new System.Drawing.Size(90, 30);
@@ -466,7 +490,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(879, 104);
+            this.label4.Location = new System.Drawing.Point(812, 107);
             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);
@@ -476,7 +500,7 @@
             // pictureBox1
             // 
             this.pictureBox1.BackColor = System.Drawing.Color.Red;
-            this.pictureBox1.Location = new System.Drawing.Point(404, 101);
+            this.pictureBox1.Location = new System.Drawing.Point(359, 102);
             this.pictureBox1.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.pictureBox1.Name = "pictureBox1";
             this.pictureBox1.Size = new System.Drawing.Size(90, 30);
@@ -486,7 +510,7 @@
             // pictureBox3
             // 
             this.pictureBox3.BackColor = System.Drawing.Color.Black;
-            this.pictureBox3.Location = new System.Drawing.Point(769, 101);
+            this.pictureBox3.Location = new System.Drawing.Point(702, 104);
             this.pictureBox3.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.pictureBox3.Name = "pictureBox3";
             this.pictureBox3.Size = new System.Drawing.Size(90, 30);
@@ -508,18 +532,40 @@
             // 
             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(515, 104);
+            this.label3.Location = new System.Drawing.Point(470, 105);
             this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label3.Name = "label3";
             this.label3.Size = new System.Drawing.Size(206, 31);
             this.label3.TabIndex = 215;
             this.label3.Text = "已执行且为不良品";
             // 
+            // ms_endremark
+            // 
+            this.ms_endremark.Font = new System.Drawing.Font("微软雅黑", 12F);
+            this.ms_endremark.Location = new System.Drawing.Point(1248, 98);
+            this.ms_endremark.Margin = new System.Windows.Forms.Padding(4);
+            this.ms_endremark.Name = "ms_endremark";
+            this.ms_endremark.Size = new System.Drawing.Size(183, 39);
+            this.ms_endremark.TabIndex = 221;
+            // 
+            // label10
+            // 
+            this.label10.AutoSize = true;
+            this.label10.Font = new System.Drawing.Font("微软雅黑", 12F);
+            this.label10.Location = new System.Drawing.Point(1135, 101);
+            this.label10.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label10.Name = "label10";
+            this.label10.Size = new System.Drawing.Size(110, 31);
+            this.label10.TabIndex = 220;
+            this.label10.Text = "客户编码";
+            // 
             // Query_ExeProgress
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(1458, 778);
+            this.Controls.Add(this.ms_endremark);
+            this.Controls.Add(this.label10);
             this.Controls.Add(this.label1);
             this.Controls.Add(this.pictureBox4);
             this.Controls.Add(this.pictureBox2);
@@ -611,5 +657,7 @@
         private System.Windows.Forms.PictureBox pictureBox3;
         private System.Windows.Forms.Label label2;
         private System.Windows.Forms.Label label3;
+        private System.Windows.Forms.TextBox ms_endremark;
+        private System.Windows.Forms.Label label10;
     }
 }

+ 3 - 2
UAS_MES_ZT/FunctionCode/Query/Query_ExeProgress.cs

@@ -68,12 +68,12 @@ namespace UAS_MES_NEW.Query
                 if (ms_id.Rows.Count > 0)
                 {
                     //说明有过转号
-                    ms_id = (DataTable)dh.ExecuteSql("select ms_id,ms_makecode,ms_checkno,ms_outboxcode,pr_code,pr_orispeccode from makeserial left join product on ms_prodcode = pr_code where ms_sncode='" + ms_id.Rows[0]["beforesn"].ToString() + "' or ms_sncode='" + ms_id.Rows[0]["sn"].ToString() + "' order by ms_id", "select");
+                    ms_id = (DataTable)dh.ExecuteSql("select ms_id,ms_makecode,ms_checkno,ms_outboxcode,pr_code,pr_orispeccode,ms_endremark from makeserial left join product on ms_prodcode = pr_code where ms_sncode='" + ms_id.Rows[0]["beforesn"].ToString() + "' or ms_sncode='" + ms_id.Rows[0]["sn"].ToString() + "' order by ms_id", "select");
                 }
                 else
                 {
                     //没有过转号
-                    ms_id = (DataTable)dh.ExecuteSql("select ms_id,ms_makecode,ms_checkno,ms_outboxcode,pr_code,pr_orispeccode from makeserial left join product on ms_prodcode = pr_code where ms_sncode='" + sn_code.Text + "' order by ms_id", "select");
+                    ms_id = (DataTable)dh.ExecuteSql("select ms_id,ms_makecode,ms_checkno,ms_outboxcode,pr_code,pr_orispeccode,ms_endremark from makeserial left join product on ms_prodcode = pr_code where ms_sncode='" + sn_code.Text + "' order by ms_id", "select");
                 }
                 if (ms_id.Rows.Count == 0)
                 {
@@ -86,6 +86,7 @@ namespace UAS_MES_NEW.Query
                 ma_code.Text = ms_id.Rows[ms_id.Rows.Count - 1]["ms_makecode"].ToString();
                 pr_code.Text = ms_id.Rows[ms_id.Rows.Count - 1]["pr_code"].ToString();
                 pr_orispeccode.Text = ms_id.Rows[ms_id.Rows.Count - 1]["pr_orispeccode"].ToString();
+                ms_endremark.Text = ms_id.Rows[ms_id.Rows.Count - 1]["ms_endremark"].ToString();
                 ms_checkno.Text = ms_id.Rows[ms_id.Rows.Count - 1]["ms_checkno"].ToString();
                 pallet.Text = dh.getFieldDataByCondition("mes_package_view", "v_outboxcode", "v_barcode = '"+sn_code.Text+"' and v_type = 3").ToString();
                 ms_outboxcode.Text = ms_id.Rows[ms_id.Rows.Count - 1]["ms_outboxcode"].ToString();

+ 5 - 0
UAS_MES_ZT/PublicMethod/LogicHandler.cs

@@ -1193,6 +1193,11 @@ namespace UAS_MES_NEW.PublicMethod
                     }
                     //int sp_length = int.Parse(iLength != "" ? iLength : "0");
                     //若有多个,以|分割
+                    if (iPrefix == "")
+                    {
+                        ErrMessage = "未维护物料规则";
+                        return false;
+                    }
                     string[] pres = iPrefix.Split('|');
                     bool f = false;
                     for (int i = 0; i < pres.Length; i++)

+ 1 - 1
UAS_MES_ZT/UAS_MES_ZT.csproj

@@ -4,7 +4,7 @@
   <PropertyGroup>
     <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
     <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
-    <ProjectGuid>{4F7963D5-1759-4789-A36A-CFE93E56D2B3}</ProjectGuid>
+    <ProjectGuid>{C2ADEB8E-C8D6-44D7-BD30-EBB279673FF8}</ProjectGuid>
     <OutputType>WinExe</OutputType>
     <AppDesignerFolder>Properties</AppDesignerFolder>
     <RootNamespace>UAS_MES_NEW</RootNamespace>

Beberapa file tidak ditampilkan karena terlalu banyak file yang berubah dalam diff ini