From d03c33eeebd11111ee6c116b35ccf8cd7372de8d Mon Sep 17 00:00:00 2001
From: duhe <226547893@qq.com>
Date: 星期二, 15 四月 2025 12:57:37 +0800
Subject: [PATCH] 提料信息Excel导入:根据宝工客户进行调整

---
 WebAPI/Controllers/SCGL/日计划管理/Sc_JIT_ComplementGoodBillController.cs |  126 +++++++++++++++++++++++------------------
 1 files changed, 71 insertions(+), 55 deletions(-)

diff --git "a/WebAPI/Controllers/SCGL/\346\227\245\350\256\241\345\210\222\347\256\241\347\220\206/Sc_JIT_ComplementGoodBillController.cs" "b/WebAPI/Controllers/SCGL/\346\227\245\350\256\241\345\210\222\347\256\241\347\220\206/Sc_JIT_ComplementGoodBillController.cs"
index 3507868..90989ac 100644
--- "a/WebAPI/Controllers/SCGL/\346\227\245\350\256\241\345\210\222\347\256\241\347\220\206/Sc_JIT_ComplementGoodBillController.cs"
+++ "b/WebAPI/Controllers/SCGL/\346\227\245\350\256\241\345\210\222\347\256\241\347\220\206/Sc_JIT_ComplementGoodBillController.cs"
@@ -467,7 +467,7 @@
                     return objJsonResult;
                 }
 
