| | |
| | | } |
| | | #endregion |
| | | |
| | | #region ç产å
¥åºåå表å页å表 |
| | | [Route("Kf_ProductInBillController/page")] |
| | | [HttpGet] |
| | | public json Sc_MouldProdOutBillPage(string sWhere, string user, int page, int size, string Type) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | //å表è¿å
¥æ¶å¤ææéï¼éæºåè¿å
¥ä¸å¤ææé |
| | | if (Type == ModName) |
| | | { |
| | | if (!DBUtility.ClsPub.Security_Log(ModRightNameList, 3, 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_Kf_ProductInBillList " + page + "," + size + ",'','" + Type + "'", "h_p_Kf_ProductInBillList"); |
| | | } |
| | | else |
| | | { |
| | | ds = oCn.RunProcReturn("exec h_p_Kf_ProductInBillList " + page + "," + size + ",'" + sWhere + "','" + Type + "'", "h_p_Kf_ProductInBillList"); |
| | | } |
| | | |
| | | //æ·»å åå |
| | | 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));//è·åå°DataColumnå对象çåå |
| | | } |
| | | |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "æåï¼"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | objJsonResult.list = columnNameList; |
| | | return objJsonResult; |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "æ¥è¯¢å表信æ¯å¤±è´¥ï¼" + e.ToString(); |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | #endregion |
| | | |
| | | #region ç产å
¥åºå å é¤ |
| | | /// <summary> |
| | | /// å é¤ç产å
¥åºå |