From acdbefae8e00a3d32b17fd23c95ad31c73d9566f Mon Sep 17 00:00:00 2001
From: zzr99 <1940172413@qq.com>
Date: 星期二, 07 六月 2022 09:57:39 +0800
Subject: [PATCH] nothing

---
 WebAPI/Controllers/SCGL/Sc_ComplementGoodBillController.cs |   19 ++++++++++---------
 1 files changed, 10 insertions(+), 9 deletions(-)

diff --git a/WebAPI/Controllers/SCGL/Sc_ComplementGoodBillController.cs b/WebAPI/Controllers/SCGL/Sc_ComplementGoodBillController.cs
index 8475e02..6e9855f 100644
--- a/WebAPI/Controllers/SCGL/Sc_ComplementGoodBillController.cs
+++ b/WebAPI/Controllers/SCGL/Sc_ComplementGoodBillController.cs
@@ -99,6 +99,7 @@
             public long HSourceEntryID = 0;//HSourceEntryIDCol
             public int? 鍙枡鏁伴噺 = 0;//HBHGQtyCol
             public int? 宸插彨鏂欐暟閲� = 0;//HBHGQtyCol
+            public int? 宸查厤閫佹暟閲� = 0;//HBHGQtyCol
             public double? 閫�鏂欐暟閲� = 0;//閫�鏂欐暟閲�
             public long HSTOCKID = 0;//HSTOCKID
             public string 閫�鏂欏師鍥� { get; set; }//閫�鏂欏師鍥�
@@ -384,11 +385,11 @@
                 {
                     if (listCa[i].閫�鏂欐暟閲� > 0)
                     {
-                        if (listCa[i].閫�鏂欐暟閲� > listCa[i].宸插彨鏂欐暟閲�)
+                        if (listCa[i].閫�鏂欐暟閲� > listCa[i].宸查厤閫佹暟閲�)
                         {
                             objJsonResult.code = "0";
                             objJsonResult.count = 0;
-                            objJsonResult.Message = "閫�鏂欐暟閲忓ぇ浜庡凡鍙枡鏁伴噺!";
+                            objJsonResult.Message = "閫�鏂欐暟閲忓ぇ浜庡凡閰嶉�佹暟閲�!";
                             objJsonResult.data = null;
                             return objJsonResult;
                         }
@@ -396,7 +397,7 @@
                         ds = oCN.RunProcReturn("select sum(HQty) from JIT_CallGoodsBackRequestBillSub " +
                    $"where HSourceInterID={listCa[i].HSouceInterID} and HSourceEntryID ={listCa[i].HSourceEntryID} and HSourceBillNo = '{listCa[i].HSourceBillNo}' and HMaterID={listCa[i].HMaterialID}", "JIT_CallGoodsBackRequestBillSub");
 
-                        if ((double.Parse(ds.Tables[0].Rows[0][0].ToString())+listCa[i].閫�鏂欐暟閲�) > listCa[i].宸插彨鏂欐暟閲�)
+                        if ((double.Parse(ds.Tables[0].Rows[0][0].ToString()==""?"0": ds.Tables[0].Rows[0][0].ToString()) +listCa[i].閫�鏂欐暟閲�) > listCa[i].宸插彨鏂欐暟閲�)
                         {
                             objJsonResult.code = "0";
                             objJsonResult.count = 0;
@@ -521,11 +522,11 @@
                 {
                     if (listCa[i].閫�鏂欐暟閲� > 0)
                     {
-                        if (listCa[i].閫�鏂欐暟閲� > listCa[i].宸插彨鏂欐暟閲�)
+                        if (listCa[i].閫�鏂欐暟閲� > listCa[i].宸查厤閫佹暟閲�)
                         {
                             objJsonResult.code = "0";
                             objJsonResult.count = 0;
-                            objJsonResult.Message = "閫�鏂欐暟閲忓ぇ浜庡凡鍙枡鏁伴噺!";
+                            objJsonResult.Message = "閫�鏂欐暟閲忓ぇ浜庡凡閰嶉�佹暟閲�!";
                             objJsonResult.data = null;
                             return objJsonResult;
                         }
@@ -533,7 +534,7 @@
                         ds = oCN.RunProcReturn("select sum(HQty) from JIT_CallGoodsBackRequestBillSub " +
                 $"where HSourceInterID={listCa[i].HSouceInterID} and HSourceEntryID ={listCa[i].HSourceEntryID} and HSourceBillNo = '{listCa[i].HSourceBillNo}' and HMaterID={listCa[i].HMaterialID}", "JIT_CallGoodsBackRequestBillSub");
 
-                        if ((double.Parse(ds.Tables[0].Rows[0][0].ToString()) + listCa[i].閫�鏂欐暟閲�) > listCa[i].宸插彨鏂欐暟閲�)
+                        if ((double.Parse(ds.Tables[0].Rows[0][0].ToString() == "" ? "0" : ds.Tables[0].Rows[0][0].ToString()) + listCa[i].閫�鏂欐暟閲�) > listCa[i].宸插彨鏂欐暟閲�)
                         {
                             objJsonResult.code = "0";
                             objJsonResult.count = 0;
@@ -618,11 +619,11 @@
                 {
                     if (listCa[i].閫�鏂欐暟閲� > 0)
                     {
-                        if (listCa[i].閫�鏂欐暟閲� > listCa[i].宸插彨鏂欐暟閲�)
+                        if (listCa[i].閫�鏂欐暟閲� > listCa[i].宸查厤閫佹暟閲�)
                         {
                             objJsonResult.code = "0";
                             objJsonResult.count = 0;
-                            objJsonResult.Message = "閫�鏂欐暟閲忓ぇ浜庡凡鍙枡鏁伴噺!";
+                            objJsonResult.Message = "閫�鏂欐暟閲忓ぇ浜庡凡閰嶉�佹暟閲�!";
                             objJsonResult.data = null;
                             return objJsonResult;
                         }
@@ -630,7 +631,7 @@
                         ds = oCN.RunProcReturn("select sum(HQty) from JIT_CallGoodsBackRequestBillSub " +
                $"where HSourceInterID={listCa[i].HSouceInterID} and HSourceEntryID ={listCa[i].HSourceEntryID} and HSourceBillNo = '{listCa[i].HSourceBillNo}' and HMaterID={listCa[i].HMaterialID}", "JIT_CallGoodsBackRequestBillSub");
 
-                        if ((double.Parse(ds.Tables[0].Rows[0][0].ToString()) + listCa[i].閫�鏂欐暟閲�) > listCa[i].宸插彨鏂欐暟閲�)
+                        if ((double.Parse(ds.Tables[0].Rows[0][0].ToString() == "" ? "0" : ds.Tables[0].Rows[0][0].ToString()) + listCa[i].閫�鏂欐暟閲�) > listCa[i].宸插彨鏂欐暟閲�)
                         {
                             objJsonResult.code = "0";
                             objJsonResult.count = 0;

--
Gitblit v1.9.1