Эх сурвалжийг харах

[万利达MES]站点重置增加备注,卡通箱称重界面录入框属性调整

caosy 6 сар өмнө
parent
commit
53d4213d1f

+ 2 - 2
UAS-MES/FunctionCode/Make/Make_CartonBoxWeigh.Designer.cs

@@ -64,7 +64,7 @@
             this.ma_salecode = new UAS_MES.CustomControl.ValueLabel.ValueLabel();
             this.Clean = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
             this.normalButton1 = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
-            this.outboxcode = new UAS_MES.CustomControl.TextBoxWithIcon.SnCollectionBox();
+            this.outboxcode = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
             this.OperateResult = new UAS_MES.CustomControl.RichText.RichTextAutoBottom();
             this.fileSystemWatcher1 = new System.IO.FileSystemWatcher();
             this.StepCount = new UAS_MES.CustomControl.TextBoxWithIcon.SourceStepCount();
@@ -778,7 +778,7 @@
         private System.Windows.Forms.Label ma_code_label;
         private CustomControl.ButtonUtil.NormalButton Clean;
         private CustomControl.ButtonUtil.NormalButton normalButton1;
-        private CustomControl.TextBoxWithIcon.SnCollectionBox outboxcode;
+        private CustomControl.TextBoxWithIcon.EnterTextBox outboxcode;
         private CustomControl.ValueLabel.ValueLabel pr_cartongw;
         private CustomControl.ValueLabel.ValueLabel pr_code;
         private System.Windows.Forms.Label pr_cartongw_label;

+ 4 - 4
UAS-MES/FunctionCode/Make/Make_CartonBoxWeighN.Designer.cs

@@ -64,7 +64,7 @@
             this.ma_salecode = new UAS_MES.CustomControl.ValueLabel.ValueLabel();
             this.Clean = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
             this.normalButton1 = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
-            this.outboxcode = new UAS_MES.CustomControl.TextBoxWithIcon.SnCollectionBox();
+            this.outboxcode = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
             this.OperateResult = new UAS_MES.CustomControl.RichText.RichTextAutoBottom();
             this.fileSystemWatcher1 = new System.IO.FileSystemWatcher();
             this.StepCount = new UAS_MES.CustomControl.TextBoxWithIcon.SourceStepCount();
@@ -82,7 +82,7 @@
             this.weight_label = new System.Windows.Forms.Label();
             this.weight = new System.Windows.Forms.Label();
             this.label122 = new System.Windows.Forms.Label();
-            this.lpn = new UAS_MES.CustomControl.TextBoxWithIcon.SnCollectionBox();
+            this.lpn = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
             ((System.ComponentModel.ISupportInitialize)(this.fileSystemWatcher1)).BeginInit();
             this.SuspendLayout();
             // 
@@ -813,7 +813,7 @@
         private System.Windows.Forms.Label ma_code_label;
         private CustomControl.ButtonUtil.NormalButton Clean;
         private CustomControl.ButtonUtil.NormalButton normalButton1;
-        private CustomControl.TextBoxWithIcon.SnCollectionBox outboxcode;
+        private CustomControl.TextBoxWithIcon.EnterTextBox outboxcode;
         private CustomControl.ValueLabel.ValueLabel pr_cartongw;
         private CustomControl.ValueLabel.ValueLabel pr_code;
         private System.Windows.Forms.Label pr_cartongw_label;
@@ -857,6 +857,6 @@
         private System.Windows.Forms.Label weight_label;
         private System.Windows.Forms.Label weight;
         private System.Windows.Forms.Label label122;
-        private CustomControl.TextBoxWithIcon.SnCollectionBox lpn;
+        private CustomControl.TextBoxWithIcon.EnterTextBox lpn;
     }
 }

+ 26 - 0
UAS-MES/FunctionCode/Special/Special_Reset.Designer.cs

@@ -51,6 +51,8 @@
             this.OperatResult = new UAS_MES.CustomControl.RichText.RichTextAutoBottom();
             this.input = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
             this.Split = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
+            this.label1 = new System.Windows.Forms.Label();
+            this.remark = new UAS_MES.CustomControl.RichText.RichTextAutoBottom();
             this.SuspendLayout();
             // 
             // Pallet_label
@@ -146,6 +148,7 @@
             this.WeighRecord.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
             this.columnHeader3});
             this.WeighRecord.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.WeighRecord.HideSelection = false;
             this.WeighRecord.Location = new System.Drawing.Point(16, 162);
             this.WeighRecord.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3);
             this.WeighRecord.Name = "WeighRecord";
@@ -194,6 +197,7 @@
             this.oqcBtn.TabIndex = 248;
             this.oqcBtn.Text = "抽检批";
             this.oqcBtn.UseVisualStyleBackColor = true;
+            this.oqcBtn.Visible = false;
             this.oqcBtn.Click += new System.EventHandler(this.bigboxBtn_Click);
             // 
             // excelim
@@ -344,11 +348,31 @@
             this.Split.UseVisualStyleBackColor = false;
             this.Split.Click += new System.EventHandler(this.Split_Click);
             // 
