Browse Source

微调界面

章政 8 years ago
parent
commit
9463b1008f

+ 37 - 37
UAS-MES/FunctionCode/Make/Make_Repair.Designer.cs

@@ -62,7 +62,11 @@
             this.ms_sncode = new UAS_MES.CustomControl.ValueLabel.ValueLabel();
             this.prodcode = new UAS_MES.CustomControl.TextBoxWithIcon.SearchTextBox();
             this.mbp_partdgv = new UAS_MES.CustomControl.DataGrid_View.DataGridViewWithCheckBox();
+            this.mbp_part1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.mbp_id = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.mbl_locdgv = new UAS_MES.CustomControl.DataGrid_View.DataGridViewWithCheckBox();
+            this.mbl_loc1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.mbl_id = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.RefreshTreeView = new UAS_MES.CustomControl.ClickPicBox.ClickPicBox();
             this.GetSNCode = new UAS_MES.CustomControl.TextBoxWithIcon.EnterTextBox();
             this.NewRepairInf = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
@@ -87,10 +91,6 @@
             this.SaveBadLocation = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
             this.Scrap = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
             this.RepairComplete = new UAS_MES.CustomControl.ButtonUtil.NormalButton();
-            this.mbl_loc1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.mbl_id = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.mbp_part1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.mbp_id = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.panel2.SuspendLayout();
             ((System.ComponentModel.ISupportInitialize)(this.LocationSource)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.ComponentSource)).BeginInit();
@@ -326,7 +326,7 @@
             this.label2.AutoSize = true;
             this.label2.Font = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
             this.label2.ForeColor = System.Drawing.Color.Black;
-            this.label2.Location = new System.Drawing.Point(12, 125);
+            this.label2.Location = new System.Drawing.Point(12, 127);
             this.label2.Name = "label2";
             this.label2.Size = new System.Drawing.Size(74, 22);
             this.label2.TabIndex = 117;
@@ -435,6 +435,21 @@
             this.mbp_partdgv.Size = new System.Drawing.Size(270, 152);
             this.mbp_partdgv.TabIndex = 121;
             // 
+            // mbp_part1
+            // 
+            this.mbp_part1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+            this.mbp_part1.DataPropertyName = "mbp_part";
+            this.mbp_part1.HeaderText = "已选择不良零件";
+            this.mbp_part1.Name = "mbp_part1";
+            this.mbp_part1.ReadOnly = true;
+            // 
+            // mbp_id
+            // 
+            this.mbp_id.DataPropertyName = "mbp_id";
+            this.mbp_id.HeaderText = "mbp_id";
+            this.mbp_id.Name = "mbp_id";
+            this.mbp_id.Visible = false;
+            // 
             // mbl_locdgv
             // 
             this.mbl_locdgv.AllowUserToAddRows = false;
@@ -449,16 +464,31 @@
             this.mbl_locdgv.Size = new System.Drawing.Size(270, 152);
             this.mbl_locdgv.TabIndex = 120;
             // 
+            // mbl_loc1
+            // 
+            this.mbl_loc1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
+            this.mbl_loc1.DataPropertyName = "mbl_loc";
+            this.mbl_loc1.HeaderText = "已选择不良位置";
+            this.mbl_loc1.Name = "mbl_loc1";
+            this.mbl_loc1.ReadOnly = true;
+            // 
+            // mbl_id
+            // 
+            this.mbl_id.DataPropertyName = "mbl_id";
+            this.mbl_id.HeaderText = "mbl_id";
+            this.mbl_id.Name = "mbl_id";
+            this.mbl_id.Visible = false;
+            // 
             // RefreshTreeView
             // 
             this.RefreshTreeView.AllPower = null;
             this.RefreshTreeView.Cursor = System.Windows.Forms.Cursors.Hand;
             this.RefreshTreeView.Image = global::UAS_MES.Properties.Resources.refresh;
-            this.RefreshTreeView.Location = new System.Drawing.Point(84, 126);
+            this.RefreshTreeView.Location = new System.Drawing.Point(89, 128);
             this.RefreshTreeView.Margin = new System.Windows.Forms.Padding(2);
             this.RefreshTreeView.Name = "RefreshTreeView";
             this.RefreshTreeView.Power = null;
