| | |
| | | /// </summary> |
| | | [Route("QC_Report/QualityTraceability1")] |
| | | [HttpGet] |
| | | public object QualityTraceability1(string HICMOBillNo, string HType) |
| | | public object QualityTraceability1(string sWhere, string HType) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | Dictionary<object, object> dic = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<object, object>>(sWhere); |
| | | |
| | | string HICMOInterID = dic["HICMOInterID"].ToString(); |
| | | string HICMOEntryID = dic["HICMOEntryID"].ToString(); |
| | | string HICMOBillNo = dic["HICMOBillNo"].ToString(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "','"+ HICMOInterID + "','"+ HICMOEntryID + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | |
| | | |
| | | //æ·»å åå |
| | |
| | | /// </summary> |
| | | [Route("QC_Report/QualityTraceability2")] |
| | | [HttpGet] |
| | | public object QualityTraceability2(string HICMOBillNo, string HType) |
| | | public object QualityTraceability2(string sWhere, string HType) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | Dictionary<object, object> dic = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<object, object>>(sWhere); |
| | | |
| | | string HICMOInterID = dic["HICMOInterID"].ToString(); |
| | | string HICMOEntryID = dic["HICMOEntryID"].ToString(); |
| | | string HICMOBillNo = dic["HICMOBillNo"].ToString(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "','" + HICMOInterID + "','" + HICMOEntryID + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | |
| | | |
| | | |
| | | //æ·»å åå |
| | |
| | | /// </summary> |
| | | [Route("QC_Report/QualityTraceability3")] |
| | | [HttpGet] |
| | | public object QualityTraceability3(string HICMOBillNo, string HType) |
| | | public object QualityTraceability3(string sWhere, string HType) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | Dictionary<object, object> dic = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<object, object>>(sWhere); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | string HICMOInterID = dic["HICMOInterID"].ToString(); |
| | | string HICMOEntryID = dic["HICMOEntryID"].ToString(); |
| | | string HICMOBillNo = dic["HICMOBillNo"].ToString(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "','" + HICMOInterID + "','" + HICMOEntryID + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | |
| | | |
| | | //æ·»å åå |
| | |
| | | /// </summary> |
| | | [Route("QC_Report/QualityTraceability4")] |
| | | [HttpGet] |
| | | public object QualityTraceability4(string HICMOBillNo, string HType) |
| | | public object QualityTraceability4(string sWhere, string HType) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | Dictionary<object, object> dic = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<object, object>>(sWhere); |
| | | |
| | | string HICMOInterID = dic["HICMOInterID"].ToString(); |
| | | string HICMOEntryID = dic["HICMOEntryID"].ToString(); |
| | | string HICMOBillNo = dic["HICMOBillNo"].ToString(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "','" + HICMOInterID + "','" + HICMOEntryID + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | |
| | | |
| | | |
| | | //æ·»å åå |
| | |
| | | } |
| | | #endregion |
| | | |
| | | #region è´¨éæ¨¡å è´¨é追溯æ¥è¡¨æ¥è¡¨æ¥è¯¢(å·¡æ£è®°å½å) |
| | | /// <summary> |
| | | /// è¿åè´¨é追溯æ¥è¡¨å表 |
| | | ///åæ°ï¼string sqlã |
| | | ///è¿åå¼ï¼objectã |
| | | /// </summary> |
| | | [Route("QC_Report/QualityTraceability5")] |
| | | [HttpGet] |
| | | public object QualityTraceability5(string sWhere, string HType) |
| | | { |
| | | try |
| | | { |
| | | List<object> columnNameList = new List<object>(); |
| | | |
| | | Dictionary<object, object> dic = Newtonsoft.Json.JsonConvert.DeserializeObject<Dictionary<object, object>>(sWhere); |
| | | |
| | | string HICMOInterID = dic["HICMOInterID"].ToString(); |
| | | string HICMOEntryID = dic["HICMOEntryID"].ToString(); |
| | | string HICMOBillNo = dic["HICMOBillNo"].ToString(); |
| | | |
| | | ds = oCN.RunProcReturn("exec h_p_Sc_QueryQualityByICMOBill '" + HType + "','" + HICMOBillNo + "','" + HICMOInterID + "','" + HICMOEntryID + "'", "h_p_Sc_QueryQualityByICMOBill"); |
| | | |
| | | |
| | | //æ·»å åå |
| | | foreach (DataColumn col in ds.Tables[2].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[4]; |
| | | 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 è´¨éæ¨¡å SPCæ£éªååæ |
| | | /// <summary> |
| | | /// è¿åç´éçæ¥è¡¨å表 |