+            // label1
+            // 
+            this.label1.AutoSize = true;
+            this.label1.Location = new System.Drawing.Point(707, 267);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(44, 18);
+            this.label1.TabIndex = 250;
+            this.label1.Text = "备注";
+            // 
+            // remark
+            // 
+            this.remark.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
+            this.remark.Location = new System.Drawing.Point(710, 302);
+            this.remark.Name = "remark";
+            this.remark.Size = new System.Drawing.Size(416, 193);
+            this.remark.TabIndex = 251;
+            this.remark.Text = "";
+            // 
             // Special_Reset
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
             this.ClientSize = new System.Drawing.Size(1208, 870);
+            this.Controls.Add(this.remark);
+            this.Controls.Add(this.label1);
             this.Controls.Add(this.oqcBtn);
             this.Controls.Add(this.excelim);
             this.Controls.Add(this.checkBox1);
@@ -403,5 +427,7 @@
         private CustomControl.ButtonUtil.NormalButton excelim;
         private System.Windows.Forms.OpenFileDialog openFileDialog1;
         private System.Windows.Forms.RadioButton oqcBtn;
+        private System.Windows.Forms.Label label1;
+        private CustomControl.RichText.RichTextAutoBottom remark;
     }
 }

+ 8 - 2
UAS-MES/FunctionCode/Special/Special_Reset.cs

@@ -58,13 +58,14 @@ namespace UAS_MES.Special
             //    dh.ExecuteSql("update makeserial set ms_bs = '',ms_key='',ms_keyid='',MS_HARDWREID='',MS_KEYSTATEID='',MS_BIOS='',ms_ec='',ms_uuid='',MS_KEYPARTNUMBER='',ms_bt='',ms_mac='',ms_imei='' where ms_sncode = '" + sncode + "' and ms_makecode = '" + ms_makecode.Text + "'", "update");
             //}
             dh.ExecuteSql("delete makebad where mb_sncode = '" + sncode + "' and mb_status = 0", "delete");
+            dh.ExecuteSql("delete OQCBATCHDETAIL where obd_sncode = '" + sncode + "' ", "delete");
             dh.ExecuteSql("delete from LABELPRINTLOG where lpl_value = '" + sncode + "'", "delete");
             sql.Clear();
             sql.Append("update craftmaterial set cm_status=-1,cm_lastdeco=-1,cm_dropman='" + User.UserCode + "',");
             sql.Append("cm_dropdate =sysdate,CM_REMARK = '重置站点拆解',cm_dropstep='" + User.CurrentStepCode + "',");
             sql.Append("cm_dropsccode='" + User.UserSourceCode + "' where cm_sncode = '" + sncode + "' and cm_stepcode in (select cd_stepcode from craftdetail left join step on st_code=cd_stepcode left join craft on cd_crid=cr_id where ST_STATUSCODE='AUDITED' and cr_code='" + cr_code.Text + "' and cr_prodcode='" + ms_prodcode.Text + "' and cd_detno >=" + cd_stepno.Text + " )");
             dh.ExecuteSql(sql.GetString(), "update");
-            LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ms_makecode.Text, User.UserLineCode, User.UserSourceCode, "站点重置", "站点重置至" + stname,  sncode, "");
+            LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ms_makecode.Text, User.UserLineCode, User.UserSourceCode, "站点重置", "重置SN 备注:" + remark.Text + " 站点重置至" + stname,  sncode, "");
         }
 
 
@@ -76,6 +77,11 @@ namespace UAS_MES.Special
                 OperatResult.AppendText(">>采集数与回流工位不能为空\n", Color.Red);
                 return;
             }
+            if (remark.Text == "")
+            {
+                OperatResult.AppendText(">>备注不能为空\n", Color.Red);
+                return;
+            }
             string Delete = MessageBox.Show(this.ParentForm, "是否确认重置站点?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question).ToString();
             if (Delete == "Yes")
             {
@@ -105,7 +111,7 @@ namespace UAS_MES.Special
                        dh.ExecuteSql("delete from LABELPRINTLOG where lpl_value = '" + sb[i].ToString() + "'", "delete");
                         //删除箱的明细
                         dh.ExecuteSql("delete from packagedetail where pd_outboxcode='" + sb[i].ToString() + "'", "delete");
-                        LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ms_makecode.Text, User.UserLineCode, User.UserSourceCode, "站点重置", "站点重置至" + stname, sb[i].ToString(), "");
+                        LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, ms_makecode.Text, User.UserLineCode, User.UserSourceCode, "站点重置", "重置箱 备注:" + remark.Text + " 站点重置至" + stname, sb[i].ToString(), "");
                         String ErrorMessage = "";
                         if (!LogicHandler.resetOutBoxStatus(sb[i].ToString(), out ErrorMessage))
                         {

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

@@ -143,7 +143,7 @@ namespace UAS_MES.PublicMethod
                     dic = BaseUtil.ToDictionary(Content);
                     if (!dic.ContainsKey("erpaccount"))
                     {
-                        oMsg = dic["code"].ToString();
+                        oMsg = dic["Code"].ToString();
                         //LogManager.DoLog("oMsg:"+ oMsg);
                         if (oMsg.Contains("200"))
                         {