Hcsy 7 years ago
parent
commit
d57c8d7934

+ 8 - 3
UAS-MES/FunctionCode/Make/Make_PackageCollection.cs

@@ -565,8 +565,13 @@ namespace UAS_MES.Make
         {
             if (dh.CheckExist("package", "pa_outboxcode='" + pa_outboxcode.Text + "' and nvl(pa_status,0)=0"))
             {
-
-                string Seal = MessageBox.Show(this.ParentForm, "是否确认封箱?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question).ToString();
+                string Seal = "";
+                if (sender != "true")
+                {
+                    Seal = MessageBox.Show(this.ParentForm, "是否确认封箱?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question).ToString();
+                }
+                else
+                    Seal = "Yes";
                 if (Seal == "Yes")
                 {
                     LoadData();
@@ -976,7 +981,7 @@ namespace UAS_MES.Make
                         LoadGridData();
                         if (int.Parse(pa_currentqty.Text == "" ? "0" : pa_currentqty.Text) == int.Parse(pr_outboxinnerqty.Text))
                         {
-                            Packing_Click(new object(), new EventArgs());
+                            Packing_Click("true", new EventArgs());
                         }
                         if (!AutoGenBoxCode.Checked)
                         {

+ 8 - 2
UAS-MES/FunctionCode/Make/Make_PackageCollectionWeigh.cs

@@ -596,7 +596,13 @@ namespace UAS_MES.Make
         {
             if (dh.CheckExist("package", "pa_outboxcode='" + pa_outboxcode.Text + "' and nvl(pa_status,0)=0"))
             {
-                string Seal = MessageBox.Show(this.ParentForm, "是否确认封箱?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question).ToString();
+                string Seal = "";
+                if (sender != "true")
+                {
+                    Seal = MessageBox.Show(this.ParentForm, "是否确认封箱?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question).ToString();
+                }
+                else
+                    Seal = "Yes";
                 if (Seal == "Yes")
                 {
                     LoadData();
@@ -988,7 +994,7 @@ namespace UAS_MES.Make
                         LoadGridData();
                         if (int.Parse(pa_currentqty.Text == "" ? "0" : pa_currentqty.Text) == int.Parse(pr_outboxinnerqty.Text))
                         {
-                            Packing_Click(new object(), new EventArgs());
+                            Packing_Click("true", new EventArgs());
                         }
                         if (!AutoGenBoxCode.Checked)
                         {