Browse Source

修改打印日期到全部打印完才记录打印时间

章政 8 năm trước cách đây
mục cha
commit
8cd03fa88a
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      UAS-出货标签管理/UAS_出货标签管理.cs

+ 2 - 2
UAS-出货标签管理/UAS_出货标签管理.cs

@@ -1163,7 +1163,7 @@ namespace UAS_LabelMachine
                         //如果不存在中盒号则进行添加
                         if (!MidIDAndOutboxcode.ContainsValue(LabelInf.Rows[i].Cells["pib_outboxcode1"].Value.ToString()))
                             MidIDAndOutboxcode.Add(LabelInf.Rows[i].Cells["pib_id1"].Value.ToString(), LabelInf.Rows[i].Cells["pib_outboxcode1"].Value.ToString());
-                    }  
+                    }
                 }
                 if (SingleID.ToArray().Length == 0)
                 {
@@ -1236,7 +1236,6 @@ namespace UAS_LabelMachine
                             SingleDoc.Save();
                             SingleDoc.Printer.SwitchTo(SingleLabelPrinter.Text);
                             SingleDoc.PrintDocument();
-                            dh.ExecuteSql("update prodiobarcode set pib_printdate=sysdate where pib_id=:pib_id","select",pib_id);
                             //勾选为已打印
                             LabelInf.Rows[i].Cells["pib_ifprint"].Value = true;
                         }
@@ -1258,6 +1257,7 @@ namespace UAS_LabelMachine
                         }
                     }
                 }
+                dh.BatchInsert("update prodiobarcode set pib_printdate=sysdate where pib_id=:pib_id", new string[] { "pib_id" }, SingleID.ToArray());
                 if (CheckedRowCount == 0)
                     MessageBox.Show("未勾选打印明细!");
                 else if (CurrentRowIndex + 1 < LabelInf.Rows.Count)