-                if (oSystemParameter.omodel.WMS_CampanyName != "甯呭▉"&& oSystemParameter.omodel.WMS_CampanyName != "瀹濆伐")
+                if (oSystemParameter.omodel.WMS_CampanyName != "甯呭▉"&& oSystemParameter.omodel.WMS_CampanyName != "瀹濆伐" && oSystemParameter.omodel.WMS_CampanyName != "涓夊崌")
                 {
                     if (oSub.HLeadTime_Sec == 0 || oSub.HLeadTime_Sec == null)
                     {
@@ -807,66 +807,82 @@
                             tb2.Rows[i]["HUnitID"] = ds.Tables[0].Rows[0]["HItemID"].ToString();
                         }
 
-                        //JIT鐗╂枡鍒嗙被
-                        if (JITType == "")
+                        string msg = "";
+                        oSystemParameter.ShowBill(ref msg);
+                        if (oSystemParameter.omodel.WMS_CampanyName == "瀹濆伐")
                         {
-                            objJsonResult.code = "0";
-                            objJsonResult.count = 0;
-                            objJsonResult.Message = "绗�" + index + "琛�,JIT鐗╂枡鍒嗙被涓虹┖锛�";
-                            objJsonResult.data = null;
-                            return objJsonResult;
+                            //JIT渚涜揣鎻愬墠鏈燂紙澶╋級
+                            if (JISLT == "")
+                            {
+                                objJsonResult.code = "0";
+                                objJsonResult.count = 0;
+                                objJsonResult.Message = "绗�" + index + "琛�,JIT渚涜揣鎻愬墠鏈燂紙澶╋級涓虹┖锛�";
+                                objJsonResult.data = null;
+                                return objJsonResult;
+                            }
                         }
-
-                        //JIT鎻愯揣缁忔祹鎵归噺
-                        if (JIPEB == "")
+                        else
                         {
-                            objJsonResult.code = "0";
-                            objJsonResult.count = 0;
-                            objJsonResult.Message = "绗�" + index + "琛�,JIT鎻愯揣缁忔祹鎵归噺涓虹┖锛�";
-                            objJsonResult.data = null;
-                            return objJsonResult;
-                        }
+                            //JIT鐗╂枡鍒嗙被
+                            if (JITType == "")
+                            {
+                                objJsonResult.code = "0";
+                                objJsonResult.count = 0;
+                                objJsonResult.Message = "绗�" + index + "琛�,JIT鐗╂枡鍒嗙被涓虹┖锛�";
+                                objJsonResult.data = null;
+                                return objJsonResult;
+                            }
 
-                        //JIT渚涜揣鎻愬墠鏈燂紙澶╋級
-                        if (JISLT == "")
-                        {
-                            objJsonResult.code = "0";
-                            objJsonResult.count = 0;
-                            objJsonResult.Message = "绗�" + index + "琛�,JIT渚涜揣鎻愬墠鏈燂紙澶╋級涓虹┖锛�";
-                            objJsonResult.data = null;
-                            return objJsonResult;
-                        }
+                            //JIT鎻愯揣缁忔祹鎵归噺
+                            if (JIPEB == "")
+                            {
+                                objJsonResult.code = "0";
+                                objJsonResult.count = 0;
+                                objJsonResult.Message = "绗�" + index + "琛�,JIT鎻愯揣缁忔祹鎵归噺涓虹┖锛�";
+                                objJsonResult.data = null;
+                                return objJsonResult;
+                            }
 
-                        //JIT鍒拌揣鍓嶇疆鏈燂紙澶╋級
-                        if (JIDLT == "")
-                        {
-                            objJsonResult.code = "0";
-                            objJsonResult.count = 0;
-                            objJsonResult.Message = "绗�" + index + "琛�,JIT鍒拌揣鍓嶇疆鏈燂紙澶╋級涓虹┖锛�";
-                            objJsonResult.data = null;
-                            return objJsonResult;
-                        }
+                            //JIT渚涜揣鎻愬墠鏈燂紙澶╋級
+                            if (JISLT == "")
+                            {
+                                objJsonResult.code = "0";
+                                objJsonResult.count = 0;
+                                objJsonResult.Message = "绗�" + index + "琛�,JIT渚涜揣鎻愬墠鏈燂紙澶╋級涓虹┖锛�";
+                                objJsonResult.data = null;
+                                return objJsonResult;
+                            }
 
-                        //JIT鏈�灏忚捣閫侀噺
-                        if (JIMLC == "")
-                        {
-                            objJsonResult.code = "0";
-                            objJsonResult.count = 0;
-                            objJsonResult.Message = "绗�" + index + "琛�,JIT鏈�灏忚捣閫侀噺涓虹┖锛�";
-                            objJsonResult.data = null;
-                            return objJsonResult;
-                        }
+                            //JIT鍒拌揣鍓嶇疆鏈燂紙澶╋級
+                            if (JIDLT == "")
+                            {
+                                objJsonResult.code = "0";
+                                objJsonResult.count = 0;
+                                objJsonResult.Message = "绗�" + index + "琛�,JIT鍒拌揣鍓嶇疆鏈燂紙澶╋級涓虹┖锛�";
+                                objJsonResult.data = null;
+                                return objJsonResult;
+                            }
 
-                        //瀹℃牳浠g爜鏄惁鍚堢悊
-                        if (!DBUtility.ClsPub.AllowNumber(HMaterNumer))
-                        {
-                            objJsonResult.code = "0";
-                            objJsonResult.count = 0;
-                            objJsonResult.Message = "绗�" + index + "琛�,鐗╂枡浠g爜涓笉鑳藉嚭鐜拌繛缁��.鈥欏苟涓旈浣嶆湯浣嶄笉鑳戒负鈥�.鈥欙紒";
-                            objJsonResult.data = null;
-                            return objJsonResult;
-                        }
+                            //JIT鏈�灏忚捣閫侀噺
+                            if (JIMLC == "")
+                            {
+                                objJsonResult.code = "0";
+                                objJsonResult.count = 0;
+                                objJsonResult.Message = "绗�" + index + "琛�,JIT鏈�灏忚捣閫侀噺涓虹┖锛�";
+                                objJsonResult.data = null;
+                                return objJsonResult;
+                            }
 
+                            //瀹℃牳浠g爜鏄惁鍚堢悊
+                            if (!DBUtility.ClsPub.AllowNumber(HMaterNumer))
+                            {
+                                objJsonResult.code = "0";
+                                objJsonResult.count = 0;
+                                objJsonResult.Message = "绗�" + index + "琛�,鐗╂枡浠g爜涓笉鑳藉嚭鐜拌繛缁��.鈥欏苟涓旈浣嶆湯浣嶄笉鑳戒负鈥�.鈥欙紒";
+                                objJsonResult.data = null;
+                                return objJsonResult;
+                            }
+                        }
                     }
                     else
                     {
@@ -967,7 +983,7 @@
                        "HLeadTime, HLeadTime_Sec, HDeliveryMode, HDeliveryDaysCtrl,HUnitID,HJITMinDeliveryQty)values" +
                        $"({HInterID}, 1, '{HRemark}', {(HSupID == "" ? "0" : HSupID)}, '{HSupplierName}', {(HMaterID == "" ? "0" : HMaterID)}," +
                        $" '{HMaterName}', '{HMaterModel}', '{JITType}', {(JITPSL == "" ? "0" : JITPSL)}, {(JITMDSC == "" ? "0" : JITMDSC)},{(JIPEB == "" ? "0" : JIPEB)},{(JITPBCC == "" ? "0" : JITPBCC)}," +
-                       $" {(JISLT == "" ? "0" : JISLT)}, {(JIDLT == "" ? "0" : JIDLT)}, '', {(JITDCD == "" ? "0" : JITDCD)} ,{HUnitID},{JIMLC})";
+                       $" {(JISLT == "" ? "0" : JISLT)}, {(JIDLT == "" ? "0" : JIDLT)}, '', {(JITDCD == "" ? "0" : JITDCD)} ,{HUnitID},{(JIMLC==""?"0": JIMLC)})";
                         //涓昏〃
                         oCN.RunProc(sql);
                         //瀛愯〃
@@ -1179,7 +1195,7 @@
                     objJsonResult.data = null;
                     return objJsonResult;
                 }
-                if (oSystemParameter.omodel.WMS_CampanyName != "瀹濆伐")
+                if (oSystemParameter.omodel.WMS_CampanyName != "瀹濆伐"&& oSystemParameter.omodel.WMS_CampanyName != "涓夊崌")
                 {
                     if (oSub.HDeliveryDaysCtrl == 0 || oSub.HDeliveryDaysCtrl == null)
                     {

--
Gitblit v1.9.1