| | |
| | | } |
| | | } |
| | | #endregion |
| | | |
| | | #region è´¨éæ¨¡å å¼å¸¸åé¦åææ¥è¡¨ æ¥è¯¢ |
| | | |
| | | [Route("QC_CustomerAppealReport/getOA_ErrMsgBackBillList_Query")] |
| | | [HttpGet] |
| | | public object getOA_ErrMsgBackBillList_Query(string sWhere, string user) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | if (sWhere == null || sWhere.Equals("")) |
| | | { |
| | | ds = oCN.RunProcReturn("select * from h_v_OA_ErrMsgBackBillList_Query order by æ¥æ desc", "h_v_OA_ErrMsgBackBillList_Query"); |
| | | } |
| | | else |
| | | { |
| | | string sql1 = "select * from h_v_OA_ErrMsgBackBillList_Query where 1 = 1 "; |
| | | string sql = sql1 + sWhere + " order by æ¥æ "; |
| | | ds = oCN.RunProcReturn(sql, "h_v_OA_ErrMsgBackBillList_Query"); |
| | | } |
| | | |
| | | //æ·»å åå |
| | | 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 = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "Sucessï¼"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | objJsonResult.list = columnNameList; |
| | | return objJsonResult; |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "Exceptionï¼" + e.ToString(); |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | #endregion |
| | | |
| | | #region è´¨éæ¨¡å å¼å¸¸ç®¡çå°è´¦ |
| | | /// <summary> |
| | | /// è¿åå¼å¸¸ç®¡çå°è´¦ |
| | | ///åæ°ï¼string sqlã |
| | | ///è¿åå¼ï¼objectã |
| | | /// </summary> |
| | | [Route("QC_CustomerAppealReport/QC_ErrManagerLedgerReport")] |
| | | [HttpGet] |
| | | public object QC_ErrManagerLedgerReport(string sWhere, string user) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | if (sWhere == null || sWhere == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "æ æ¥è¯¢æ¡ä»¶ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | Dictionary<object, object> dic = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<object, object>>(sWhere); |
| | | |
| | | |
| | | string HBeginDate = dic["HBeginDate"].ToString(); |
| | | string HEndDate = dic["HEndDate"].ToString(); |
| | | int HDeptID = int.Parse(dic["HDeptID"].ToString()); |
| | | string HMaterModel = dic["HMaterModel"].ToString(); |
| | | string HSourceName = dic["HSourceName"].ToString(); |
| | | string HProSource = dic["HProSource"].ToString(); |
| | | string HShiftsName = dic["HShiftsName"].ToString(); |
| | | string HCustomize = dic["HCustomize"].ToString(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_QC_ErrManagerLedgerReport '" + HBeginDate + "','" + HEndDate + "'," + HDeptID + ",'" + HMaterModel + "','" + HSourceName + "','" + HProSource + "','" + HShiftsName + "','" + HCustomize + "'", "h_p_QC_ErrManagerLedgerReport"); |
| | | |
| | | //æ·»å åå |
| | | 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 = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "Sucessï¼"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | objJsonResult.list = columnNameList; |
| | | return objJsonResult; |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "Exceptionï¼" + e.ToString(); |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | #endregion |
| | | |
| | | #region è´¨éæ¨¡å ä¸è¯åå°è´¦ |
| | | /// <summary> |
| | | /// è¿åå¼å¸¸ç®¡çå°è´¦ |
| | | ///åæ°ï¼string sqlã |
| | | ///è¿åå¼ï¼objectã |
| | | /// </summary> |
| | | [Route("QC_CustomerAppealReport/QC_BadProductsReport")] |
| | | [HttpGet] |
| | | public object QC_BadProductsReport(string sWhere, string user) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | if (sWhere == null || sWhere == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "æ æ¥è¯¢æ¡ä»¶ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | Dictionary<object, object> dic = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<object, object>>(sWhere); |
| | | |
| | | |
| | | string HBeginDate = dic["HBeginDate"].ToString(); |
| | | string HEndDate = dic["HEndDate"].ToString(); |
| | | string HMaterNumber = dic["HMaterNumber"].ToString(); |
| | | string HMaterModel = dic["HMaterModel"].ToString(); |
| | | string HProcessName = dic["HProcessName"].ToString(); |
| | | string HDealingType = dic["HDealingType"].ToString(); |
| | | string HSendManName = dic["HSendManName"].ToString(); |
| | | string HCustomize = dic["HCustomize"].ToString(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_QC_BadProductsReport '" + HBeginDate + "','" + HEndDate + "','" + HMaterNumber + "','" + HMaterModel + "','" + HProcessName + "','" + HDealingType + "','" + HSendManName + "','" + HCustomize + "'", "h_p_QC_BadProductsReport"); |
| | | |
| | | //æ·»å åå |
| | | 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 = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "Sucessï¼"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | objJsonResult.list = columnNameList; |
| | | return objJsonResult; |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "Exceptionï¼" + e.ToString(); |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | #endregion |
| | | |
| | | } |
| | | } |