-            this.RefreshTreeView.Size = new System.Drawing.Size(20, 22);
+            this.RefreshTreeView.Size = new System.Drawing.Size(20, 20);
             this.RefreshTreeView.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
             this.RefreshTreeView.TabIndex = 119;
             this.RefreshTreeView.TabStop = false;
@@ -864,36 +894,6 @@
             this.RepairComplete.UseVisualStyleBackColor = true;
             this.RepairComplete.Click += new System.EventHandler(this.RepairComplete_Click);
             // 
-            // mbl_loc1
-            // 
-            this.mbl_loc1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
-            this.mbl_loc1.DataPropertyName = "mbl_loc";
-            this.mbl_loc1.HeaderText = "已选择不良位置";
-            this.mbl_loc1.Name = "mbl_loc1";
-            this.mbl_loc1.ReadOnly = true;
-            // 
-            // mbl_id
-            // 
-            this.mbl_id.DataPropertyName = "mbl_id";
-            this.mbl_id.HeaderText = "mbl_id";
-            this.mbl_id.Name = "mbl_id";
-            this.mbl_id.Visible = false;
-            // 
-            // mbp_part1
-            // 
-            this.mbp_part1.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
-            this.mbp_part1.DataPropertyName = "mbp_part";
-            this.mbp_part1.HeaderText = "已选择不良零件";
-            this.mbp_part1.Name = "mbp_part1";
-            this.mbp_part1.ReadOnly = true;
-            // 
-            // mbp_id
-            // 
-            this.mbp_id.DataPropertyName = "mbp_id";
-            this.mbp_id.HeaderText = "mbp_id";
-            this.mbp_id.Name = "mbp_id";
-            this.mbp_id.Visible = false;
-            // 
             // Make_Repair
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);

+ 3 - 17
UAS-MES/FunctionCode/Make/Make_Repair.cs

@@ -263,9 +263,7 @@ namespace UAS_MES.Make
             //判断是否有无法维修的记录
             int ScrapNum = int.Parse(dh.getFieldDataByCondition("makebad", "count(0) cn", "mb_sncode='" + ms_sncode.Text + "'").ToString());
             if (ScrapNum == 0)
-            {
                 OperatResult.AppendText(">>存在无法维修的记录才允许报废\n", Color.Red);
-            }
             else
             {
                 string confirm = MessageBox.Show(this.ParentForm, "此操作不可撤销,是否确认报废", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Asterisk).ToString();
@@ -344,6 +342,9 @@ namespace UAS_MES.Make
                     string delete4 = "delete from makebadreason where mbr_id=" + mbr_id;
                     dh.ExecuteSQLTran(delete1, delete2, delete3, delete4);
                     OperatResult.AppendText(">>删除成功\n", Color.Green);
+                    BaseUtil.CleanControlsText(bc_name, bc_code, bg_name, bg_code, mb_badremark, nrg_name, nr_name, nr_code, mbr_solutioncode, mbr_dutycode, mbc_component);
+                    mbp_partdgv.DataSource = null;
+                    mbl_locdgv.DataSource = null;
                     mbr_id = "";
                     //删除后重新加载Tree的信息
                     LoadBadInfTree(sender, e);
@@ -381,21 +382,6 @@ namespace UAS_MES.Make
                 prodcode.TableName = dbtable2.Replace(":macode", macode).Replace(":sncode", GetSNCode.Text).Replace(":msl_location", mbl_loc.Text);
         }
 
-        /// <summary>
-        /// 加载不良零件Grid
-        /// </summary>
-        private void LoadBadPart()
-        {
-        }
-
-        /// <summary>
-        /// 加载不良位置信息
-        /// </summary>
-        private void LoadBadLocation()
-        {
-
-        }
-
         private void nr_name_TextChanged(object sender, EventArgs e)
         {
             if (nr_name.Text == "")

+ 6 - 6
UAS-MES/FunctionCode/Make/Make_Repair.resx

@@ -126,6 +126,12 @@
   <metadata name="mbp_part1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
+  <metadata name="mbp_part1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="mbl_loc1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
   <metadata name="mbl_loc1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
@@ -1178,12 +1184,6 @@
         ROJSU3qXjMKwG/vjzEz/skOI3Zqgv7AAAAAASUVORK5CYII=
 </value>
   </data>
-  <metadata name="mbl_loc1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
-  <metadata name="mbp_part1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
-    <value>True</value>
-  </metadata>
   <metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>42</value>
   </metadata>