From 5e97cb34d9d8dc608de861eac31c7c10fdec2b5b Mon Sep 17 00:00:00 2001
From: zzr99 <1940172413@qq.com>
Date: 星期五, 14 一月 2022 19:33:29 +0800
Subject: [PATCH] 盘点审核+条码拆码

---
 WebAPI/Controllers/MateOutController.cs |  108 ++++++++++++++++++++++++++++++++---------------------
 1 files changed, 65 insertions(+), 43 deletions(-)

diff --git a/WebAPI/Controllers/MateOutController.cs b/WebAPI/Controllers/MateOutController.cs
index 787dda7..7269f7a 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,  long.Parse(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>

--
Gitblit v1.9.1