From 495bec6b471348d3b5b82b1aa6c3af2c9a0e31a2 Mon Sep 17 00:00:00 2001
From: yxj <1qaz@123>
Date: 星期四, 23 九月 2021 09:56:32 +0800
Subject: [PATCH] 直接调拨单、分步式调出单、分步式调入单模块,上传生成CLOUD单据,增加启用模治具管理判断

---
 CLOUDWEB/WebService1.asmx.cs |   68 ++++++++++++++++++++++++++++++++++
 1 files changed, 68 insertions(+), 0 deletions(-)

diff --git a/CLOUDWEB/WebService1.asmx.cs b/CLOUDWEB/WebService1.asmx.cs
index cd01be6..722484b 100644
--- a/CLOUDWEB/WebService1.asmx.cs
+++ b/CLOUDWEB/WebService1.asmx.cs
@@ -5485,6 +5485,12 @@
                     oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + oMain.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120),HBillStatus=2 where HInterID= " + oMain.HInterID.ToString());
                 }
 
+                if (oSystemParameterMain.WMS_MouldManagerCtl == "Y") //绯荤粺鍙傛暟  鍚敤鍣ㄥ叿绠$悊
+                {
+                    string HMouldBillType = "3814";
+                    oCn.RunProc("EXEC h_p_Sc_MouldStockBill_Insert_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "','" + HMouldBillType + "'," + oMain.HSupID.ToString() + "," + oMain.HKeeperID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HDeptID.ToString());
+                }
+
                 //鏍规嵁TMP琛� 杩斿洖 瀛愯〃淇℃伅
                 Ds = oCn.RunProcReturn("exec h_p_Kf_GetMoveOutBill_CLD " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "'", "h_p_Kf_GetMoveOutBill_CLD");
                 if (Ds == null || Ds.Tables[0].Rows.Count == 0 || Ds.Tables[1].Rows.Count == 0)
@@ -5756,6 +5762,12 @@
                     oCn.RunProc("exec h_p_Kf_MoveMaterOut_UpdateSourceByBarCodeBill " + oMain.HInterID.ToString());
                 }
 
+                if (oSystemParameterMain.WMS_MouldManagerCtl == "Y") //绯荤粺鍙傛暟  鍚敤鍣ㄥ叿绠$悊
+                {
+                    string HMouldBillType = "3814";
+                    oCn.RunProc("EXEC h_p_Sc_MouldStockBill_Insert_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "','" + HMouldBillType + "'," + oMain.HSupID.ToString() + "," + oMain.HKeeperID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HDeptID.ToString());
+                }
+
                 //鏍规嵁TMP琛� 杩斿洖 瀛愯〃淇℃伅
                 Ds = oCn.RunProcReturn("exec h_p_Kf_GetMoveMaterOutBill_CLD " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "'", "h_p_Kf_GetMoveMaterOutBill_CLD");
                 if (Ds == null || Ds.Tables[0].Rows.Count == 0 || Ds.Tables[1].Rows.Count == 0)
@@ -6005,6 +6017,12 @@
                 {
                     //瀹℃牳鍗曟嵁
                     oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + oMain.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120),HBillStatus=2 where HInterID= " + oMain.HInterID.ToString());
+                }
+
+                if (oSystemParameterMain.WMS_MouldManagerCtl == "Y") //绯荤粺鍙傛暟  鍚敤鍣ㄥ叿绠$悊
+                {
+                    string HMouldBillType = "3814";
+                    oCn.RunProc("EXEC h_p_Sc_MouldStockBill_Insert_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "','" + HMouldBillType + "'," + oMain.HSupID.ToString() + "," + oMain.HKeeperID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HDeptID.ToString());
                 }
 
                 //鏍规嵁TMP琛� 杩斿洖 瀛愯〃淇℃伅
@@ -7481,6 +7499,12 @@
                     oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + oMain.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120) where HInterID= " + oMain.HInterID.ToString());
                 }
 
+                if (oSystemParameterMain.WMS_MouldManagerCtl == "Y") //绯荤粺鍙傛暟  鍚敤鍣ㄥ叿绠$悊
+                {
+                    string HMouldBillType = "3814";
+                    oCn.RunProc("EXEC h_p_Sc_MouldStockBill_Insert_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "','" + HMouldBillType + "'," + oMain.HSupID.ToString() + "," + oMain.HKeeperID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HDeptID.ToString());
+                }
+
                 //鏍规嵁TMP琛� 杩斿洖 瀛愯〃淇℃伅
                 DataSet Ds;
                 Ds = oCn.RunProcReturn("exec h_p_Kf_GetMoveStockBill_MoveStockRequest_CLD_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "'", "h_p_Kf_GetMoveStockBill_MoveStockRequest_CLD_New");
@@ -7879,6 +7903,12 @@
                     oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + oMain.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120) where HInterID= " + oMain.HInterID.ToString());
                 }
 
