فهرست منبع

修改功能提交

callm 3 ماه پیش
والد
کامیت
40b2fbcac2

+ 1 - 1
UAS_MES_JWS/CustomControl/HeadBar/HeadBar.cs

@@ -122,7 +122,7 @@ namespace UAS_MES_NEW.CustomControl
                 if (logout_confirm == "Yes")
                 {
                     //注销的时候切换回默认数据库
-                    SystemInf.ConnectionString = "Connection Timeout=0;Pooling=false;Password=select!#%*(;User ID=N_MES;Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=jiaweisi-mes.dieyuyun.com)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
+                    SystemInf.ConnectionString = "Connection Timeout=0;Pooling=false;Password=select!#%*(;User ID=N_MES;Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=10.8.11.30)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
                     DataHelper.DBConnectionString = SystemInf.ConnectionString;
                     //清除上个用户的权限信息
                     SystemInf.Caller.Clear();

+ 3 - 3
UAS_MES_JWS/DataOperate/DataHelper.cs

@@ -10,11 +10,11 @@ namespace UAS_MES_NEW.DataOperate
     class DataHelper
     {
         //系统默认的的连接字符串 
-        private string ConnectionStrings = "Connection Timeout=0;Pooling=false;Password=select!#%*(;User ID=N_MES;Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=jiaweisi-mes.dieyuyun.com)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
+        private string ConnectionStrings = "Connection Timeout=0;Pooling=false;Password=select!#%*(;User ID=N_MES;Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=10.8.11.30)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
 
-        //public static readonly string ERPAddesss = "http://jiaweisi-mes.dieyuyun.com:8099/mes/";
+        //public static readonly string ERPAddesss = "http://10.8.11.30:8099/mes/";
 
-        public static readonly string ERPAddesss = "http://jiaweisi-mes.dieyuyun.com:8099/mes/";
+        public static readonly string ERPAddesss = "http://10.8.11.30:8099/mes/";
 
         //用户选择的数据库的连接字符串
         public static string DBConnectionString;

+ 3 - 11
UAS_MES_JWS/FunctionCode/Make/Make_ColorBoxWeigh.cs

@@ -122,18 +122,10 @@ namespace UAS_MES_NEW.Make
                 {
                     string oMakeCode = "";
                     string oMsID = "";
-                    dt = (DataTable)dh.ExecuteSql("select ms_sncode from makeserial where ms_imei1='" + sncode.Text + "' order by ms_id desc", "select");
-                    if (dt.Rows.Count > 0)
+                    string mssncode = "";
+                    if (LogicHandler.GetInfoByMaterial(sncode.Text, out mssncode, out ErrorMessage))
                     {
-                        sncode.Text = dt.Rows[0]["ms_sncode"].ToString();
-                    }
-                    else
-                    {
-                        dt = (DataTable)dh.ExecuteSql("select ms_sncode from makeserial where ms_imei2='" + sncode.Text + "' order by ms_id desc", "select");
-                        if (dt.Rows.Count > 0)
-                        {
-                            sncode.Text = dt.Rows[0]["ms_sncode"].ToString();
-                        }
+                        sncode.Text = mssncode;
                     }
                     if (LogicHandler.CheckStepSNAndMacode(ma_code.Text, User.UserSourceCode, sncode.Text, User.UserCode, out oMakeCode, out oMsID, out ErrorMessage))
                     {

+ 1 - 1
UAS_MES_JWS/FunctionCode/Make/Make_CustomLabelPrint.cs

@@ -167,7 +167,7 @@ namespace UAS_MES_NEW.Make
                                             string fp_path = label.Rows[0]["FP_PATH"].ToString().Replace("/app/uas/webapps/", "");
                                             fp_name = label.Rows[0]["fp_name"].ToString();
                                             WebClient wc = new WebClient();
-                                            wc.DownloadFile("http://jiaweisi-mes.dieyuyun.com:8099/" + fp_path, @"C:\打印标签\" + fp_name);
+                                            wc.DownloadFile("http://10.8.11.30:8099/" + fp_path, @"C:\打印标签\" + fp_name);
                                         }
                                     }
                                 }

+ 1 - 1
UAS_MES_JWS/FunctionCode/Make/Make_FeedingCollection.cs

@@ -197,7 +197,7 @@ namespace UAS_MES_NEW.Make
                                 SetCheck set = new SetCheck("NG", Color.Red);
                                 BaseUtil.SetFormCenter(set);
                                 set.ShowDialog();
-                                ClearSn_code_Click(sender, e);
+                                //ClearSn_code_Click(sender, e);
                             }
                         }
                     }

+ 37 - 38
UAS_MES_JWS/FunctionCode/Make/Make_TestCollection.cs

@@ -51,7 +51,6 @@ namespace UAS_MES_NEW.Make
 
         LabelFormatDocument format;
 
-        Engine engine;
 
         bool EnablePrint;
 
@@ -87,18 +86,18 @@ namespace UAS_MES_NEW.Make
             if (BaseUtil.CheckBarTenderEnable())
             {
                 OperateResult.AppendText("已安装BarTender\n");
-                try
-                {
-                    engine = new Engine();
-                    engine.Start();
-                    format = engine.Documents.Open(Application.StartupPath + "/BadCode.btw");
-                    EnablePrint = true;
-                }
-                catch (Exception)
-                {
-                    EnablePrint = false;
-                    OperateResult.AppendText("未正确安装BarTender");
-                }
+                //try
+                //{
+                //    engine = new Engine();
+                //    engine.Start();
+                //    format = engine.Documents.Open(Application.StartupPath + "/BadCode.btw");
+                //    EnablePrint = true;
+                //}
+                //catch (Exception)
+                //{
+                //    EnablePrint = false;
+                //    OperateResult.AppendText("未正确安装BarTender");
+                //}
             }
             else
             {
@@ -217,7 +216,7 @@ namespace UAS_MES_NEW.Make
                         OperateResult.AppendText(">>" + ErrorMessage + "\n", Color.Red, ms_sncode);
                         return;
                     }
-                    if (LogicHandler.CheckStepSNAndMacode(oMakeCode, User.UserSourceCode, ms_sncode.Text, User.UserCode, out oMakeCode, out oMSID, out ErrorMessage))
+                    if (LogicHandler.CheckStepSNAndMacode(oMakeCode==""?ma_code.Text:oMakeCode, User.UserSourceCode, ms_sncode.Text, User.UserCode, out oMakeCode, out oMSID, out ErrorMessage))
                     {
                         //是否提示过工单切换框,检测前后执行
                         if (!LogicHandler.CheckDiffMakeCodeAfterStepCheck(ms_sncode.Text, oMakeCode, NoteForChange.Checked, NoteAlready, ma_code, out ErrorMessage))
@@ -588,18 +587,18 @@ namespace UAS_MES_NEW.Make
                         dh.ExecuteSql("update makeserial set ms_iftest=-1 where ms_id='" + oMSID + "'", "update");
                     }
                     //打印不良代码贴纸
-                    if (EnablePrint && AutoPrintBad.Checked)
-                    {
-                        RePrintCode.Clear();
-                        for (int i = 0; i < bcname.Length; i++)
-                        {
-                            RePrintCode.Add(bcname[i]);
-                            format.SubStrings["SN1"].Value = bcname[i];
-                            format.PrintSetup.PrinterName = Printer.Text;
-                            format.PrintSetup.IdenticalCopiesOfLabel = 1;
-                            format.Print();
-                        }
-                    }
+                    //if (EnablePrint && AutoPrintBad.Checked)
+                    //{
+                    //    RePrintCode.Clear();
+                    //    for (int i = 0; i < bcname.Length; i++)
+                    //    {
+                    //        RePrintCode.Add(bcname[i]);
+                    //        format.SubStrings["SN1"].Value = bcname[i];
+                    //        format.PrintSetup.PrinterName = Printer.Text;
+                    //        format.PrintSetup.IdenticalCopiesOfLabel = 1;
+                    //        format.Print();
+                    //    }
+                    //}
                     LastSncode = ms_sncode.Text;
                     //采集完不良,聚焦序列号
                     ms_sncode.Focus();
