| | |
| | | string msg2 = sArray[0].ToString(); |
| | | string msg3 = sArray[1].ToString(); |
| | | string OperationType = sArray[2].ToString().Trim(); |
| | | string user = sArray[3].ToString();//ç¨æ·å |
| | | |
| | | bool bResult; |
| | | try |
| | | { |
| | | //夿æé |
| | | if (!DBUtility.ClsPub.Security_Log("QC_ProcessCheckBill_Edit", 1, false, user)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "æ ä¿åæé"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | msg2 = "[" + msg2.ToString() + "]"; |
| | | List<Model.ClsQC_ProcessCheckBillMain> mainList = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsQC_ProcessCheckBillMain>>(msg2); |
| | | DAL.ClsQC_ProcessCheckBill BillNew = new DAL.ClsQC_ProcessCheckBill(); |
| | |
| | | /// </summary> |
| | | [Route("QC_ProcessCheckBill/Delete_Json")] |
| | | [HttpGet] |
| | | public object Delete_Json(long HItemID) |
| | | public object Delete_Json(long HItemID,string user) |
| | | { |
| | | DAL.ClsQC_ProcessCheckBill BillOld = new DAL.ClsQC_ProcessCheckBill(); |
| | | try |
| | | { |
| | | //æ¥çæé |
| | | if (!DBUtility.ClsPub.Security_Log("QC_ProcessCheckBill_Delete", 1, false, user)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "æ å 餿éï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | if (BillOld.DeleteBill(HItemID, ref ClsPub.sExeReturnInfo) != true) |
| | | { |
| | | objJsonResult.code = "1"; |
| | |
| | | /// </summary> |
| | | [Route("QC_ProcessCheckBill/GetProcessCheckBillList")] |
| | | [HttpGet] |
| | | public object GetProcessCheckBillList(string sWhere) |
| | | public object GetProcessCheckBillList(string sWhere,string user) |
| | | { |
| | | try |
| | | { |
| | | //æ¥çæé |
| | | if (!DBUtility.ClsPub.Security_Log("QC_ProcessCheckBill_Query", 1, false, user)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "æ æ¥çæéï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | if (sWhere == null || sWhere.Equals("")) |
| | | { |
| | | ds = oCN.RunProcReturn("select * from h_v_QC_ProcessCheckBillListDetail " + sWhere, "h_v_QC_ProcessCheckBillListDetail"); |
| | | ds = oCN.RunProcReturn("select * from h_v_QC_ProcessCheckBillListDetail order by hmainid desc ", "h_v_QC_ProcessCheckBillListDetail"); |
| | | } |
| | | else |
| | | { |
| | | string sql1 = "select * from h_v_QC_ProcessCheckBillListDetail where 1 = 1 "; |
| | | string sql = sql1 + sWhere; |
| | | string sql = sql1 + sWhere+ " order by hmainid desc "; |
| | | ds = oCN.RunProcReturn(sql, "h_v_QC_ProcessCheckBillListDetail"); |
| | | } |
| | | if (ds == null || ds.Tables[0].Rows.Count == 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "falseï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | else |
| | | { |
| | | objJsonResult.code = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "Sucessï¼"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | //if (ds.Tables[0].Rows.Count != 0 || ds != null) |
| | | //{ |
| | | objJsonResult.code = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "Sucessï¼"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | return objJsonResult; |
| | | //} |
| | | //else |
| | | //{ |
| | | //objJsonResult.code = "0"; |
| | | //objJsonResult.count = 0; |
| | | //objJsonResult.Message = "æ æ°æ®"; |
| | | //objJsonResult.data = null; |
| | | //return objJsonResult; |
| | | //} |
| | | } |
| | | catch (Exception e) |
| | | { |