| | |
| | | |
| | | HEntryID = j + 1; |
| | | HBarCode = TM.ToUpper(); |
| | | if (cmbHCusName.Text.Contains("䏿¹éä¿¡")) |
| | | { |
| | | HBarCodeType = "䏿¹éä¿¡å
ç®±ç "; |
| | | } |
| | | else |
| | | { |
| | | HBarCodeType = "æ°åä¸å
ç®±ç "; |
| | | } |
| | | HMaterID = ClsPub.isLong(grdMain.Rows[j].Cells[HMaterIDCol].Value); |
| | | HBatchNo = sYear4 + sPeriod2 + sDay; |
| | | HUnitID = ClsPub.isLong(grdMain.Rows[j].Cells[HUnitIDCol].Value); |
| | |
| | | HInnerBillNo = ClsPub.isStrNull(grdMain.Rows[j].Cells[HInnerBillNoCol].Value); //éå®è®¢åå· |
| | | |
| | | //è·åæå¤§æµæ°´å· |
| | | //æ¡ç åç¼ = ä¾åºå代ç + éå®è®¢åå· |
| | | sWTMNumber = "151091" + HInnerBillNo; |
| | | //æ¡ç åç¼ = 2ä½åºå®ç ï¼'09'ï¼ + CPN客æ·ç¼ç ï¼è§æ ¼åå·ï¼+ 2ä½é¢çç ï¼åºå®'01'ï¼+ 5ä½å¹´å¹´ææ¥æ¥ï¼YYMDDï¼ + 3ä½09ç æµæ°´å·ï¼åºå®'001'ï¼ + ä¾åºå代ç ï¼åºå®'151091'ï¼ |
| | | sWTMNumber = "09" + HMaterModel + "01" + sYear + sPeriod + sDay + "001151091"; |
| | | Ds = oCn.RunProcReturn("exec h_p_WMS_GetMaxNo '" + sWTMNumber + "'", "h_p_WMS_GetMaxNo"); //è·åæå¤§æµæ°´å· |
| | | LWSH = ClsPub.isLong(Ds.Tables[0].Rows[0][0]); |
| | | |
| | |
| | | } |
| | | |
| | | //æ¡ç ç¼å· = 2ä½åºå®ç ï¼'09'ï¼ + CPN客æ·ç¼ç ï¼è§æ ¼åå·ï¼+ 2ä½é¢çç ï¼åºå®'01'ï¼+ 5ä½å¹´å¹´ææ¥æ¥ï¼YYMDDï¼ + 3ä½09ç æµæ°´å·ï¼åºå®'001'ï¼ + ä¾åºå代ç ï¼åºå®'151091'ï¼+ 3使µæ°´å· |
| | | TM = "09" + HMaterModel + "01" + sYear + sPeriod + sDay + "001151091" + LSH2; |
| | | TM = sWTMNumber + LSH2; |
| | | |
| | | HEntryID = j + 1; |
| | | HBarCode = TM.ToUpper(); |
| | | if (cmbHCusName.Text.Contains("䏿¹éä¿¡")) |
| | | { |
| | | HBarCodeType = "䏿¹éä¿¡å¤ç®±ç "; |
| | | } |
| | | else |
| | | { |
| | | HBarCodeType = "æ°åä¸å¤ç®±ç "; |
| | | } |
| | | HMaterID = ClsPub.isLong(grdMain.Rows[j].Cells[HMaterIDCol].Value); |
| | | HBatchNo = sYear4 + sPeriod2 + sDay; |
| | | HUnitID = ClsPub.isLong(grdMain.Rows[j].Cells[HUnitIDCol].Value); |
| | |
| | | private void Display() |
| | | { |
| | | //å·æ°å
ç®±ç å表 |
| | | DataSet DSet = oCn.RunProcReturn("select * from h_v_Gy_BarCodeBill_CusList where HInterID=" + HInterID.ToString() + " and æ¡ç ç±»å='æ°åä¸å
ç®±ç ' order by HItemID", "h_v_Gy_BarCodeBill_CusList", ref DBUtility.ClsPub.sExeReturnInfo); |
| | | DataSet DSet = oCn.RunProcReturn("select * from h_v_Gy_BarCodeBill_CusList where HInterID=" + HInterID.ToString() + " and (æ¡ç ç±»å='æ°åä¸å
ç®±ç ' or æ¡ç ç±»å='䏿¹éä¿¡å
ç®±ç ) order by HItemID", "h_v_Gy_BarCodeBill_CusList", ref DBUtility.ClsPub.sExeReturnInfo); |
| | | //çæé¦è¡æ é¢ |
| | | if (DSet == null) |
| | | { |
| | |
| | | grdSub.DataSource = DSet.Tables[0].DefaultView; |
| | | |
| | | //å·æ°å¤ç®±ç å表 |
| | | DataSet DWSet = oCn.RunProcReturn("select * from h_v_Gy_BarCodeBill_CusList where HInterID=" + HInterID.ToString() + " and æ¡ç ç±»å='æ°åä¸å¤ç®±ç ' order by HItemID", "h_v_Gy_BarCodeBill_CusList", ref DBUtility.ClsPub.sExeReturnInfo); |
| | | DataSet DWSet = oCn.RunProcReturn("select * from h_v_Gy_BarCodeBill_CusList where HInterID=" + HInterID.ToString() + " and (æ¡ç ç±»å='æ°åä¸å¤ç®±ç ' or æ¡ç ç±»å='䏿¹éä¿¡å¤ç®±ç ) order by HItemID", "h_v_Gy_BarCodeBill_CusList", ref DBUtility.ClsPub.sExeReturnInfo); |
| | | //çæé¦è¡æ é¢ |
| | | if (DWSet == null) |
| | | { |
| | |
| | | grdMain.Columns[HEXPPERIODCol].Visible = false; |
| | | grdMain.Columns[HLSHCol].Visible = false; |
| | | grdMain.Columns[HBaNoCol].Visible = false; |
| | | grdMain.Columns[HCusModelNameCol].Visible = false; |
| | | //grdMain.Columns[HCusModelNameCol].Visible = false; |
| | | grdMain.Columns[HCusModelCol].Visible = false; |
| | | grdMain.Columns[HBatchNoCol].Visible = false; |
| | | grdMain.Columns[HCode1Col].Visible = false; |
| | |
| | | { |
| | | try |
| | | { |
| | | oCn.RunProc("update Gy_BarCodeBill_Cus set HPrintQty=isnull(HPrintQty,0)+1 where HBarCodeType='æ°åä¸å
ç®±ç ' and HInterID=" + HInterID, ref DBUtility.ClsPub.sExeReturnInfo); |
| | | oCn.RunProc("update Gy_BarCodeBill_Cus set HPrintQty=isnull(HPrintQty,0)+1 where HBarCodeType in ('æ°åä¸å
ç®±ç ','䏿¹éä¿¡å
ç®±ç ') and HInterID=" + HInterID, ref DBUtility.ClsPub.sExeReturnInfo); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | |
| | | { |
| | | try |
| | | { |
| | | oCn.RunProc("update Gy_BarCodeBill_Cus set HPrintQty=isnull(HPrintQty,0)+1 where HBarCodeType='æ°åä¸å¤ç®±ç ' and HInterID=" + HInterID, ref DBUtility.ClsPub.sExeReturnInfo); |
| | | oCn.RunProc("update Gy_BarCodeBill_Cus set HPrintQty=isnull(HPrintQty,0)+1 where HBarCodeType in ('æ°åä¸å¤ç®±ç ','䏿¹éä¿¡å¤ç®±ç ') and HInterID=" + HInterID, ref DBUtility.ClsPub.sExeReturnInfo); |
| | | } |
| | | catch (Exception e) |
| | | { |