From d1b14d00d9ee4ff4a1b271e6b4fe094f5049a55f Mon Sep 17 00:00:00 2001 From: duhe <226547893@qq.com> Date: 星期一, 17 三月 2025 09:23:16 +0800 Subject: [PATCH] 采购入库单:下推采购退料单 --- WebAPI/Controllers/SBGL/Sb_EquipDotCheckBillController.cs | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 53 insertions(+), 0 deletions(-) diff --git a/WebAPI/Controllers/SBGL/Sb_EquipDotCheckBillController.cs b/WebAPI/Controllers/SBGL/Sb_EquipDotCheckBillController.cs index 75eab75..87392d2 100644 --- a/WebAPI/Controllers/SBGL/Sb_EquipDotCheckBillController.cs +++ b/WebAPI/Controllers/SBGL/Sb_EquipDotCheckBillController.cs @@ -107,6 +107,59 @@ } } + #region 璁惧鐐规璁板綍鍒嗛〉鏌ヨ + [Route("Sb_EquipDotCheckBill/GetEquipDotCheckBillListPage")] + [HttpGet] + public object GetEquipDotCheckBillListPage(string sWhere, string user, int page, int size) + { + try + { + List<object> columnNameList = new List<object>(); + //缂栬緫鏉冮檺 + if (!DBUtility.ClsPub.Security_Log_second("Sb_EquipDotCheckBillList", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犳煡鐪嬫潈闄愶紒"; + objJsonResult.data = null; + return objJsonResult; + } + sWhere = sWhere.Replace("'", "''"); + if (sWhere == null || sWhere.Equals("")) + { + ds = oCN.RunProcReturn("exec h_p_Sb_EquipDotCheckBillListPage " + page + "," + size + ",''", "h_p_Sb_EquipDotCheckBillListPage"); + } + else + { + ds = oCN.RunProcReturn("exec h_p_Sb_EquipDotCheckBillListPage " + page + "," + size + ",'" + sWhere + "'", "h_p_Sb_EquipDotCheckBillListPage"); + } + + //娣诲姞鍒楀悕 + foreach (DataColumn col in ds.Tables[0].Columns) + { + Type dataType = col.DataType; + string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}"; + columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕 + } + + objJsonResult.code = "1"; + objJsonResult.count = int.Parse(ds.Tables[1].Rows[0]["count"].ToString()); + objJsonResult.Message = "Sucess锛�"; + objJsonResult.list = columnNameList; + objJsonResult.data = ds.Tables[0]; + return objJsonResult; + } + catch (Exception e) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "Exception锛�" + e.ToString(); + objJsonResult.data = null; + return objJsonResult; + } + } + #endregion + #region sql璇彞 -- Gitblit v1.9.1