From f431a054fc8d876769a3e8f65a3eba43e0c3523b Mon Sep 17 00:00:00 2001 From: yangle <admin@YINMOU> Date: 星期一, 09 一月 2023 09:56:04 +0800 Subject: [PATCH] 末道工序出站列表 入库 首道工序出站 列表 维护 委外工序发出单 委外工序接收单 工序进站接收单 维护 --- WebAPI/Controllers/Sc_ProcessMangementController.cs | 66 ++++++++++++++++++++++++++++----- 1 files changed, 56 insertions(+), 10 deletions(-) diff --git a/WebAPI/Controllers/Sc_ProcessMangementController.cs b/WebAPI/Controllers/Sc_ProcessMangementController.cs index 74861e0..47f0224 100644 --- a/WebAPI/Controllers/Sc_ProcessMangementController.cs +++ b/WebAPI/Controllers/Sc_ProcessMangementController.cs @@ -98,6 +98,51 @@ return objJsonResult; } + #region 鏈亾宸ュ簭姹囨姤鍏ュ簱 + /// <summary> + /// 鏈亾宸ュ簭姹囨姤鍏ュ簱鍒楄〃 + /// </summary> + /// <param name="sWhere"></param> + /// <param name="user"></param> + /// <returns></returns> + [Route("Sc_ProcessMangement/Sc_ProcessReportList_Last")] + [HttpGet] + public object Sc_ProcessReportList_Last(string sWhere, string user) + { + try + { + //鍒ゆ柇鏄惁鏈夋煡璇㈡潈闄� + if (!DBUtility.ClsPub.Security_Log("Cj_StationOutBill_Query", 1, false, user)) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏃犳煡璇㈡潈闄�!"; + objJsonResult.data = null; + return objJsonResult; + } + + string sql1 = "select * from h_v_Sc_ProcessReportList_Last where 1 = 1 and HLastProc='鏄�'"; + string sql = sql1 + sWhere + " order by hmainid desc"; + ds = oCN.RunProcReturn(sql, "h_v_Sc_ProcessReportList_Last"); + + objJsonResult.code = "1"; + objJsonResult.count = 1; + objJsonResult.Message = "Sucess锛�"; + 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 宸ュ簭姹囨姤鍏ュ簱 /// <summary> /// 鑾峰彇宸ュ簭姹囨姤鍏ュ簱鍗曞垪琛� @@ -121,16 +166,11 @@ return objJsonResult; } - if (sWhere == null || sWhere.Equals("")) - { - ds = oCN.RunProcReturn("select * from h_v_MES_StationOutBillList_LastProc order by hmainid desc", "h_v_MES_StationOutBillList_LastProc"); - } - else - { - string sql1 = "select * from h_v_MES_StationOutBillList_LastProc where 1 = 1 "; - string sql = sql1 + sWhere + " order by hmainid desc"; - ds = oCN.RunProcReturn(sql, "h_v_MES_StationOutBillList_LastProc"); - } + + string sql1 = "select * from h_v_Sc_ProcessReportList_Last where 1 = 1 and HFstProc='鏄�' "; + string sql = sql1 + sWhere + " order by hmainid desc"; + ds = oCN.RunProcReturn(sql, "h_v_Sc_ProcessReportList_Last"); + objJsonResult.code = "1"; objJsonResult.count = 1; objJsonResult.Message = "Sucess锛�"; @@ -331,6 +371,8 @@ objJsonResult.data = null; return objJsonResult; } + + oCN.RunProc("update Sc_StationOutBillMain set HRelationQty=1 where HBillNo='" + BillNo+"'"); oCN.Commit(); objJsonResult.code = "0"; @@ -577,6 +619,8 @@ return objJsonResult; } + oCN.RunProc("update Sc_StationOutBillMain set HRelationQty=1 where HBillNo='" + BillNo + "'"); + oCN.Commit(); objJsonResult.code = "0"; objJsonResult.count = 1; @@ -814,6 +858,8 @@ return objJsonResult; } + oCN.RunProc("update Sc_StationOutBillMain set HRelationQty=1 where HBillNo='" + BillNo + "'"); + oCN.Commit(); oCN.RunProc("update sc_stationoutbillmain set HBFFlag =1 where HProcExchBillNo = '" + BillNo + "'"); objJsonResult.code = "0"; -- Gitblit v1.9.1