| | |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | ds = oCN.RunProcReturn("Select * from Gy_BarCodeBill where HBarCode='" + list.packagebarcode.ToString().Trim() + "' and HStopflag='1'", "Gy_BarCodeBill"); |
| | | if (ds != null && ds.Tables[0].Rows.Count > 0) |
| | | { |
| | | objJsonResult.status = -1; |
| | | objJsonResult.msg = "æ¤ç®±æ¡ç å·²ä½åº"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | Models.ClsSc_PackUnionBillMain oItem = new ClsSc_PackUnionBillMain(); |
| | | oItem.HYear = DBUtility.ClsPub.isLong(DateTime.Now.Year); |
| | |
| | | oItem.HCheckItemNowID = 0; |
| | | oItem.HCheckItemNextID = 0; |
| | | oItem.HCheckFlowID = 0; |
| | | oItem.HRemark = "èªå¨å
è£
线çè¾°ç®±æ¡ç "; |
| | | oItem.HRemark = "èªå¨å
è£
线çæç®±æ¡ç "; |
| | | oItem.HBacker = ""; |
| | | oItem.HBackDate = ""; |
| | | oItem.HMaker = ""; |
| | |
| | | { |
| | | try |
| | | { |
| | | ds = oCN.RunProcReturn("Select * from Gy_BarCodeBill where HBarCode='" + packagebarcode.ToString().Trim() + "'", "Gy_BarCodeBill"); |
| | | if (ds == null && ds.Tables[0].Rows.Count == 0) |
| | | { |
| | | objJsonResult.status = -1; |
| | | objJsonResult.msg = "æ æç®±æ¡ç "; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | ds = oCN.RunProcReturn("Select * from Gy_BarCodeBill where HBarCode='" + packagebarcode.ToString().Trim() + "' and HStopflag='1'", "Gy_BarCodeBill"); |
| | | if (ds != null && ds.Tables[0].Rows.Count>0) |
| | | { |
| | | objJsonResult.status = -1; |
| | | objJsonResult.msg = "æ¤ç®±æ¡ç å·²ä½åº"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | // |
| | | oCN.BeginTran(); |
| | | //å é¤å表 |
| | | oCN.RunProc("Delete From Sc_PackUnionBillSub where HBarCode_Pack=" + packagebarcode.ToString()); |
| | | oCN.RunProc("Delete From Sc_PackUnionBillSub where HBarCode_Pack='"+ packagebarcode.ToString() + "'"); |
| | | //å é¤ä¸»è¡¨ |
| | | oCN.RunProc("Delete From Sc_PackUnionBillMain where HBarCode_Pack=" + packagebarcode.ToString()); |
| | | oCN.RunProc("Delete From Sc_PackUnionBillMain where HBarCode_Pack='" + packagebarcode.ToString() + "'"); |
| | | //ä½åºæ¡ç æ¡£æ¡è¡¨ |
| | | oCN.RunProc("Update Gy_BarCodeBill set HStopflag='1' where HBarCode=" + packagebarcode.ToString()); |
| | | oCN.RunProc("Update Gy_BarCodeBill set HStopflag='1' where HBarCode='"+ packagebarcode .ToString()+ "'"); |
| | | |
| | | oCN.Commit(); |
| | | |