@@ -846,18 +845,18 @@ namespace UAS_MES_NEW.Make
 
         private void RePrint_Click(object sender, EventArgs e)
         {
-            if (EnablePrint && AutoPrintBad.Checked)
-            {
-                string[] bcname = RePrintCode.ToArray();
-                for (int i = 0; i < bcname.Length; i++)
-                {
-                    RePrintCode.Add(bcname[i]);
-                    format.SubStrings["SN1"].Value = bcname[i];
-                    format.PrintSetup.PrinterName = Printer.Text;
-                    format.PrintSetup.IdenticalCopiesOfLabel = 1;
-                    format.Print();
-                }
-            }
+            //if (EnablePrint && AutoPrintBad.Checked)
+            //{
+            //    string[] bcname = RePrintCode.ToArray();
+            //    for (int i = 0; i < bcname.Length; i++)
+            //    {
+            //        RePrintCode.Add(bcname[i]);
+            //        format.SubStrings["SN1"].Value = bcname[i];
+            //        format.PrintSetup.PrinterName = Printer.Text;
+            //        format.PrintSetup.IdenticalCopiesOfLabel = 1;
+            //        format.Print();
+            //    }
+            //}
         }
 
         private void WriteSoftWare_CheckedChanged(object sender, EventArgs e)

+ 3 - 27
UAS_MES_JWS/FunctionCode/Packing/Packing_PackageCollectionWeigh.cs