+                if (oSystemParameterMain.WMS_MouldManagerCtl == "Y") //绯荤粺鍙傛暟  鍚敤鍣ㄥ叿绠$悊
+                {
+                    string HMouldBillType = "3840";
+                    oCn.RunProc("EXEC h_p_Sc_MouldStockBill_Insert_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "','" + HMouldBillType + "'," + oMain.HSupID.ToString() + "," + oMain.HKeeperID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HDeptID.ToString());
+                }
+
                 //鏍规嵁TMP琛� 杩斿洖 瀛愯〃淇℃伅
                 DataSet Ds;
                 Ds = oCn.RunProcReturn("exec h_p_Kf_GetMoveStockStepOutBill_SeOutStock_CLD " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "'", "h_p_Kf_GetMoveStockStepOutBill_SeOutStock_CLD");
@@ -8176,6 +8206,12 @@
                 {
                     //瀹℃牳鍗曟嵁
                     oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + oMain.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120) where HInterID= " + oMain.HInterID.ToString());
+                }
+
+                if (oSystemParameterMain.WMS_MouldManagerCtl == "Y") //绯荤粺鍙傛暟  鍚敤鍣ㄥ叿绠$悊
+                {
+                    string HMouldBillType = "3840";
+                    oCn.RunProc("EXEC h_p_Sc_MouldStockBill_Insert_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "','" + HMouldBillType + "'," + oMain.HSupID.ToString() + "," + oMain.HKeeperID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HDeptID.ToString());
                 }
 
                 //鏍规嵁TMP琛� 杩斿洖 瀛愯〃淇℃伅
@@ -8518,6 +8554,12 @@
                 {
                     //瀹℃牳鍗曟嵁
                     oCn.RunProc("Update Kf_ICStockBillMain Set HChecker='" + oMain.HMaker + "',HCheckDate=convert(varchar(10),getdate(),120) where HInterID= " + oMain.HInterID.ToString());
+                }
+
+                if (oSystemParameterMain.WMS_MouldManagerCtl == "Y") //绯荤粺鍙傛暟  鍚敤鍣ㄥ叿绠$悊
+                {
+                    string HMouldBillType = "3841";
+                    oCn.RunProc("EXEC h_p_Sc_MouldStockBill_Insert_New " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "','" + HMouldBillType + "'," + oMain.HSupID.ToString() + "," + oMain.HKeeperID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HDeptID.ToString());
                 }
 
                 //鏍规嵁TMP琛� 杩斿洖 瀛愯〃淇℃伅
@@ -32603,7 +32645,33 @@
 
         #endregion
 
+        #region 璋冩嫧妯″潡    鎵弿妯℃不鍏锋潯鐮�
+        [WebMethod]
+        //鎵弿鐗╂枡鏉$爜瀛樺叆涓存椂琛ㄦ椂鍒ゆ柇浠撳簱浠撲綅鏄惁姝g‘
+        public bool Get_CheckTypeByMouldBarCode(string sBarCode, Int64 HBillID, string HBillType, string HBillNo, string HMaker, Int64 HWhID, Int64 HSPID, Int64 HSCWhID, Int64 HSCSPID, bool HRedBlueFlag, string HSourceBillNo, string HSourceBillType, Int64 HOWNERID, ref string sErrMsg)
+        {
+            SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
+            DataSet ds = oCN.RunProcReturn("exec h_p_WMS_AddMouldBarCode_New '" + sBarCode + "'," + HBillID.ToString() + ",'" + HBillNo + "','" + HBillType + "'," + HWhID.ToString() + "," + HSPID.ToString() + "," + HSCWhID.ToString() + "," + HSCSPID.ToString() +",'" + HSourceBillNo + "','" + HSourceBillType + "','" + HRedBlueFlag + "','" + HMaker + "'," + HOWNERID.ToString(), "h_p_WMS_AddMouldBarCode_New");
+            if (ds == null || ds.Tables[0].Rows.Count == 0)
+            {
+                sErrMsg = "灏嗘ā娌诲叿淇℃伅鍐欏叆妯℃不鍏峰嚭鍏ュ簱涓存椂琛ㄥけ璐ワ紒";
+                return false;
+            }
+            else
+            {
+                if (DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0][0]) == 0)
+                {
+                    return true;
+                }
+                else
+                {
+                    sErrMsg = DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]);
+                    return false;
+                }
+            }
+        }
 
+        #endregion
 
         #endregion
 

--
Gitblit v1.9.1