From ad7bec1313df110892242c6dab7848b8df61a1e0 Mon Sep 17 00:00:00 2001 From: zgq <519541279@qq.com> Date: 星期三, 30 六月 2021 09:08:21 +0800 Subject: [PATCH] 调拨单新增参数‘源单号’ --- WebAPI/Controllers/Xs_CutWorkSendBillController.cs | 45 +++++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 43 insertions(+), 2 deletions(-) diff --git a/WebAPI/Controllers/Xs_CutWorkSendBillController.cs b/WebAPI/Controllers/Xs_CutWorkSendBillController.cs index a8319b0..61b1388 100644 --- a/WebAPI/Controllers/Xs_CutWorkSendBillController.cs +++ b/WebAPI/Controllers/Xs_CutWorkSendBillController.cs @@ -101,7 +101,7 @@ + list[i].HMainSourceBillNo + "'," + list[i].HMainSourceInterID + ")"; oCN.RunProc(subSql); //鍙嶅啓閲戣澏閿�鍞鍗曠殑瑁佸垏娲惧伐鐝粍 - var HGroupSql = "update AIS20200908101915zs..T_SAL_ORDER set F_XSDD_PGSJ=GETDATE(),F_XSDD_PGBZ=(select HName from Gy_Group where HItemID=" + list[i].HGroupID + ") where FID = " + list[i].HMainSourceInterID + ""; + var HGroupSql = "update AIS20200908101915zs..T_SAL_ORDERENTRY set F_XSDD_PGSJ=GETDATE(),F_XSDD_PGBZ=(select HName from Gy_Group where HItemID=" + list[i].HGroupID + ") where FID = " + list[i].HMainSourceInterID + ""; oCN.RunProc(HGroupSql); } oCN.Commit(); @@ -122,6 +122,44 @@ } } + /// <summary> + /// 涓婁笅鏋跺崟鍒楄〃 + /// </summary> + /// <returns></returns> + [Route("Xs_CutWorkSendBill/List")] + [HttpGet] + public object List(string sWhere) + { + try + { + ds = List_s(sWhere); + if (ds == null || ds.Tables[0].Rows.Count <= 0) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "娌℃湁杩斿洖浠讳綍璁板綍锛�"; + objJsonResult.data = null; + return objJsonResult; + } + else + { + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = "杩斿洖璁板綍鎴愬姛锛�"; + objJsonResult.data = ds.Tables[0]; + return objJsonResult; + } + } + catch (Exception ex) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "娌℃湁杩斿洖浠讳綍璁板綍锛�" + ex.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #region sql璇彞 @@ -132,7 +170,10 @@ "select FID HMainSourceInterID,FBILLNO HMainSourceBillNo,1 pages,'' HMaker from AIS20200908101915zs..T_SAL_ORDER where FBILLNO ='" + HSEOrderBillNo + "'" , "AIS20200908101915zs..T_SAL_ORDER"); } - + public static DataSet List_s(string sWhere) + { + return new SQLHelper.ClsCN().RunProcReturn("select * from h_v_Xs_CutWorkSendBillList where 1=1 " + sWhere , "h_v_Xs_CutWorkSendBillList"); + } #endregion -- Gitblit v1.9.1