@@ -284,34 +284,10 @@ namespace UAS_MES_NEW.Packing
             {
                 if (LogicHandler.CheckStepAttribute(Tag.ToString(), User.UserSourceCode, out ErrorMessage))
                 {
-                    dt = (DataTable)dh.ExecuteSql("select ms_sncode from makeserial where ms_imei1='" + sn_code.Text + "' order by ms_id desc", "select");
-                    if (dt.Rows.Count > 0)
+                    string mssncode = "";
+                    if (LogicHandler.GetInfoByMaterial(sn_code.Text, out mssncode, out ErrorMessage))
                     {
-                        sn_code.Text = dt.Rows[0]["ms_sncode"].ToString();
-                    }
-                    else
-                    {
-                        dt = (DataTable)dh.ExecuteSql("select ms_sncode from makeserial where ms_imei2='" + sn_code.Text + "' order by ms_id desc", "select");
-                        if (dt.Rows.Count > 0)
-                        {
-                            sn_code.Text = dt.Rows[0]["ms_sncode"].ToString();
-                        }
-                        else
-                        {
-                            dt = (DataTable)dh.ExecuteSql("select mil_sncode from makeimeilist where mil_imei1='" + sn_code.Text + "' order by mil_id desc", "select");
-                            if (dt.Rows.Count > 0)
-                            {
-                                sn_code.Text = dt.Rows[0]["mil_sncode"].ToString();
-                            }
-                            else
-                            {
-                                dt = (DataTable)dh.ExecuteSql("select mil_sncode from makeimeilist where mil_imei2='" + sn_code.Text + "' order by mil_id desc", "select");
-                                if (dt.Rows.Count > 0)
-                                {
-                                    sn_code.Text = dt.Rows[0]["mil_sncode"].ToString();
-                                }
-                            }
-                        }
+                        sn_code.Text = mssncode;
                     }
                     dt = (DataTable)dh.ExecuteSql("select ms_status,ms_id,ms_makecode,ms_craftcode,ms_prodcode from makeserial where ms_sncode ='" + sn_code.Text + "'  order by ms_id desc", "select");
                     if (LogicHandler.CheckStepSNAndMacode("", User.UserSourceCode, sn_code.Text, User.UserCode, out oMakeCode, out oMsID, out ErrorMessage) || (dt.Rows.Count > 0 && dt.Rows[0]["ms_status"].ToString() == "2"))

+ 114 - 86
UAS_MES_JWS/FunctionCode/Packing/Packing_ProdWeightSet.Designer.cs

@@ -45,6 +45,7 @@
             this.panel4 = new System.Windows.Forms.Panel();
             this.errorValue = new System.Windows.Forms.TextBox();
             this.standardWeight = new System.Windows.Forms.TextBox();
+            this.confirm = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
             this.label7 = new System.Windows.Forms.Label();
             this.unit = new System.Windows.Forms.Label();
             this.label6 = new System.Windows.Forms.Label();
@@ -53,13 +54,13 @@
             this.weight = new System.Windows.Forms.Label();
             this.label1 = new System.Windows.Forms.Label();
             this.sncode = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SnCollectionBox();
-            this.confirm = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
             this.OperateResult = new UAS_MES_NEW.CustomControl.RichText.RichTextAutoBottom();
             this.ComList = new UAS_MES_NEW.CustomControl.ValueLabel.ValueLabel();
             this.BaudRate = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.NumOnlyTextBox();
             this.stopWeigh = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
             this.startWeigh = new UAS_MES_NEW.CustomControl.ButtonUtil.NormalButton();
             this.ma_code = new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SearchTextBox();
+            this.Remark = new UAS_MES_NEW.CustomControl.RichText.RichTextAutoBottom();
             this.panel4.SuspendLayout();
             this.SuspendLayout();
             // 
@@ -67,10 +68,10 @@
             // 
             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(33, 18);
-            this.ms_makecode_label.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.ms_makecode_label.Location = new System.Drawing.Point(44, 24);
+            this.ms_makecode_label.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
             this.ms_makecode_label.Name = "ms_makecode_label";
-            this.ms_makecode_label.Size = new System.Drawing.Size(86, 31);
+            this.ms_makecode_label.Size = new System.Drawing.Size(114, 41);
             this.ms_makecode_label.TabIndex = 212;
             this.ms_makecode_label.Text = "工单号";
             // 
@@ -78,9 +79,10 @@
             // 
             this.pr_code.AutoSize = true;
             this.pr_code.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.pr_code.Location = new System.Drawing.Point(145, 74);
+            this.pr_code.Location = new System.Drawing.Point(193, 99);
+            this.pr_code.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pr_code.Name = "pr_code";
-            this.pr_code.Size = new System.Drawing.Size(0, 31);
+            this.pr_code.Size = new System.Drawing.Size(0, 41);
             this.pr_code.TabIndex = 215;
             this.pr_code.TextChanged += new System.EventHandler(this.pr_code_TextChanged);
             // 
@@ -88,9 +90,10 @@
             // 
             this.label2.AutoSize = true;
             this.label2.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.label2.Location = new System.Drawing.Point(33, 74);
+            this.label2.Location = new System.Drawing.Point(44, 99);
+            this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label2.Name = "label2";
-            this.label2.Size = new System.Drawing.Size(110, 31);
+            this.label2.Size = new System.Drawing.Size(146, 41);
             this.label2.TabIndex = 214;
             this.label2.Text = "产品编号";
             // 
@@ -98,18 +101,20 @@
             // 
             this.pr_detail.AutoSize = true;
             this.pr_detail.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.pr_detail.Location = new System.Drawing.Point(145, 128);
+            this.pr_detail.Location = new System.Drawing.Point(193, 171);
+            this.pr_detail.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.pr_detail.Name = "pr_detail";
-            this.pr_detail.Size = new System.Drawing.Size(0, 31);
+            this.pr_detail.Size = new System.Drawing.Size(0, 41);
             this.pr_detail.TabIndex = 217;
             // 
             // label3
             // 
             this.label3.AutoSize = true;
             this.label3.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.label3.Location = new System.Drawing.Point(33, 128);
+            this.label3.Location = new System.Drawing.Point(44, 171);
+            this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label3.Name = "label3";
-            this.label3.Size = new System.Drawing.Size(110, 31);
+            this.label3.Size = new System.Drawing.Size(146, 41);
             this.label3.TabIndex = 216;
             this.label3.Text = "产品名称";
             // 
@@ -117,19 +122,21 @@
             // 
             this.pr_spec.AutoSize = true;
             this.pr_spec.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.pr_spec.Location = new System.Drawing.Point(145, 182);
-            this.pr_spec.MaximumSize = new System.Drawing.Size(550, 60);
+            this.pr_spec.Location = new System.Drawing.Point(193, 243);
+            this.pr_spec.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pr_spec.MaximumSize = new System.Drawing.Size(733, 80);
             this.pr_spec.Name = "pr_spec";
-            this.pr_spec.Size = new System.Drawing.Size(0, 31);
+            this.pr_spec.Size = new System.Drawing.Size(0, 41);
             this.pr_spec.TabIndex = 219;
             // 
             // label5
             // 
             this.label5.AutoSize = true;
             this.label5.Font = new System.Drawing.Font("微软雅黑", 12F);
-            this.label5.Location = new System.Drawing.Point(33, 182);
+            this.label5.Location = new System.Drawing.Point(44, 243);
+            this.label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label5.Name = "label5";
-            this.label5.Size = new System.Drawing.Size(62, 31);
+            this.label5.Size = new System.Drawing.Size(82, 41);
             this.label5.TabIndex = 218;
             this.label5.Text = "规格";
             // 
@@ -142,10 +149,11 @@
             this.columnHeader4,
             this.columnHeader5});
             this.showResult.Font = new System.Drawing.Font("宋体", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.showResult.Location = new System.Drawing.Point(428, 250);
-            this.showResult.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.showResult.HideSelection = false;
+            this.showResult.Location = new System.Drawing.Point(571, 333);
+            this.showResult.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.showResult.Name = "showResult";
-            this.showResult.Size = new System.Drawing.Size(658, 307);
+            this.showResult.Size = new System.Drawing.Size(876, 408);
             this.showResult.TabIndex = 220;
             this.showResult.UseCompatibleStateImageBehavior = false;
             this.showResult.View = System.Windows.Forms.View.Details;
@@ -191,37 +199,59 @@
             this.panel4.Controls.Add(this.pr_cartonunit);
             this.panel4.Controls.Add(this.label22);
             this.panel4.Controls.Add(this.weight);
-            this.panel4.Location = new System.Drawing.Point(570, 18);
-            this.panel4.Margin = new System.Windows.Forms.Padding(4, 2, 4, 2);
+            this.panel4.Location = new System.Drawing.Point(760, 24);
+            this.panel4.Margin = new System.Windows.Forms.Padding(5, 3, 5, 3);
             this.panel4.Name = "panel4";
-            this.panel4.Size = new System.Drawing.Size(515, 156);
+            this.panel4.Size = new System.Drawing.Size(686, 207);
             this.panel4.TabIndex = 221;
             // 
             // errorValue
             // 
-            this.errorValue.Location = new System.Drawing.Point(245, 19);
+            this.errorValue.Location = new System.Drawing.Point(327, 25);
+            this.errorValue.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.errorValue.Name = "errorValue";
-            this.errorValue.Size = new System.Drawing.Size(100, 28);
+            this.errorValue.Size = new System.Drawing.Size(132, 35);
             this.errorValue.TabIndex = 52;
             this.errorValue.Enter += new System.EventHandler(this.standardWeight_Enter);
             this.errorValue.Leave += new System.EventHandler(this.standardWeight_Leave);
             // 
             // standardWeight
             // 
-            this.standardWeight.Location = new System.Drawing.Point(83, 19);
+            this.standardWeight.Location = new System.Drawing.Point(111, 25);
+            this.standardWeight.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.standardWeight.Name = "standardWeight";
-            this.standardWeight.Size = new System.Drawing.Size(100, 28);
+            this.standardWeight.Size = new System.Drawing.Size(132, 35);
             this.standardWeight.TabIndex = 51;
             this.standardWeight.Enter += new System.EventHandler(this.standardWeight_Enter);
             this.standardWeight.Leave += new System.EventHandler(this.standardWeight_Leave);
             // 
+            // confirm
+            // 
+            this.confirm.AllPower = null;
+            this.confirm.BackColor = System.Drawing.Color.Transparent;
+            this.confirm.DownImage = ((System.Drawing.Image)(resources.GetObject("confirm.DownImage")));
+            this.confirm.Image = null;
+            this.confirm.IsShowBorder = true;
+            this.confirm.Location = new System.Drawing.Point(493, 115);
+            this.confirm.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
+            this.confirm.MoveImage = ((System.Drawing.Image)(resources.GetObject("confirm.MoveImage")));
+            this.confirm.Name = "confirm";
+            this.confirm.NormalImage = ((System.Drawing.Image)(resources.GetObject("confirm.NormalImage")));
+            this.confirm.Power = null;
+            this.confirm.Size = new System.Drawing.Size(100, 37);
+            this.confirm.TabIndex = 227;
+            this.confirm.Text = "保存";
+            this.confirm.UseVisualStyleBackColor = false;
+            this.confirm.Click += new System.EventHandler(this.confirm_Click);
+            // 
             // label7
             // 
             this.label7.AutoSize = true;
             this.label7.Font = new System.Drawing.Font("微软雅黑", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label7.Location = new System.Drawing.Point(18, 22);
+            this.label7.Location = new System.Drawing.Point(24, 29);
+            this.label7.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label7.Name = "label7";
-            this.label7.Size = new System.Drawing.Size(52, 27);
+            this.label7.Size = new System.Drawing.Size(69, 35);
             this.label7.TabIndex = 50;
             this.label7.Text = "标准";
             // 
@@ -229,18 +259,20 @@
             // 
             this.unit.AutoSize = true;
             this.unit.Font = new System.Drawing.Font("微软雅黑", 10F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.unit.Location = new System.Drawing.Point(371, 22);
+            this.unit.Location = new System.Drawing.Point(495, 29);
+            this.unit.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.unit.Name = "unit";
-            this.unit.Size = new System.Drawing.Size(36, 27);
+            this.unit.Size = new System.Drawing.Size(47, 35);
             this.unit.TabIndex = 47;
             this.unit.Text = "kg";
             // 
             // label6
             // 
             this.label6.AutoSize = true;
-            this.label6.Location = new System.Drawing.Point(202, 22);
+            this.label6.Location = new System.Drawing.Point(269, 29);
+            this.label6.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label6.Name = "label6";
-            this.label6.Size = new System.Drawing.Size(26, 18);
+            this.label6.Size = new System.Drawing.Size(34, 24);
             this.label6.TabIndex = 44;
             this.label6.Text = "±";
             // 
@@ -250,10 +282,10 @@
             this.pr_cartonunit.BackColor = System.Drawing.SystemColors.ActiveCaptionText;
             this.pr_cartonunit.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.pr_cartonunit.ForeColor = System.Drawing.SystemColors.ControlLightLight;
-            this.pr_cartonunit.Location = new System.Drawing.Point(452, 86);
-            this.pr_cartonunit.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.pr_cartonunit.Location = new System.Drawing.Point(603, 115);
+            this.pr_cartonunit.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
             this.pr_cartonunit.Name = "pr_cartonunit";
-            this.pr_cartonunit.Size = new System.Drawing.Size(46, 38);
+            this.pr_cartonunit.Size = new System.Drawing.Size(60, 50);
             this.pr_cartonunit.TabIndex = 42;
             this.pr_cartonunit.Text = "克";
             this.pr_cartonunit.Visible = false;
@@ -264,10 +296,10 @@
             this.label22.BackColor = System.Drawing.SystemColors.ActiveCaptionText;
             this.label22.Font = new System.Drawing.Font("微软雅黑", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.label22.ForeColor = System.Drawing.SystemColors.ControlLightLight;
-            this.label22.Location = new System.Drawing.Point(14, 86);
-            this.label22.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label22.Location = new System.Drawing.Point(19, 115);
+            this.label22.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
             this.label22.Name = "label22";
-            this.label22.Size = new System.Drawing.Size(75, 38);
+            this.label22.Size = new System.Drawing.Size(98, 50);
             this.label22.TabIndex = 20;
             this.label22.Text = "重量";
             // 
@@ -279,20 +311,20 @@
             this.weight.AutoSize = true;
             this.weight.Font = new System.Drawing.Font("微软雅黑", 22.2F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.weight.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(0)))));
-            this.weight.Location = new System.Drawing.Point(148, 74);
-            this.weight.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.weight.Location = new System.Drawing.Point(197, 99);
+            this.weight.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
             this.weight.Name = "weight";
-            this.weight.Size = new System.Drawing.Size(0, 58);
+            this.weight.Size = new System.Drawing.Size(0, 78);
             this.weight.TabIndex = 41;
             // 
             // label1
             // 
             this.label1.AutoSize = true;
             this.label1.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.label1.Location = new System.Drawing.Point(15, 526);
-            this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label1.Location = new System.Drawing.Point(20, 701);
+            this.label1.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
             this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(86, 31);
+            this.label1.Size = new System.Drawing.Size(114, 41);
             this.label1.TabIndex = 229;
             this.label1.Text = "序列号";
             // 
@@ -302,41 +334,24 @@
             this.sncode.BackColor = System.Drawing.Color.White;
             this.sncode.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.sncode.ID = null;
-            this.sncode.Location = new System.Drawing.Point(110, 526);
+            this.sncode.Location = new System.Drawing.Point(147, 701);
+            this.sncode.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.sncode.Name = "sncode";
             this.sncode.Power = null;
-            this.sncode.Size = new System.Drawing.Size(187, 31);
+            this.sncode.Size = new System.Drawing.Size(248, 39);
             this.sncode.Str = null;
             this.sncode.Str1 = null;
             this.sncode.Str2 = null;
             this.sncode.TabIndex = 228;
             this.sncode.KeyDown += new System.Windows.Forms.KeyEventHandler(this.sncode_KeyDown);
             // 
-            // confirm
-            // 
-            this.confirm.AllPower = null;
-            this.confirm.BackColor = System.Drawing.Color.Transparent;
-            this.confirm.DownImage = ((System.Drawing.Image)(resources.GetObject("confirm.DownImage")));
-            this.confirm.Image = null;
-            this.confirm.IsShowBorder = true;
-            this.confirm.Location = new System.Drawing.Point(370, 86);
-            this.confirm.MoveImage = ((System.Drawing.Image)(resources.GetObject("confirm.MoveImage")));
-            this.confirm.Name = "confirm";
-            this.confirm.NormalImage = ((System.Drawing.Image)(resources.GetObject("confirm.NormalImage")));
-            this.confirm.Power = null;
-            this.confirm.Size = new System.Drawing.Size(75, 28);
-            this.confirm.TabIndex = 227;
-            this.confirm.Text = "保存";
-            this.confirm.UseVisualStyleBackColor = false;
-            this.confirm.Click += new System.EventHandler(this.confirm_Click);
-            // 
             // OperateResult
             // 
             this.OperateResult.Font = new System.Drawing.Font("宋体", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
-            this.OperateResult.Location = new System.Drawing.Point(21, 248);
-            this.OperateResult.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.OperateResult.Location = new System.Drawing.Point(28, 331);
+            this.OperateResult.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.OperateResult.Name = "OperateResult";
-            this.OperateResult.Size = new System.Drawing.Size(332, 254);
+            this.OperateResult.Size = new System.Drawing.Size(441, 337);
             this.OperateResult.TabIndex = 226;
             this.OperateResult.Text = "";
             // 
@@ -344,11 +359,11 @@
             // 
             this.ComList.AutoSize = true;
             this.ComList.CutLength = null;
-            this.ComList.Location = new System.Drawing.Point(954, 228);
-            this.ComList.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
-            this.ComList.MaximumSize = new System.Drawing.Size(225, 0);
+            this.ComList.Location = new System.Drawing.Point(1272, 304);
+            this.ComList.Margin = new System.Windows.Forms.Padding(5, 0, 5, 0);
+            this.ComList.MaximumSize = new System.Drawing.Size(300, 0);
             this.ComList.Name = "ComList";
-            this.ComList.Size = new System.Drawing.Size(71, 18);
+            this.ComList.Size = new System.Drawing.Size(94, 24);
             this.ComList.TabIndex = 225;
             this.ComList.Text = "ComList";
             this.ComList.Visible = false;
@@ -358,12 +373,12 @@
             this.BaudRate.AllPower = null;
             this.BaudRate.BackColor = System.Drawing.Color.White;
             this.BaudRate.ID = null;
-            this.BaudRate.Location = new System.Drawing.Point(962, 194);
-            this.BaudRate.Margin = new System.Windows.Forms.Padding(4, 2, 4, 2);
+            this.BaudRate.Location = new System.Drawing.Point(1283, 259);
+            this.BaudRate.Margin = new System.Windows.Forms.Padding(5, 3, 5, 3);
             this.BaudRate.Name = "BaudRate";
             this.BaudRate.Negative = false;
             this.BaudRate.Power = null;
-            this.BaudRate.Size = new System.Drawing.Size(50, 28);
+            this.BaudRate.Size = new System.Drawing.Size(65, 35);
             this.BaudRate.Str = null;
             this.BaudRate.Str1 = null;
             this.BaudRate.Str2 = null;
@@ -377,13 +392,13 @@
             this.stopWeigh.DownImage = ((System.Drawing.Image)(resources.GetObject("stopWeigh.DownImage")));
             this.stopWeigh.Image = null;
             this.stopWeigh.IsShowBorder = true;
-            this.stopWeigh.Location = new System.Drawing.Point(808, 188);
-            this.stopWeigh.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.stopWeigh.Location = new System.Drawing.Point(1077, 251);
+            this.stopWeigh.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.stopWeigh.MoveImage = ((System.Drawing.Image)(resources.GetObject("stopWeigh.MoveImage")));
             this.stopWeigh.Name = "stopWeigh";
             this.stopWeigh.NormalImage = ((System.Drawing.Image)(resources.GetObject("stopWeigh.NormalImage")));
             this.stopWeigh.Power = null;
-            this.stopWeigh.Size = new System.Drawing.Size(108, 38);
+            this.stopWeigh.Size = new System.Drawing.Size(144, 51);
             this.stopWeigh.TabIndex = 223;
             this.stopWeigh.Text = "停止称重";
             this.stopWeigh.UseVisualStyleBackColor = false;
@@ -396,13 +411,13 @@
             this.startWeigh.DownImage = ((System.Drawing.Image)(resources.GetObject("startWeigh.DownImage")));
             this.startWeigh.Image = null;
             this.startWeigh.IsShowBorder = true;
-            this.startWeigh.Location = new System.Drawing.Point(654, 188);
-            this.startWeigh.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
+            this.startWeigh.Location = new System.Drawing.Point(872, 251);
+            this.startWeigh.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.startWeigh.MoveImage = ((System.Drawing.Image)(resources.GetObject("startWeigh.MoveImage")));
             this.startWeigh.Name = "startWeigh";
             this.startWeigh.NormalImage = ((System.Drawing.Image)(resources.GetObject("startWeigh.NormalImage")));
             this.startWeigh.Power = null;
-            this.startWeigh.Size = new System.Drawing.Size(93, 38);
+            this.startWeigh.Size = new System.Drawing.Size(124, 51);
             this.startWeigh.TabIndex = 222;
             this.startWeigh.Text = "开始称重";
             this.startWeigh.UseVisualStyleBackColor = false;
@@ -416,25 +431,36 @@
             this.ma_code.DBTitle = "";
             this.ma_code.Font = new System.Drawing.Font("微软雅黑", 9F);
             this.ma_code.FormName = null;
-            this.ma_code.Location = new System.Drawing.Point(151, 18);
-            this.ma_code.Margin = new System.Windows.Forms.Padding(4);
+            this.ma_code.Location = new System.Drawing.Point(201, 24);
+            this.ma_code.Margin = new System.Windows.Forms.Padding(5, 5, 5, 5);
             this.ma_code.Name = "ma_code";
             this.ma_code.Power = "";
             this.ma_code.ReturnData = null;
             this.ma_code.SelectField = null;
             this.ma_code.SetValueField = null;
-            this.ma_code.Size = new System.Drawing.Size(212, 34);
+            this.ma_code.Size = new System.Drawing.Size(283, 45);
             this.ma_code.TabIndex = 213;
             this.ma_code.TableName = null;
             this.ma_code.Tag = "makecode";
             this.ma_code.TextBoxEnable = true;
             this.ma_code.UserControlTextChanged += new UAS_MES_NEW.CustomControl.TextBoxWithIcon.SearchTextBox.OnTextChange(this.ma_code_UserControlTextChanged);
             // 
+            // Remark
+            // 
+            this.Remark.Font = new System.Drawing.Font("宋体", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.Remark.Location = new System.Drawing.Point(521, 140);
+            this.Remark.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
+            this.Remark.Name = "Remark";
+            this.Remark.Size = new System.Drawing.Size(219, 141);
+            this.Remark.TabIndex = 230;
+            this.Remark.Text = "";
+            // 
             // Packing_ProdWeightSet
             // 
-            this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
+            this.AutoScaleDimensions = new System.Drawing.SizeF(12F, 24F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.ClientSize = new System.Drawing.Size(1120, 596);
+            this.ClientSize = new System.Drawing.Size(1493, 795);
+            this.Controls.Add(this.Remark);
             this.Controls.Add(this.label1);
             this.Controls.Add(this.sncode);
             this.Controls.Add(this.OperateResult);
@@ -453,6 +479,7 @@
             this.Controls.Add(this.ma_code);
             this.Controls.Add(this.ms_makecode_label);
             this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
+            this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
             this.Name = "Packing_ProdWeightSet";
             this.Tag = "Packing!ProdWeightSet";
             this.Text = "Packing_ProdWeightSet";
@@ -499,5 +526,6 @@
         private System.Windows.Forms.Label label7;
         private System.Windows.Forms.TextBox errorValue;
         private System.Windows.Forms.TextBox standardWeight;
+        private CustomControl.RichText.RichTextAutoBottom Remark;
     }
 }

+ 4 - 2
UAS_MES_JWS/FunctionCode/Packing/Packing_ProdWeightSet.cs

@@ -142,6 +142,8 @@ namespace UAS_MES_NEW.Packing
                             try
                             {
                                 weight.Text = re.Match(serialPort1.ReadLine().Trim()).Groups[0].Value;
+                                Remark.AppendText(weight.Text + "\n");
+                                Remark.Clear();
                                 //weight.Text = Regex.Replace(serialPort1.ReadLine(), "\\D+", "");
                             }
                             catch (Exception)
@@ -306,11 +308,11 @@ namespace UAS_MES_NEW.Packing
             //在采样的时候不能更改
             if (showResult.Items.Count > 0)
             {
-                if ((sender as TextBox).Name == "standardWeight"&& standardWeight.Text == recordSW)
+                if ((sender as System.Windows.Forms.TextBox).Name == "standardWeight"&& standardWeight.Text == recordSW)
                 {
                     return;
                 }
-                else if((sender as TextBox).Name == "errorValue" && errorValue.Text == recordEV)
+                else if((sender as System.Windows.Forms.TextBox).Name == "errorValue" && errorValue.Text == recordEV)
                 {
                     return;
                 }

+ 69 - 69
UAS_MES_JWS/FunctionCode/Packing/Packing_ProdWeightSet.resx

@@ -121,115 +121,115 @@
   <data name="confirm.DownImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFcSURBVFhH5di7UsJAFMbxtDT6QMI76IAFT0npIE0K
-        GcRORxHklpAIBHLfbILV8XxeNsMznJ35F5vu+82kWYuILD4N7oq75roCw27sb/x5WBdc27btntY64o/i
-        DnZjPxy4S6A0R6PHO1WUNHc9ep4uxIXd2D8eP/XZowWUThBG+n3p0stsKbbJ0qFDFFfscQuUbpzm9Pqx
-        Eh8c4PGLkuX0Nl+LDw4GJckUTRaO+OBQo+SKpitXfHAwKClfZuuN+OBgUDJV0NzxxAeHM5TFxhffGUpe
-        aFp5n+KDg0FRfHH8nfjgUKPoktztXnxwMCgFX7xdID441ChlRf7+ID44GBTNl21wFB8capSqot0xFB8c
-        /lE6Wa70IU5oH0Ziw/5cFebpoPUwHPbL04nCJKUgisWF3dgPB3gABc9v7fvBoBcnaVKdvkha2I39cPjx
-        oPrhusndcPinpIXd2N8gIusbTaFspKtR2SQAAAAASUVORK5CYII=
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFfSURBVFhH5dhNTsJgFIXhM2WiCxL2oAEHrJKhQSYM
+        JIgzjSLIX0sRKPSPtl+Lo2uOgVbWcJu8CzhP8nVwISIAUAFwA+AWQFNh3M39lZMHrgDUu91uyxjji8KP
+        u7mfDgCuiVLt958fkjSTie3I62iqLu7m/sHgpQ2gRpSG6/nmc2bL23imtuHMkp0f5ADuidIMoljev+bq
+        o8PpH4NmcIjlY7JQHx0KlPCQyHBqqY8OJUqcyGhuq48OBUoUJzJeLNVHhwLlkKQysRz10eECZbpcqe8C
+        JU6NzJ1v9dGhQElSI9Zqoz46lCgmE3u9VR8dCpTUZOJsXPXRoUTJclltd+qjQ4FislzW7l59dChR8lw2
+        e099dDijNA5xYnZBKFvPVxv3x0lanA5qT71eOzsexQsjcf1AXdzN/XQ4H5l4fqs/djqtIIzC/Pgj2uJu
+        7i/Okf8O11UAd6c3pS3u5v6/w/UvTaFspAxAMh4AAAAASUVORK5CYII=
 </value>
   </data>
   <data name="confirm.MoveImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFzSURBVFhH5djNSgJRGMZxL2P2gTfQFbZvHSEZFBEW
-        CEIQBEIgVFiS9qXWoDmp4/fHzDmjM2a+vU/QqUVX0DvwXxxn9fwYXJwYEcXWNzIWt83dcq7AsBv7LXgA
-        ZI0r71/aaqjCJf8o7sFu7IcDFwdK4vimrv1oSZXRnArdQFzYjf3pQkOzRxIoVWc6X5X6M7ruBGIr9mbU
-        9MIVe9hAcXvBO125WnxwgMcXSpcPF20tPjgYlI5eUK6lxAcHg9Lmw3nTFx8cDEpLLSjr+OKDg0FpqojO
-        Gp744GBQ3vyITutT8cHBoDheRCe1ifjgYFBe+ZCxJ+KDg0GpT0NKv4zFBweDUpuEdFQdiQ8OBsXmw2Fl
-        JD44/KCM53TwNBQfHAzKMx/2Hgfig8M3SrXYUasUfz67DwOxYf9dV5urg+RWzta4aEnxn83OfV9c2I39
-        cIAHUOJceTNbUfmW94GX0sJu7IcDPH5fXCe4EvfXxe5/D7ux3yKi2CfkPhTy27lqkwAAAABJRU5ErkJg
-        gg==
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAF3SURBVFhH5djbSgJRFMbxHsP7wBfYT7jvu46QDIoI
+        C4QNQRAIgVBRSdpxpgZN83wYx5nZOjNqrvgEd73DGvhfzdX3g32ztohoS0iVElLtCakehVQdhmE39qfg
+        AZBtIdX70Y0TjsJ4SQw/7MZ+OAip0kDJnD3UdJAsyXIjKvWm7MJu7M+X6lpIlQWK3ZhEq8pgRvfdKdvK
+        /Rk1/XglpHKA0ulPF3Tb0eyDAzzWKL3pgq7bmn1wMChdPadiK2QfHAxKW8/pqhmwDw4GpRXOqdAI2AcH
+        g9IME7qs++yDg0H5DhK6qE3YBweD0vATOq967IODQfnyE1KOxz44GJTaJKb855h9cDAoVS+mU9tlHxwM
+        iuPFdGK57IPDH8o4ouO3EfvgYFA+xhEdvg7ZB4cNil3uhquc5dLBy5Bt2P/U0+Z0kN0tOhqHlpzt0v7z
+        gF3Yjf1w2ByZ0jjD7RSs8K7l/+Ant7Ab+8058t/hOiOkquBNMQy7sX99uP4F5D4U8hdr4uMAAAAASUVO
+        RK5CYII=
 </value>
   </data>
   <data name="confirm.NormalImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAGVSURBVFhH5di7agJRFIXhDSKoYBQEC8FCECwEQRBE
-        4uUVEtTiPKVlom2wttM6IfF+15njXHRnL19jD/zFmanWV8zAEDNTp9OJS6/Sm2QUht3YH4cHtdvtF6k7
-        mUwG1tqd3FR3YTf2w0FKUVOu6XT68Xgw3+8PtWH/bDYbCkeLGo1Gz/d9JwzvrL0gCKx49KlerxtIBUGo
-        PjjAg2q1mqDc2fN99cEBHlStVk0oB+t56oMDPKhSqZggDNm1N/XBAR5ULpeNvGD46rrqgwM8qFQqGV8O
-        56ujPjjAg4rFosFL5ni5qA8O8KBCoWBuns/701l9cIAH5fN5QfF4dzipDw7woFwuZ+zN483+oD44wIOy
-        2azB52i13asPDvCgTCZjHGt5sdmqDw7woHQ6bRzX8ny1UR8c4EHJZNJc5fC7XKsPDvCgRCLR2x9Pzt9q
-        zT+Lpdqw/3A6W/HoUywWa32Nx8OL4zwffM8X6sJu7IcDPCgajaak7udoNNjsdgc81BZ2Yz8c4PH8cR2J
-        ROJSU3qXjMKwG/vjzEz/skOI3Zqgv7AAAAAASUVORK5CYII=
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAGpSURBVFhH5dg/ayJBGMfxB4YFXTARBAvBQhAsBEEQ
+        ZLnNzFu4I6aYV5kyF9tgbad1jrsYY9T4Z3fcnV2f45e38Sx8q6l+n2IWhpiZjDFVY8wPY8xPY4wVGHZj
+        fxUepLW+0Vrfz+fzR+fclgV+2I39cNBa31Icx/FisXi6XpnL8io27F8ul89xHN9RFEWTPM+ToihZet57
+        F0XRA43HYwsp7wvxwQEeNBqNbFmWnOW5+OAADxoOh7YoS3ZZJj44wIMGg4H1RcGpu4gPDvCgfr9vvfd8
+        TlPxwQEe1Ov1bO49H8+J+OAAD+p2uxaXzNfpJD44wIM6nY69ZDnvDkfxwQEe1G637SXLeLs/iA8O8KBW
+        q2XdJePNbi8+OMCDms2mxe9o/bkTHxzgQY1GwybO8WrzKT44wIPq9bpNUsdv64344AAPqtVq9pw6/vv+
+        IT44wIPCMJzsvg7Jv/UH/1m9iw3794ejC8PwgSqVyt3LbPZ8SpLvg9e3lbiwG/vhAA8KguA2CIL739Pp
+        42a73eNQWtiN/XCAB+GhVilVVUrFSqlfSikrMOzG/u+H6/+yQ4jdXN8e9AAAAABJRU5ErkJggg==
 </value>
   </data>
   <data name="stopWeigh.DownImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFcSURBVFhH5di7UsJAFMbxtDT6QMI76IAFT0npIE0K
-        GcRORxHklpAIBHLfbILV8XxeNsMznJ35F5vu+82kWYuILD4N7oq75roCw27sb/x5WBdc27btntY64o/i
-        DnZjPxy4S6A0R6PHO1WUNHc9ep4uxIXd2D8eP/XZowWUThBG+n3p0stsKbbJ0qFDFFfscQuUbpzm9Pqx
-        Eh8c4PGLkuX0Nl+LDw4GJckUTRaO+OBQo+SKpitXfHAwKClfZuuN+OBgUDJV0NzxxAeHM5TFxhffGUpe
-        aFp5n+KDg0FRfHH8nfjgUKPoktztXnxwMCgFX7xdID441ChlRf7+ID44GBTNl21wFB8capSqot0xFB8c
-        /lE6Wa70IU5oH0Ziw/5cFebpoPUwHPbL04nCJKUgisWF3dgPB3gABc9v7fvBoBcnaVKdvkha2I39cPjx
-        oPrhusndcPinpIXd2N8gIusbTaFspKtR2SQAAAAASUVORK5CYII=
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFfSURBVFhH5dhNTsJgFIXhM2WiCxL2oAEHrJKhQSYM
+        JIgzjSLIX0sRKPSPtl+Lo2uOgVbWcJu8CzhP8nVwISIAUAFwA+AWQFNh3M39lZMHrgDUu91uyxjji8KP
+        u7mfDgCuiVLt958fkjSTie3I62iqLu7m/sHgpQ2gRpSG6/nmc2bL23imtuHMkp0f5ADuidIMoljev+bq
+        o8PpH4NmcIjlY7JQHx0KlPCQyHBqqY8OJUqcyGhuq48OBUoUJzJeLNVHhwLlkKQysRz10eECZbpcqe8C
+        JU6NzJ1v9dGhQElSI9Zqoz46lCgmE3u9VR8dCpTUZOJsXPXRoUTJclltd+qjQ4FislzW7l59dChR8lw2
+        e099dDijNA5xYnZBKFvPVxv3x0lanA5qT71eOzsexQsjcf1AXdzN/XQ4H5l4fqs/djqtIIzC/Pgj2uJu
+        7i/Okf8O11UAd6c3pS3u5v6/w/UvTaFspAxAMh4AAAAASUVORK5CYII=
 </value>
   </data>
   <data name="stopWeigh.MoveImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFzSURBVFhH5djNSgJRGMZxL2P2gTfQFbZvHSEZFBEW
-        CEIQBEIgVFiS9qXWoDmp4/fHzDmjM2a+vU/QqUVX0DvwXxxn9fwYXJwYEcXWNzIWt83dcq7AsBv7LXgA
-        ZI0r71/aaqjCJf8o7sFu7IcDFwdK4vimrv1oSZXRnArdQFzYjf3pQkOzRxIoVWc6X5X6M7ruBGIr9mbU
-        9MIVe9hAcXvBO125WnxwgMcXSpcPF20tPjgYlI5eUK6lxAcHg9Lmw3nTFx8cDEpLLSjr+OKDg0FpqojO
-        Gp744GBQ3vyITutT8cHBoDheRCe1ifjgYFBe+ZCxJ+KDg0GpT0NKv4zFBweDUpuEdFQdiQ8OBsXmw2Fl
-        JD44/KCM53TwNBQfHAzKMx/2Hgfig8M3SrXYUasUfz67DwOxYf9dV5urg+RWzta4aEnxn83OfV9c2I39
-        cIAHUOJceTNbUfmW94GX0sJu7IcDPH5fXCe4EvfXxe5/D7ux3yKi2CfkPhTy27lqkwAAAABJRU5ErkJg
-        gg==
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAF3SURBVFhH5djbSgJRFMbxHsP7wBfYT7jvu46QDIoI
+        C4QNQRAIgVBRSdpxpgZN83wYx5nZOjNqrvgEd73DGvhfzdX3g32ztohoS0iVElLtCakehVQdhmE39qfg
+        AZBtIdX70Y0TjsJ4SQw/7MZ+OAip0kDJnD3UdJAsyXIjKvWm7MJu7M+X6lpIlQWK3ZhEq8pgRvfdKdvK
+        /Rk1/XglpHKA0ulPF3Tb0eyDAzzWKL3pgq7bmn1wMChdPadiK2QfHAxKW8/pqhmwDw4GpRXOqdAI2AcH
+        g9IME7qs++yDg0H5DhK6qE3YBweD0vATOq967IODQfnyE1KOxz44GJTaJKb855h9cDAoVS+mU9tlHxwM
+        iuPFdGK57IPDH8o4ouO3EfvgYFA+xhEdvg7ZB4cNil3uhquc5dLBy5Bt2P/U0+Z0kN0tOhqHlpzt0v7z
+        gF3Yjf1w2ByZ0jjD7RSs8K7l/+Ant7Ab+8058t/hOiOkquBNMQy7sX99uP4F5D4U8hdr4uMAAAAASUVO
+        RK5CYII=
 </value>
   </data>
   <data name="stopWeigh.NormalImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAGVSURBVFhH5di7agJRFIXhDSKoYBQEC8FCECwEQRBE
-        4uUVEtTiPKVlom2wttM6IfF+15njXHRnL19jD/zFmanWV8zAEDNTp9OJS6/Sm2QUht3YH4cHtdvtF6k7
-        mUwG1tqd3FR3YTf2w0FKUVOu6XT68Xgw3+8PtWH/bDYbCkeLGo1Gz/d9JwzvrL0gCKx49KlerxtIBUGo
-        PjjAg2q1mqDc2fN99cEBHlStVk0oB+t56oMDPKhSqZggDNm1N/XBAR5ULpeNvGD46rrqgwM8qFQqGV8O
-        56ujPjjAg4rFosFL5ni5qA8O8KBCoWBuns/701l9cIAH5fN5QfF4dzipDw7woFwuZ+zN483+oD44wIOy
-        2azB52i13asPDvCgTCZjHGt5sdmqDw7woHQ6bRzX8ny1UR8c4EHJZNJc5fC7XKsPDvCgRCLR2x9Pzt9q
-        zT+Lpdqw/3A6W/HoUywWa32Nx8OL4zwffM8X6sJu7IcDPCgajaak7udoNNjsdgc81BZ2Yz8c4PH8cR2J
-        ROJSU3qXjMKwG/vjzEz/skOI3Zqgv7AAAAAASUVORK5CYII=
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAGpSURBVFhH5dg/ayJBGMfxB4YFXTARBAvBQhAsBEEQ
+        ZLnNzFu4I6aYV5kyF9tgbad1jrsYY9T4Z3fcnV2f45e38Sx8q6l+n2IWhpiZjDFVY8wPY8xPY4wVGHZj
+        fxUepLW+0Vrfz+fzR+fclgV+2I39cNBa31Icx/FisXi6XpnL8io27F8ul89xHN9RFEWTPM+ToihZet57
+        F0XRA43HYwsp7wvxwQEeNBqNbFmWnOW5+OAADxoOh7YoS3ZZJj44wIMGg4H1RcGpu4gPDvCgfr9vvfd8
+        TlPxwQEe1Ov1bO49H8+J+OAAD+p2uxaXzNfpJD44wIM6nY69ZDnvDkfxwQEe1G637SXLeLs/iA8O8KBW
+        q2XdJePNbi8+OMCDms2mxe9o/bkTHxzgQY1GwybO8WrzKT44wIPq9bpNUsdv64344AAPqtVq9pw6/vv+
+        IT44wIPCMJzsvg7Jv/UH/1m9iw3794ejC8PwgSqVyt3LbPZ8SpLvg9e3lbiwG/vhAA8KguA2CIL739Pp
+        42a73eNQWtiN/XCAB+GhVilVVUrFSqlfSikrMOzG/u+H6/+yQ4jdXN8e9AAAAABJRU5ErkJggg==
 </value>
   </data>
   <data name="startWeigh.DownImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFcSURBVFhH5di7UsJAFMbxtDT6QMI76IAFT0npIE0K
-        GcRORxHklpAIBHLfbILV8XxeNsMznJ35F5vu+82kWYuILD4N7oq75roCw27sb/x5WBdc27btntY64o/i
-        DnZjPxy4S6A0R6PHO1WUNHc9ep4uxIXd2D8eP/XZowWUThBG+n3p0stsKbbJ0qFDFFfscQuUbpzm9Pqx
-        Eh8c4PGLkuX0Nl+LDw4GJckUTRaO+OBQo+SKpitXfHAwKClfZuuN+OBgUDJV0NzxxAeHM5TFxhffGUpe
-        aFp5n+KDg0FRfHH8nfjgUKPoktztXnxwMCgFX7xdID441ChlRf7+ID44GBTNl21wFB8capSqot0xFB8c
-        /lE6Wa70IU5oH0Ziw/5cFebpoPUwHPbL04nCJKUgisWF3dgPB3gABc9v7fvBoBcnaVKdvkha2I39cPjx
-        oPrhusndcPinpIXd2N8gIusbTaFspKtR2SQAAAAASUVORK5CYII=
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFfSURBVFhH5dhNTsJgFIXhM2WiCxL2oAEHrJKhQSYM
+        JIgzjSLIX0sRKPSPtl+Lo2uOgVbWcJu8CzhP8nVwISIAUAFwA+AWQFNh3M39lZMHrgDUu91uyxjji8KP
+        u7mfDgCuiVLt958fkjSTie3I62iqLu7m/sHgpQ2gRpSG6/nmc2bL23imtuHMkp0f5ADuidIMoljev+bq
+        o8PpH4NmcIjlY7JQHx0KlPCQyHBqqY8OJUqcyGhuq48OBUoUJzJeLNVHhwLlkKQysRz10eECZbpcqe8C
+        JU6NzJ1v9dGhQElSI9Zqoz46lCgmE3u9VR8dCpTUZOJsXPXRoUTJclltd+qjQ4FislzW7l59dChR8lw2
+        e099dDijNA5xYnZBKFvPVxv3x0lanA5qT71eOzsexQsjcf1AXdzN/XQ4H5l4fqs/djqtIIzC/Pgj2uJu
+        7i/Okf8O11UAd6c3pS3u5v6/w/UvTaFspAxAMh4AAAAASUVORK5CYII=
 </value>
   </data>
   <data name="startWeigh.MoveImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAFzSURBVFhH5djNSgJRGMZxL2P2gTfQFbZvHSEZFBEW
-        CEIQBEIgVFiS9qXWoDmp4/fHzDmjM2a+vU/QqUVX0DvwXxxn9fwYXJwYEcXWNzIWt83dcq7AsBv7LXgA
-        ZI0r71/aaqjCJf8o7sFu7IcDFwdK4vimrv1oSZXRnArdQFzYjf3pQkOzRxIoVWc6X5X6M7ruBGIr9mbU
-        9MIVe9hAcXvBO125WnxwgMcXSpcPF20tPjgYlI5eUK6lxAcHg9Lmw3nTFx8cDEpLLSjr+OKDg0FpqojO
-        Gp744GBQ3vyITutT8cHBoDheRCe1ifjgYFBe+ZCxJ+KDg0GpT0NKv4zFBweDUpuEdFQdiQ8OBsXmw2Fl
-        JD44/KCM53TwNBQfHAzKMx/2Hgfig8M3SrXYUasUfz67DwOxYf9dV5urg+RWzta4aEnxn83OfV9c2I39
-        cIAHUOJceTNbUfmW94GX0sJu7IcDPH5fXCe4EvfXxe5/D7ux3yKi2CfkPhTy27lqkwAAAABJRU5ErkJg
-        gg==
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAF3SURBVFhH5djbSgJRFMbxHsP7wBfYT7jvu46QDIoI
+        C4QNQRAIgVBRSdpxpgZN83wYx5nZOjNqrvgEd73DGvhfzdX3g32ztohoS0iVElLtCakehVQdhmE39qfg
+        AZBtIdX70Y0TjsJ4SQw/7MZ+OAip0kDJnD3UdJAsyXIjKvWm7MJu7M+X6lpIlQWK3ZhEq8pgRvfdKdvK
+        /Rk1/XglpHKA0ulPF3Tb0eyDAzzWKL3pgq7bmn1wMChdPadiK2QfHAxKW8/pqhmwDw4GpRXOqdAI2AcH
+        g9IME7qs++yDg0H5DhK6qE3YBweD0vATOq967IODQfnyE1KOxz44GJTaJKb855h9cDAoVS+mU9tlHxwM
+        iuPFdGK57IPDH8o4ouO3EfvgYFA+xhEdvg7ZB4cNil3uhquc5dLBy5Bt2P/U0+Z0kN0tOhqHlpzt0v7z
+        gF3Yjf1w2ByZ0jjD7RSs8K7l/+Ant7Ab+8058t/hOiOkquBNMQy7sX99uP4F5D4U8hdr4uMAAAAASUVO
+        RK5CYII=
 </value>
   </data>
   <data name="startWeigh.NormalImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
     <value>
         iVBORw0KGgoAAAANSUhEUgAAAEUAAAAWCAYAAACWl1FwAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
-        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAGVSURBVFhH5di7agJRFIXhDSKoYBQEC8FCECwEQRBE
-        4uUVEtTiPKVlom2wttM6IfF+15njXHRnL19jD/zFmanWV8zAEDNTp9OJS6/Sm2QUht3YH4cHtdvtF6k7
-        mUwG1tqd3FR3YTf2w0FKUVOu6XT68Xgw3+8PtWH/bDYbCkeLGo1Gz/d9JwzvrL0gCKx49KlerxtIBUGo
-        PjjAg2q1mqDc2fN99cEBHlStVk0oB+t56oMDPKhSqZggDNm1N/XBAR5ULpeNvGD46rrqgwM8qFQqGV8O
-        56ujPjjAg4rFosFL5ni5qA8O8KBCoWBuns/701l9cIAH5fN5QfF4dzipDw7woFwuZ+zN483+oD44wIOy
-        2azB52i13asPDvCgTCZjHGt5sdmqDw7woHQ6bRzX8ny1UR8c4EHJZNJc5fC7XKsPDvCgRCLR2x9Pzt9q
-        zT+Lpdqw/3A6W/HoUywWa32Nx8OL4zwffM8X6sJu7IcDPCgajaak7udoNNjsdgc81BZ2Yz8c4PH8cR2J
-        ROJSU3qXjMKwG/vjzEz/skOI3Zqgv7AAAAAASUVORK5CYII=
+        dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAGpSURBVFhH5dg/ayJBGMfxB4YFXTARBAvBQhAsBEEQ
+        ZLnNzFu4I6aYV5kyF9tgbad1jrsYY9T4Z3fcnV2f45e38Sx8q6l+n2IWhpiZjDFVY8wPY8xPY4wVGHZj
+        fxUepLW+0Vrfz+fzR+fclgV+2I39cNBa31Icx/FisXi6XpnL8io27F8ul89xHN9RFEWTPM+ToihZet57
+        F0XRA43HYwsp7wvxwQEeNBqNbFmWnOW5+OAADxoOh7YoS3ZZJj44wIMGg4H1RcGpu4gPDvCgfr9vvfd8
+        TlPxwQEe1Ov1bO49H8+J+OAAD+p2uxaXzNfpJD44wIM6nY69ZDnvDkfxwQEe1G637SXLeLs/iA8O8KBW
+        q2XdJePNbi8+OMCDms2mxe9o/bkTHxzgQY1GwybO8WrzKT44wIPq9bpNUsdv64344AAPqtVq9pw6/vv+
+        IT44wIPCMJzsvg7Jv/UH/1m9iw3794ejC8PwgSqVyt3LbPZ8SpLvg9e3lbiwG/vhAA8KguA2CIL739Pp
+        42a73eNQWtiN/XCAB+GhVilVVUrFSqlfSikrMOzG/u+H6/+yQ4jdXN8e9AAAAABJRU5ErkJggg==
 </value>
   </data>
 </root>

+ 1 - 0
UAS_MES_JWS/FunctionCode/Special/Special_CancelOQC.cs

@@ -147,6 +147,7 @@ namespace UAS_MES_NEW.Special
                     LogicHandler.DoCommandLog(Tag.ToString(), User.UserName, ms_makecode.Text, User.UserLineCode, User.UserSourceCode, "QC抽检", "QC抽检成功,结果为不良", SN.Text, "");
                 }
                 OperateResult.AppendText("序列号" + SN.Text + "抽检记录成功", System.Drawing.Color.Green);
+                SN.SelectAll();
                 LoadData();
             }
         }

