From d9d0587b8ae82785a97b874a4d2b0fff9d3e0882 Mon Sep 17 00:00:00 2001 From: yusijie <ysj@hz-kingdee.com> Date: 星期三, 16 八月 2023 14:48:24 +0800 Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-API --- WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs | 87 ++++++++++++++++++++++++++++++++----------- 1 files changed, 65 insertions(+), 22 deletions(-) diff --git a/WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs b/WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs index f5c918e..b145631 100644 --- a/WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs +++ b/WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs @@ -121,6 +121,8 @@ public json AddBillMain(string msg1) { + string sErrMsg = ""; + oSystemParameter.ShowBill(ref sErrMsg); string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries); string msg2 = sArray[0].ToString(); string msg3 = sArray[1].ToString(); @@ -180,6 +182,50 @@ int IsProNo = mainList[0].IsProNo;//鏄惁杞伐搴� HName_LongShan = mainList[0].HName;//宸ヨ壓璺嚎鍚嶇О + + if (oSystemParameter.omodel.WMS_CampanyName == "") + { + if (HPicNumVer == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鍥惧彿鐗堟湰涓嶈兘涓虹┖!"; + objJsonResult.data = null; + return objJsonResult; + } + if (HPicNumAssemble == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鎬昏鍥惧彿涓嶈兘涓虹┖!"; + objJsonResult.data = null; + return objJsonResult; + } + if (HMaterTexture == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏉愯川涓嶈兘涓虹┖!"; + objJsonResult.data = null; + return objJsonResult; + } + if (HProductNum == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鎴愬搧缂栧彿涓嶈兘涓虹┖!"; + objJsonResult.data = null; + return objJsonResult; + } + if (HVerNum == "") + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鐗堟湰涓嶈兘涓虹┖!"; + objJsonResult.data = null; + return objJsonResult; + } + } if (OperationType == 2) { ds = oCN.RunProcReturn("select * from h_v_Gy_RoutingBillList where 鍗曟嵁鍙�='" + HBillNo + "'", "h_v_Gy_RoutingBillList"); @@ -244,29 +290,9 @@ return objJsonResult; } - string sErrMsg = ""; - if (oSystemParameter.ShowBill(ref sErrMsg)) + if (oSystemParameter.omodel.WMS_CampanyName == "鐟炰笌绁�") { - if (oSystemParameter.omodel.WMS_CampanyName == "鐟炰笌绁�") - { - if (oSystemParameter.omodel.Gy_RoutingBill_SaveAutoLastProc == "Y" && OperationType == 1) - { - ds = oCN.RunProcReturn("select * from Gy_Process Where HTProcessFlag = 1 and HNumber='9999' ", "Gy_Process"); - - if (ds.Tables[0].Rows.Count == 0) - { - objJsonResult.code = "0"; - objJsonResult.count = 0; - objJsonResult.Message = "鏈缃浆宸ュ簭!"; - objJsonResult.data = null; - return objJsonResult; - } - - //璁剧疆杞伐搴� - oCN.RunProc("exec Gy_RoutingBill_LastProNo " + HInterID); - } - } - else if (IsProNo == 1 && OperationType == 1) + if (oSystemParameter.omodel.Gy_RoutingBill_SaveAutoLastProc == "Y" && OperationType == 1) { ds = oCN.RunProcReturn("select * from Gy_Process Where HTProcessFlag = 1 and HNumber='9999' ", "Gy_Process"); @@ -283,6 +309,23 @@ oCN.RunProc("exec Gy_RoutingBill_LastProNo " + HInterID); } } + else if (IsProNo == 1 && OperationType == 1) + { + ds = oCN.RunProcReturn("select * from Gy_Process Where HTProcessFlag = 1 and HNumber='9999' ", "Gy_Process"); + + if (ds.Tables[0].Rows.Count == 0) + { + objJsonResult.code = "0"; + objJsonResult.count = 0; + objJsonResult.Message = "鏈缃浆宸ュ簭!"; + objJsonResult.data = null; + return objJsonResult; + } + + //璁剧疆杞伐搴� + oCN.RunProc("exec Gy_RoutingBill_LastProNo " + HInterID); + } + //鏄惁鍕鹃�夐粯璁ゅ伐鑹鸿矾绾� -- Gitblit v1.9.1