From 1f53d71884bb7f6264da7f2b2a1adb5351a8e420 Mon Sep 17 00:00:00 2001
From: ch <37327@LLOOCCY>
Date: 星期五, 14 一月 2022 09:12:55 +0800
Subject: [PATCH] 修改了生产领料扫描多源单方法
---
WebAPI/Controllers/MateOutController.cs | 108 ++++++++++++++++++++++++++++++++---------------------
WebAPI/Web.config | 4 +-
2 files changed, 67 insertions(+), 45 deletions(-)
diff --git a/WebAPI/Controllers/MateOutController.cs b/WebAPI/Controllers/MateOutController.cs
index 787dda7..99751fe 100644
--- a/WebAPI/Controllers/MateOutController.cs
+++ b/WebAPI/Controllers/MateOutController.cs
@@ -70,56 +70,78 @@
/// <returns></returns>
[Route("MateOut/set_SavePonderationBillMain_Temp_Mate_Source_Fast_Json")]
[HttpGet]
- public object set_SavePonderationBillMain_Temp_Mate_Source_Fast_Json(string HSourceBillType,string HSourceBillNo, Int64 sInterID, string sBillNo)
+ public object set_SavePonderationBillMain_Temp_Mate_Source_Fast_Json(Int64 sInterID, string sBillNo, string HBillType, string HSourceBillNo, string HSourceBillType, string sMaker,double sPPQty,string sPlanMode,Int64 sFIFOWHID, Int64 HOWNERID)
{
- try
+ //try
+ //{
+ // // DataSet ds = new DataSet();
+ // // WebServer webserver = new WebServer();
+ // string sWhere = " Where 鍗曟嵁鍙� like '%" + HSourceBillNo.Trim() + "%'";
+ // ds = webserver.GetSc_PPBomBillList(sWhere);
+ // if (ds == null || ds.Tables[0].Rows.Count <= 0)
+ // {
+ // objJsonResult.code = "0";
+ // objJsonResult.count = 0;
+ // objJsonResult.Message = "娌℃湁杩斿洖浠讳綍璁板綍锛�";
+ // objJsonResult.data = null;
+ // return objJsonResult;
+ // //DBUtility.ClsPub.MessageBeep((int)DBUtility.ClsPub.BeepType.Warning);
+ // }
+ // else
+ // {
+ // //HSupID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HSupID"]);
+ // //HSupName = Convert.ToString(ds.Tables[0].Rows[0]["HSupName"]);
+ // HDeptID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HDeptID"]);
+ // HDeptName = Convert.ToString(ds.Tables[0].Rows[0]["HDeptName"]);
+ // if (webserver.set_SavePonderationBillMain_Temp_Source_Fast(sInterID, sBillNo, HBillType, HSourceBillNo, HSourceBillType, "钃濆瓧", ref DBUtility.ClsPub.sErrInfo))
+ // {
+ // objJsonResult.code = "0";
+ // objJsonResult.count = 1;
+ // objJsonResult.Message = "杩斿洖璁板綍鎴愬姛锛�";
+ // objJsonResult.data = null;
+ // return objJsonResult;
+ // }
+ // else
+ // {
+ // objJsonResult.code = "0";
+ // objJsonResult.count = 0;
+ // objJsonResult.Message = "鎵爜澶辫触锛�" + DBUtility.ClsPub.sErrInfo;
+ // objJsonResult.data = null;
+ // return objJsonResult;
+ // }
+ // }
+ //}
+ //catch (Exception ex)
+ //{
+
+ // objJsonResult.code = "0";
+ // objJsonResult.count = 0;
+ // objJsonResult.Message = "娌℃湁杩斿洖浠讳綍璁板綍锛�"+ex.ToString();
+ // objJsonResult.data = null;
+ // return objJsonResult;
+ //}
+ WebS.WebService1 oWebs1 = new WebS.WebService1();
+ WebSoBar = oWebs1.get_SourceBarCode_MateOut(sInterID, sBillNo, HBillType, HSourceBillNo, HSourceBillType, sMaker, sPPQty, sPlanMode, sFIFOWHID, HOWNERID, ref DBUtility.ClsPub.sErrInfo);
+
+
+ //oBar = webserver.get_CheckTypeByBarCode_Out(sCode, sInterID, HBillType, sBillNo, sMaker, WhID, SPID, sQty, sRedBlue, SourceFlag, sSourceBillNo, sSourceType, HOWNERID, ref DBUtility.ClsPub.sErrInfo);
+ if (WebSoBar == null)
{
- // DataSet ds = new DataSet();
- // WebServer webserver = new WebServer();
- string sWhere = " Where 鍗曟嵁鍙� like '%" + HSourceBillNo.Trim() + "%'";
- ds = webserver.GetSc_PPBomBillList(sWhere);
- if (ds == null || ds.Tables[0].Rows.Count <= 0)
- {
- objJsonResult.code = "0";
- objJsonResult.count = 0;
- objJsonResult.Message = "娌℃湁杩斿洖浠讳綍璁板綍锛�";
- objJsonResult.data = null;
- return objJsonResult;
- //DBUtility.ClsPub.MessageBeep((int)DBUtility.ClsPub.BeepType.Warning);
- }
- else
- {
- //HSupID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HSupID"]);
- //HSupName = Convert.ToString(ds.Tables[0].Rows[0]["HSupName"]);
- HDeptID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HDeptID"]);
- HDeptName = Convert.ToString(ds.Tables[0].Rows[0]["HDeptName"]);
- if (webserver.set_SavePonderationBillMain_Temp_Source_Fast(sInterID, sBillNo, HBillType, HSourceBillNo, HSourceBillType, "钃濆瓧", ref DBUtility.ClsPub.sErrInfo))
- {
- objJsonResult.code = "0";
- objJsonResult.count = 1;
- objJsonResult.Message = "杩斿洖璁板綍鎴愬姛锛�";
- objJsonResult.data = null;
- return objJsonResult;
- }
- else
- {
- objJsonResult.code = "0";
- objJsonResult.count = 0;
- objJsonResult.Message = "鎵爜澶辫触锛�" + DBUtility.ClsPub.sErrInfo;
- objJsonResult.data = null;
- return objJsonResult;
- }
- }
- }
- catch (Exception ex)
- {
-
objJsonResult.code = "0";
objJsonResult.count = 0;
- objJsonResult.Message = "娌℃湁杩斿洖浠讳綍璁板綍锛�"+ex.ToString();
+ objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
objJsonResult.data = null;
return objJsonResult;
}
+ else
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
+ objJsonResult.data = oBar;
+ return objJsonResult;
+ }
+
}
/// <summary>
diff --git a/WebAPI/Web.config b/WebAPI/Web.config
index d975c2d..28c2e7f 100644
--- a/WebAPI/Web.config
+++ b/WebAPI/Web.config
@@ -21,8 +21,8 @@
<add key="FileIP" value="http://localhost:8080/"/>
<!--<add key="sUrl" value="http://183.129.128.86:9090/WEBS-WMSTest/WebService1.asmx"/> -->
<!--<add key="sUrl" value="http://192.168.63.195/WEBS-WMS/WebService1.asmx"/> 棰滃彴寮忔満-->
- <add key="sUrl" value="http://60.190.4.42:9003/WebService/WebService1.asmx"/> <!--澶忓疂-->
-
+ <!--<add key="sUrl" value="http://60.190.4.42:9003/WebService/WebService1.asmx"/> 澶忓疂-->
+ <add key="sUrl" value="http://localhost:8098/WebService1.asmx"/>
<!--<add key="sUrl" value="http://10.10.130.181/WEBS-WMS/WebService1.asmx"/> 鍗氭棩绉戞妧-->
<add key="webpages:Version" value="3.0.0.0" />
<add key="webpages:Enabled" value="false" />
--
Gitblit v1.9.1