| | |
| | | DateTime HEndDate; //计åå®å·¥æ¥æ |
| | | |
| | | oCn.BeginTran(); |
| | | Application.DoEvents(); |
| | | //è·åå䏿¹çææ¡ç æ»ç®±æ° |
| | | for (int j = 0; j < grdMain.Rows.Count; j++) |
| | | { |
| | | Application.DoEvents(); |
| | | if (ClsPub.isLong(grdMain.Rows[j].Cells[HMaterIDCol].Value) != 0) |
| | | { |
| | | HSumBQty = HSumBQty + ClsPub.isInt(grdMain.Rows[j].Cells[HBQtyCol].Value); |
| | | pb1.Maximum = HSumBQty; |
| | | } |
| | | } |
| | | for (int j = 0; j < grdMain.Rows.Count; j++) |
| | | { |
| | | if (ClsPub.isLong(grdMain.Rows[j].Cells[HMaterIDCol].Value) != 0) |
| | | { |
| | | sMaterID = DBUtility.ClsPub.isStrNull(grdMain.Rows[j].Cells[HMaterIDCol].Value); |
| | |
| | | HBQty = ClsPub.isLong(grdMain.Rows[j].Cells[HBQtyCol].Value); |
| | | HMinQty = ClsPub.isDoule(grdMain.Rows[j].Cells[HMinQtyCol].Value); |
| | | HSumQty = ClsPub.isDoule(grdMain.Rows[j].Cells[HQtyCol].Value); |
| | | HSumBQty = HSumBQty + ClsPub.isInt(grdMain.Rows[j].Cells[HBQtyCol].Value); |
| | | pb1.Maximum = HSumBQty; |
| | | |
| | | int nn = 0; //æ¬æ¬¡æµæ°´å·ç´¯è®¡ä½¿ç¨ä¸ªæ° |
| | | for (int i = 0; i < HBQty; i++) |
| | | { |
| | | pb1.Value = n+1; |
| | | if (HSumQty - HMinQty > 0) |
| | | { |
| | | HEndQty = ""; |
| | |
| | | + ", " + HCusID.ToString() + ",'" + HCusType + "','" + HSeOrderBillNo + "'," + HSeOrderSEQ.ToString() + ",'" + HInnerBillNo + "','" + HWorkLineName + "'" |
| | | + ",'" + HMaterName + "','" + HMaterModel + "','" + HPinfan + "','" + HEndDate.ToShortDateString() + "','" + ClsPub.CurUserName + "',getdate()" + |
| | | ")"); |
| | | pb1.Value = n + 1; |
| | | n = n + 1; |
| | | Application.DoEvents(); |
| | | nn = nn + 1; |
| | | } |
| | | //åå¡«æµæ°´å·ä¿¡æ¯ |
| | | oCn.RunProc("exec h_p_WMS_SetMaxNo_QTY '" + sTMNumber + "'," + nn.ToString() + " "); |
| | | } |
| | | } |
| | | oCn.Commit(); |