From 8c0257244b7292ad6326d0ac0d909d1e78935ebd Mon Sep 17 00:00:00 2001 From: yusijie <ysj@hz-kingdee.com> Date: 星期二, 12 十二月 2023 13:56:49 +0800 Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-API --- WebAPI/Controllers/CJGL/Cj_SingleStationController.cs | 34 +++++++++++++++++----------------- 1 files changed, 17 insertions(+), 17 deletions(-) diff --git a/WebAPI/Controllers/CJGL/Cj_SingleStationController.cs b/WebAPI/Controllers/CJGL/Cj_SingleStationController.cs index 79f48fe..5346ce3 100644 --- a/WebAPI/Controllers/CJGL/Cj_SingleStationController.cs +++ b/WebAPI/Controllers/CJGL/Cj_SingleStationController.cs @@ -502,7 +502,7 @@ ,HSourceBillType,HMaterID,HSourceID,HEquipID,HUnitID,HQty ,HGroupID,HWorkerID,HScanDate,HBarCode,HBarCode_P,HSNNumber) values({HInterID1},'{HBillNo1}',{(i + 1)},0,0,'' -,'',{sub[i].HMaterID},0,0,0,{sub[i].HQty} +,'',{sub[i].HMaterID},0,0,0,1 ,0,0,getdate(),'{sub[i].HBarCode}','{omodel.HBarCode_P}','') "; oCN.RunProc(sq2); } @@ -939,7 +939,7 @@ #region 宸ュ簭鍗曞搧杩囩珯 鏌ヨ涓嶈壇璁板綍 [Route("Cj_SingleStation/BadRecordsList")] [HttpGet] - public object BadRecordsList(string HBarCode, string user) + public object BadRecordsList(string HProcExchInterID, string HProcExchEntryID, string user) { try { @@ -953,12 +953,12 @@ return objJsonResult; } - ds = oCN.RunProcReturn(@"select * from h_v_Gy_BadRecordsList where HProcExchBillNo='" + HBarCode + "'", "h_v_Gy_BadRecordsList"); + ds = oCN.RunProcReturn(@"exec h_p_Gy_BadRecordsList " + HProcExchInterID + "," + HProcExchEntryID, "h_p_Gy_BadRecordsList"); objJsonResult.code = "1"; objJsonResult.count = 1; objJsonResult.Message = ""; - objJsonResult.data = ds.Tables[0]; + objJsonResult.data = ds; return objJsonResult; } catch (Exception e) @@ -1392,24 +1392,24 @@ if (HResult == "OK") { - ds = oCN.RunProcReturn("select * from Sc_SourceLineRepairBillSub where HInterID=" + model.HInterID, "Sc_SourceLineRepairBillSub"); +// ds = oCN.RunProcReturn("select * from Sc_SourceLineRepairBillSub where HInterID=" + model.HInterID, "Sc_SourceLineRepairBillSub"); - if (ds.Tables[0].Rows[0]["HRepairResult"].ToString() == "OK") - { +// if (ds.Tables[0].Rows[0]["HRepairResult"].ToString() == "OK") +// { - //鐢熶骇宸ュ簭鍑虹珯SN鏁版嵁 - ds = oCN.RunProcReturn("select top 1 HInterID,HBillNo from Sc_StationOutBillMain where HProcExchInterID=" + model.HProcExchInterID + " and HProcExchEntryID=" + model.HProcExchEntryID + " and HBadCount<>0 order by HInterID desc", "Sc_StationOutBillMain"); +// //鐢熶骇宸ュ簭鍑虹珯SN鏁版嵁 +// ds = oCN.RunProcReturn("select top 1 HInterID,HBillNo from Sc_StationOutBillMain where HProcExchInterID=" + model.HProcExchInterID + " and HProcExchEntryID=" + model.HProcExchEntryID + " and HBadCount<>0 order by HInterID desc", "Sc_StationOutBillMain"); - string HInterIDSN = ds.Tables[0].Rows[0]["HInterID"].ToString(); - string HBillNoSN = ds.Tables[0].Rows[0]["HBillNo"].ToString(); +// string HInterIDSN = ds.Tables[0].Rows[0]["HInterID"].ToString(); +// string HBillNoSN = ds.Tables[0].Rows[0]["HBillNo"].ToString(); - ds = oCN.RunProcReturn("select * from Sc_StationOutBillSub_SN where HInterID=" + HInterIDSN, "Sc_StationOutBillSub_SN"); +// ds = oCN.RunProcReturn("select * from Sc_StationOutBillSub_SN where HInterID=" + HInterIDSN, "Sc_StationOutBillSub_SN"); - oCN.RunProc($@"insert into Sc_StationOutBillSub_SN(HInterID,HBillNo_bak,HEntryID,HBarCode,HBarCodeQty,HMakeTime,HRemark,HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney) -values({HInterIDSN}, '{HBillNoSN}', {ds.Tables[0].Rows.Count + 1}, '{model.HBarCode}', 1, GETDATE(), '', " + model.HProcExchInterID + "," + model.HProcExchEntryID + ", '" + model.HProcExchBillNo + "', '', 0, 0)"); - //鍙嶅啓宸ュ簭鍑虹珯鍗� 涓昏〃 涓嶈壇鏁伴噺 鍜� 鍚堟牸鏁伴噺 - oCN.RunProc("update Sc_StationOutBillMain set HQty+=1,HBadCount-=1 where HInterID='" + HInterIDSN + "'"); - } +// oCN.RunProc($@"insert into Sc_StationOutBillSub_SN(HInterID,HBillNo_bak,HEntryID,HBarCode,HBarCodeQty,HMakeTime,HRemark,HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney) +//values({HInterIDSN}, '{HBillNoSN}', {ds.Tables[0].Rows.Count + 1}, '{model.HBarCode}', 1, GETDATE(), '', " + model.HProcExchInterID + "," + model.HProcExchEntryID + ", '" + model.HProcExchBillNo + "', '', 0, 0)"); +// //鍙嶅啓宸ュ簭鍑虹珯鍗� 涓昏〃 涓嶈壇鏁伴噺 鍜� 鍚堟牸鏁伴噺 +// oCN.RunProc("update Sc_StationOutBillMain set HQty+=1,HBadCount-=1 where HInterID='" + HInterIDSN + "'"); +// } oCN.RunProc("update Gy_BarCodeBill set HStatus='' where HBarCode='" + model.HBarCode + "'"); } -- Gitblit v1.9.1