+ 2 - 2
UAS_MES_JWS/Login.cs

@@ -47,7 +47,7 @@ namespace UAS_MES_NEW
         {
             BaseUtil.FormStepInOrOut(this, true);
             //设置默认数据库
-            SystemInf.DefaultDB = "Connection Timeout=0;Pooling=false;Password=select!#%*(;User ID=N_MES;Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=jiaweisi-mes.dieyuyun.com)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
+            SystemInf.DefaultDB = "Connection Timeout=0;Pooling=false;Password=select!#%*(;User ID=N_MES;Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=10.8.11.30)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
             SystemInf.ProcessesID = System.Diagnostics.Process.GetCurrentProcess().Id;
             CheckForIllegalCrossThreadCalls = false;
             LoadMasterInf = new Thread(LoadMaster);
@@ -94,7 +94,7 @@ namespace UAS_MES_NEW
             //设置选中数据库的链接
             string DBUser = DB.SelectedValue.ToString().Split('#')[0];
             string Address = DB.SelectedValue.ToString().Split('#')[1];
-            DataHelper.DBConnectionString = "Password=select!#%*(;User ID=" + DBUser + ";Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=jiaweisi-mes.dieyuyun.com)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
+            DataHelper.DBConnectionString = "Password=select!#%*(;User ID=" + DBUser + ";Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=10.8.11.30)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
             SystemInf.CurrentDB = DBUser;
             //设置屏幕的宽高信息
             SystemInf.ScreenWidth = Screen.PrimaryScreen.WorkingArea.Width;

+ 1 - 1
UAS_MES_JWS/Main.cs

@@ -357,7 +357,7 @@ namespace UAS_MES_NEW
             if (logout_confirm == "Yes")
             {
                 //注销的时候切换回默认数据库
-                SystemInf.ConnectionString = "Connection Timeout=0;Pooling=false;Password=select!#%*(;User ID=N_MES;Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=jiaweisi-mes.dieyuyun.com)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
+                SystemInf.ConnectionString = "Connection Timeout=0;Pooling=false;Password=select!#%*(;User ID=N_MES;Pooling=false;Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=10.8.11.30)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=orcl)));";
                 DataHelper.DBConnectionString = SystemInf.ConnectionString;
                 //清除上个用户的权限信息
                 SystemInf.Caller.Clear();

+ 29 - 1
UAS_MES_JWS/PublicMethod/LogicHandler.cs

@@ -44,6 +44,34 @@ namespace UAS_MES_NEW.PublicMethod
             dh.ExecuteSql(sql.ToString(), "insert");
         }
 
+        public static bool GetInfoByMaterial(string iPCBA, out string oSN, out string oErrMessage)
+        {
+            oSN = "";
+            oErrMessage = "";
+            if (iPCBA == "")
+            {
+                oErrMessage = "主板SN不能为空";
+            }
+
+            DataTable dt = (DataTable)dh.ExecuteSql("select ms_firstsn,ms_sncode from CRAFTMATERIAL left join make on cm_makecode=ma_code " +
+                "left join makeserial on ms_firstsn=cm_firstsn and cm_makecode=ms_makecode  where cm_barcode='" + iPCBA + "' and nvl(cm_status,0)<>-1 order by cm_id desc", "select");
+            if (dt.Rows.Count > 0)
+            {
+                oSN = dt.Rows[0]["ms_sncode"].ToString();
+            }
+            else
+            {
+                oErrMessage = "主板SN未查询到关联信息";
+            }
+            if (oErrMessage == "" || oErrMessage == null || oErrMessage == "null")
+            {
+                return true;
+            }
+            else
+                return false;
+        }
+
+
         /// <summary>
         /// 判断工单是否已经下放
         /// </summary>
@@ -420,7 +448,7 @@ namespace UAS_MES_NEW.PublicMethod
             oMakeCode = "";
             oErrorMessage = "";
             oStatus = "";
-            DataTable dt = dh.getFieldsDataByCondition("MakeSerial", new string[] { "ms_makecode", "ms_status" }, "ms_id=(select max(ms_id) from makeserial where ms_sncode='" + iSnCode + "')");
+            DataTable dt = dh.getFieldsDataByCondition("MakeSerial", new string[] { "ms_makecode", "ms_status" }, "ms_id=(select max(ms_id) from makeserial where ms_sncode='" + iSnCode + "') ");
             if (dt.Rows.Count > 0)
             {
                 oMakeCode = dt.Rows[0]["ms_makecode"].ToString();

+ 3 - 3
UAS_MES_JWS/PublicMethod/Print.cs

@@ -230,7 +230,7 @@ namespace UAS_MES_NEW.PublicMethod
                     return false;
                 }
             }
