| | |
| | | { |
| | | if (oSystemParameter.omodel.WMS_CampanyName == "瑞与祺") |
| | | { |
| | | |
| | | //判断金蝶云是否已经有入库的数据 |
| | | ds = oCN.RunProcReturn($@"select * from AIS20220308151944..T_PRD_INSTOCK where FBILLNO='{BillNo}'", "T_PRD_INSTOCK"); |
| | | |
| | | if (ds.Tables[0].Rows.Count > 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "当前出站单号已入库,请不要重新入库!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | //判断金蝶云生产汇报单 数量 是否 大于 末道出站数量 |
| | | ds = oCN.RunProcReturn($@"select sum(FFinishQty)-(select HQty from Sc_StationOutBillMain where HBillNo='{BillNo}') |
| | | ds = oCN.RunProcReturn($@"select sum(FFinishQty)-sum(FSTOCKINQUASELQTY)-(select HQty from Sc_StationOutBillMain where HBillNo='{BillNo}') |
| | | from AIS20220308151944..T_PRD_MORPT rpt3 |
| | | left join AIS20220308151944..T_PRD_MORPTENTRY rpt2 on rpt3.FID = rpt2.FID |
| | | left join AIS20220308151944..T_PRD_MORPTENTRY_A rpt1 on rpt2.FID = rpt1.FID |
| | | where F_bsv_Text=(select HProcExchBillNo from Sc_StationOutBillMain where HBillNo='{BillNo}')", "SumCount"); |
| | | |
| | | if (double.Parse(ds.Tables[0].Rows[0][0].ToString()) < 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "金蝶云汇报数量小于本地出站数量!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | if (double.Parse(ds.Tables[0].Rows[0][0].ToString()) < 0) { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "金蝶云汇报数量小于本地出站数量!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | |
| | | |
| | | JObject model = new JObject(); |
| | |
| | | Int64 HSourceEntryID, string HSourceBillNo, string user, |
| | | Int64 HWHID, Int64 HSPID, Int64 HSupID, Int64 HKeeperID, |
| | | Int64 HMaterID, string HSourceBillType, Int64 HSLInterID, |
| | | Int64 HSLEntryID, string HSLBillNo, Int64 HSLSeQ, string HBillNo, Int64 HInterID) |
| | | Int64 HSLEntryID, string HSLBillNo, Int64 HSLSeQ, string HBillNo, Int64 HInterID, string HBatchNo) |
| | | { |
| | | try |
| | | { |
| | |
| | | FentityModel.Add("FBaseAcceptQty", HRightQty.ToString());//基本单位接收数 |
| | | FentityModel.Add("FCurrency", new JObject() { ["Fnumber"] = "PRE001" });//币别 |
| | | FentityModel.Add("FIsSplitRow ", false);// 是否拆分行 |
| | | FentityModel.Add("FLot", new JObject() { ["Fnumber"] = HBatchNo.ToString() });//批号 |
| | | |
| | | JArray Fentity2 = new JArray(); |
| | | JObject FentityModel2 = new JObject(); |
| | |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |