From fd8a551ed255e6f61d71aba6f42ddb0dc6a05df3 Mon Sep 17 00:00:00 2001
From: yxj <1qaz@123>
Date: 星期四, 01 九月 2022 16:04:00 +0800
Subject: [PATCH] 生产汇报、采购入库、生产入库、销售出库、领料出库、其他出库、直接调拨上传增加上传前控制
---
CLOUDWEB/WebService1.asmx.cs | 197 ++++++++++++++++++++++++++++++++++++++++--------
1 files changed, 162 insertions(+), 35 deletions(-)
diff --git a/CLOUDWEB/WebService1.asmx.cs b/CLOUDWEB/WebService1.asmx.cs
index 3cca01e..c03ad43 100644
--- a/CLOUDWEB/WebService1.asmx.cs
+++ b/CLOUDWEB/WebService1.asmx.cs
@@ -4229,6 +4229,22 @@
sErrMsg = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
return false;
}
+ //涓婁紶鍓嶅垽鏂�
+ SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ DataSet Ds = oCn.RunProcReturn("exec h_p_WMS_BeforeUpload_ICMOReportBill " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "','" + sHSourceType + "'," + oMain.HDeptID.ToString() + ",'" + oSystemParameter.omodel.Sc_ICMOReportBill_MustQtyCtl + "'", "h_p_WMS_BeforeUpload_ICMOReportBill");
+ if (Ds == null || Ds.Tables[0].Rows.Count == 0)
+ {
+ sErrMsg = "涓婁紶鍓嶅垽鏂暟鎹畬鏁存�уけ璐ワ紒";
+ return false;
+ }
+ else
+ {
+ if (DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0][0]) == 1)
+ {
+ sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
+ return false;
+ }
+ }
//
if (oSystemParameter.omodel.Sc_ICMOReportBill_ERPMode.ToUpper() == "WISE") //鍒ゆ柇鍚屾妯″紡鏄噾铦禬ISE
{
@@ -4236,7 +4252,7 @@
}
if (oSystemParameter.omodel.Sc_ICMOReportBill_ERPMode.ToUpper() == "CLOUD") //鍒ゆ柇鍚屾妯″紡鏄噾铦禖LOUD
{
- if (set_SaveICMOReportBill_CLD_New(oMain, sHSourceType, oSystemParameter.omodel, ref sErrMsg) == true)
+ if (set_SaveICMOReportBill_CLD_New(oMain, sHSourceType, oSystemParameter.omodel, ref sErrMsg) == true)
{
//"淇濆瓨鎴愬姛锛�";
return true;
@@ -4260,20 +4276,20 @@
[WebMethod]
public bool set_SaveICMOReportBill_CLD_New(Model.ClsSc_ICMOReportBillMain oMain, string sHSourceType, Pub_Class.ClsXt_SystemParameterMain oSystemParameterMain, ref string sErrMsg)
{
- //涓婁紶鍓嶅垽鏂槸鍚﹀瓨鍦ㄧ浉鍚屾潯鐮�
- SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
- DataSet ds = oCn.RunProcReturn("exec h_p_WMS_UpLoadControl " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "'", "h_p_WMS_UpLoadControl");
- if (ds == null || ds.Tables[0].Rows.Count == 0)
- {
- }
- else
- {
- if (DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0][0]) == 1)
- {
- sErrMsg = DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]);
- return false;
- }
- }
+ ////涓婁紶鍓嶅垽鏂槸鍚﹀瓨鍦ㄧ浉鍚屾潯鐮�
+ //SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ //DataSet ds = oCn.RunProcReturn("exec h_p_WMS_UpLoadControl " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "'", "h_p_WMS_UpLoadControl");
+ //if (ds == null || ds.Tables[0].Rows.Count == 0)
+ //{
+ //}
+ //else
+ //{
+ // if (DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0][0]) == 1)
+ // {
+ // sErrMsg = DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]);
+ // return false;
+ // }
+ //}
//if (sHSourceType == "3710") //婧愬崟锛氱敓浜ц鍗�
//{
@@ -6411,7 +6427,22 @@
sErrMsg = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
return false;
}
-
+ //涓婁紶鍓嶅垽鏂�
+ SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ DataSet Ds = oCn.RunProcReturn("exec h_p_WMS_BeforeUpload_MoveStockBill " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "','" + sHSourceType + "'," + oMain.HDeptID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HKeeperID.ToString() + ",'" + oSystemParameter.omodel.Kf_MoveStockBill_MustQtyCtl + "'", "h_p_WMS_BeforeUpload_MoveStockBill");
+ if (Ds == null || Ds.Tables[0].Rows.Count == 0)
+ {
+ sErrMsg = "涓婁紶鍓嶅垽鏂暟鎹畬鏁存�уけ璐ワ紒";
+ return false;
+ }
+ else
+ {
+ if (DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0][0]) == 1)
+ {
+ sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
+ return false;
+ }
+ }
//
if (oSystemParameter.omodel.Kf_MoveStockBill_ERPMode.ToUpper() == "WISE") //鍒ゆ柇鍚屾妯″紡鏄噾铦禬ISE
{
@@ -9798,6 +9829,22 @@
sErrMsg = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
return false;
}
+ //涓婁紶鍓嶅垽鏂�
+ SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ DataSet Ds = oCn.RunProcReturn("exec h_p_WMS_BeforeUpload_SellOutBill " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "','" + sHSourceType + "'," + oMain.HDeptID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HKeeperID.ToString() + ",'" + oSystemParameter.omodel.Kf_SellOutBill_MustQtyCtl + "'", "h_p_WMS_BeforeUpload_SellOutBill");
+ if (Ds == null || Ds.Tables[0].Rows.Count == 0)
+ {
+ sErrMsg = "涓婁紶鍓嶅垽鏂暟鎹畬鏁存�уけ璐ワ紒";
+ return false;
+ }
+ else
+ {
+ if (DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0][0]) == 1)
+ {
+ sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
+ return false;
+ }
+ }
//
if (oSystemParameter.omodel.Kf_SellOutBill_ERPMode.ToUpper() == "WISE") //鍒ゆ柇鍚屾妯″紡鏄噾铦禬ISE
{
@@ -12231,6 +12278,22 @@
{
sErrMsg = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
return false;
+ }
+ //涓婁紶鍓嶅垽鏂�
+ SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ DataSet Ds = oCn.RunProcReturn("exec h_p_WMS_BeforeUpload_MateOutBill " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "','" + sHSourceType + "'," + oMain.HDeptID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HKeeperID.ToString() + ",'" + oSystemParameter.omodel.Kf_MateOutBill_MustQtyCtl + "'", "h_p_WMS_BeforeUpload_MateOutBill");
+ if (Ds == null || Ds.Tables[0].Rows.Count == 0)
+ {
+ sErrMsg = "涓婁紶鍓嶅垽鏂暟鎹畬鏁存�уけ璐ワ紒";
+ return false;
+ }
+ else
+ {
+ if (DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0][0]) == 1)
+ {
+ sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
+ return false;
+ }
}
//
if (oSystemParameter.omodel.Kf_MateOutBill_ERPMode.ToUpper() == "WISE") //鍒ゆ柇鍚屾妯″紡鏄噾铦禬ISE
@@ -14672,6 +14735,22 @@
sErrMsg = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
return false;
}
+ //涓婁紶鍓嶅垽鏂�
+ SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ DataSet Ds = oCn.RunProcReturn("exec h_p_WMS_BeforeUpload_OtherOutBill " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "','" + sHSourceType + "'," + oMain.HDeptID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HKeeperID.ToString() + ",'" + oSystemParameter.omodel.Kf_OtherOutBill_MustQtyCtl + "'", "h_p_WMS_BeforeUpload_OtherOutBill");
+ if (Ds == null || Ds.Tables[0].Rows.Count == 0)
+ {
+ sErrMsg = "涓婁紶鍓嶅垽鏂暟鎹畬鏁存�уけ璐ワ紒";
+ return false;
+ }
+ else
+ {
+ if (DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0][0]) == 1)
+ {
+ sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
+ return false;
+ }
+ }
//
if (oSystemParameter.omodel.Kf_OtherOutBill_ERPMode.ToUpper() == "WISE") //鍒ゆ柇鍚屾妯″紡鏄噾铦禬ISE
{
@@ -16219,6 +16298,22 @@
sErrMsg = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
return false;
}
+ //涓婁紶鍓嶅垽鏂�
+ SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ DataSet Ds = oCn.RunProcReturn("exec h_p_WMS_BeforeUpload_POStockInBill " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "','" + sHSourceType + "'," + oMain.HDeptID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HKeeperID.ToString() + ",'" + oSystemParameter.omodel.Kf_POStockInBill_MustQtyCtl + "'", "h_p_WMS_BeforeUpload_POStockInBill");
+ if (Ds == null || Ds.Tables[0].Rows.Count == 0)
+ {
+ sErrMsg = "涓婁紶鍓嶅垽鏂暟鎹畬鏁存�уけ璐ワ紒";
+ return false;
+ }
+ else
+ {
+ if (DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0][0]) == 1)
+ {
+ sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
+ return false;
+ }
+ }
//
if (oSystemParameter.omodel.Kf_POStockInBill_ERPMode.ToUpper() == "WISE") //鍒ゆ柇鍚屾妯″紡鏄噾铦禬ISE
{
@@ -17418,20 +17513,36 @@
sErrMsg = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
return false;
}
- //涓婁紶鍓嶅垽鏂槸鍚﹀瓨鍦ㄧ浉鍚屾潯鐮�
+ //涓婁紶鍓嶅垽鏂�
SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
- DataSet ds = oCn.RunProcReturn("exec h_p_WMS_UpLoadControl " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "'", "h_p_WMS_UpLoadControl");
- if (ds == null || ds.Tables[0].Rows.Count == 0)
+ DataSet Ds = oCn.RunProcReturn("exec h_p_WMS_BeforeUpload_ProductInBill_MulSource " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "'", "h_p_WMS_BeforeUpload_ProductInBill_MulSource");
+ if (Ds == null || Ds.Tables[0].Rows.Count == 0)
{
+ sErrMsg = "涓婁紶鍓嶅垽鏂暟鎹畬鏁存�уけ璐ワ紒";
+ return false;
}
else
{
- if (DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0][0]) == 1)
+ if (DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0][0]) == 1)
{
- sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]);
+ sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
return false;
}
}
+ ////涓婁紶鍓嶅垽鏂槸鍚﹀瓨鍦ㄧ浉鍚屾潯鐮�
+ //SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ //DataSet ds = oCn.RunProcReturn("exec h_p_WMS_UpLoadControl " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "'", "h_p_WMS_UpLoadControl");
+ //if (ds == null || ds.Tables[0].Rows.Count == 0)
+ //{
+ //}
+ //else
+ //{
+ // if (DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0][0]) == 1)
+ // {
+ // sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]);
+ // return false;
+ // }
+ //}
//浜у搧鍏ュ簱鍗曚繚瀛樺墠杩涜鍊掑啿浠撹礋搴撳瓨鎺у埗
DataSet ds2 = oCn.RunProcReturn("exec h_p_IFCLD_CheckDaochong_Handian " + oMain.HInterID.ToString() + ",'" + oMain.HBillType + "'", "h_p_IFCLD_CheckDaochong_Handian");
@@ -18385,6 +18496,22 @@
sErrMsg = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
return false;
}
+ //涓婁紶鍓嶅垽鏂�
+ SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ DataSet Ds = oCn.RunProcReturn("exec h_p_WMS_BeforeUpload_ProductInBill " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "','" + sHSourceType + "'," + oMain.HDeptID.ToString() + "," + oMain.HSecManagerID.ToString() + "," + oMain.HKeeperID.ToString() + ",'" + oSystemParameter.omodel.Kf_ProductInBill_MustQtyCtl + "'", "h_p_WMS_BeforeUpload_ProductInBill");
+ if (Ds == null || Ds.Tables[0].Rows.Count == 0)
+ {
+ sErrMsg = "涓婁紶鍓嶅垽鏂暟鎹畬鏁存�уけ璐ワ紒";
+ return false;
+ }
+ else
+ {
+ if (DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0][0]) == 1)
+ {
+ sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["HRemark"]);
+ return false;
+ }
+ }
//
if (oSystemParameter.omodel.Kf_ProductInBill_ERPMode.ToUpper() == "WISE") //鍒ゆ柇鍚屾妯″紡鏄噾铦禬ISE
{
@@ -18601,20 +18728,20 @@
[WebMethod]
public bool set_SaveProductInBill_CLD_New(Model.ClsKf_ProductInBillMain oMain, string sHSourceType, Pub_Class.ClsXt_SystemParameterMain oSystemParameterMain, ref string sErrMsg)
{
- //涓婁紶鍓嶅垽鏂槸鍚﹀瓨鍦ㄧ浉鍚屾潯鐮�
- SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
- DataSet ds = oCn.RunProcReturn("exec h_p_WMS_UpLoadControl " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "'", "h_p_WMS_UpLoadControl");
- if (ds == null || ds.Tables[0].Rows.Count == 0)
- {
- }
- else
- {
- if (DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0][0]) == 1)
- {
- sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]);
- return false;
- }
- }
+ ////涓婁紶鍓嶅垽鏂槸鍚﹀瓨鍦ㄧ浉鍚屾潯鐮�
+ //SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
+ //DataSet ds = oCn.RunProcReturn("exec h_p_WMS_UpLoadControl " + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HBillType + "'", "h_p_WMS_UpLoadControl");
+ //if (ds == null || ds.Tables[0].Rows.Count == 0)
+ //{
+ //}
+ //else
+ //{
+ // if (DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0][0]) == 1)
+ // {
+ // sErrMsg = "鍗曟嵁鍙凤細" + oMain.HBillNo + "锛屽崟鎹甀D锛�" + oMain.HInterID + "锛�" + DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HRemark"]);
+ // return false;
+ // }
+ //}
if (sHSourceType == "3710") //鐢熶骇璁㈠崟
{
--
Gitblit v1.9.1