-            if (IfRePrint != "-1" && LabelType != "机身标")
+            if (IfRePrint != "-1" && LabelType != "机身标" && LabelType != "老化箱标")
             {
                 bool allowPallte = true;
                 if ((SystemInf.dh.getFieldDataByCondition("master", "MA_FUNCTION", "ma_user='" + SystemInf.CurrentDB + "'").ToString() == "万年MES系统(正式)"))
@@ -285,7 +285,7 @@ namespace UAS_MES_NEW.PublicMethod
                                 string fp_path = label.Rows[0]["FP_PATH"].ToString().Replace("/app/uas/webapps/", "");
                                 fp_name = label.Rows[0]["fp_name"].ToString();
                                 WebClient wc = new WebClient();
-                                wc.DownloadFile("http://jiaweisi-mes.dieyuyun.com:8099/" + fp_path, @"C:\打印标签\" + fp_name);
+                                wc.DownloadFile("http://10.8.11.30:8099/" + fp_path, @"C:\打印标签\" + fp_name);
                             }
                         }
                     }
@@ -314,7 +314,7 @@ namespace UAS_MES_NEW.PublicMethod
                                     string fp_path = label.Rows[0]["FP_PATH"].ToString().Replace("/app/uas/webapps/", "");
                                     fp_name = label.Rows[0]["fp_name"].ToString();
                                     WebClient wc = new WebClient();
-                                    wc.DownloadFile("http://jiaweisi-mes.dieyuyun.com:8099/" + fp_path, @"C:\打印标签\" + fp_name);
+                                    wc.DownloadFile("http://10.8.11.30:8099/" + fp_path, @"C:\打印标签\" + fp_name);
                                     FileInfo file = new FileInfo(@"C:\打印标签\" + fp_name);
                                     file.CreationTime = Convert.ToDateTime(filelastwritetime);
                                 }