From b5995a148f7a9e66b7042313487b1d76e07e0845 Mon Sep 17 00:00:00 2001
From: ch <37327@LLOOCCY>
Date: 星期二, 28 六月 2022 08:44:38 +0800
Subject: [PATCH] 新增了采购看板、缺料看板、车间看板

---
 WebAPI/Controllers/CGGL/Kf_POStockInBillController.cs |   40 +++++++++++++++++++++-------------------
 1 files changed, 21 insertions(+), 19 deletions(-)

diff --git a/WebAPI/Controllers/CGGL/Kf_POStockInBillController.cs b/WebAPI/Controllers/CGGL/Kf_POStockInBillController.cs
index 1e37d71..5b7139a 100644
--- a/WebAPI/Controllers/CGGL/Kf_POStockInBillController.cs
+++ b/WebAPI/Controllers/CGGL/Kf_POStockInBillController.cs
@@ -60,7 +60,8 @@
         }
 
         /// <summary>
-        /// 杩斿洖鏀舵枡閫氱煡鍗曞垪琛�
+        /// --杩斿洖鏀舵枡閫氱煡鍗曞垪琛�
+        /// 澶栬喘鍏ュ簱鍗� 1201
         ///鍙傛暟锛歴tring sql銆�
         ///杩斿洖鍊硷細object銆�
         /// </summary>
@@ -72,30 +73,31 @@
             {
                 if (sWhere == null || sWhere.Equals(""))
                 {
-                    ds = oCN.RunProcReturn("select * from h_v_Kf_POStockInBillList " + sWhere, "h_v_Kf_POStockInBillList");
+                    ds = oCN.RunProcReturn("select * from h_v_Kf_POStockInBillList order by hmainid desc", "h_v_Kf_POStockInBillList");
                 }
                 else
                 {
                     string sql1 = "select * from h_v_Kf_POStockInBillList where 1 = 1 ";
-                    string sql = sql1 + sWhere;
+                    string sql = sql1 + sWhere+ " order by hmainid desc";
                     ds = oCN.RunProcReturn(sql, "h_v_Kf_POStockInBillList");
                 }
-                if (ds == null || ds.Tables[0].Rows.Count == 0)
-                {
-                    objJsonResult.code = "0";
-                    objJsonResult.count = 0;
-                    objJsonResult.Message = "娌℃湁杩斿洖浠讳綍璁板綍锛�";
-                    objJsonResult.data = null;
-                    return objJsonResult;
-                }
-                else
-                {
-                    objJsonResult.code = "1";
-                    objJsonResult.count = 1;
-                    objJsonResult.Message = "Sucess锛�";
-                    objJsonResult.data = ds.Tables[0];
-                    return objJsonResult;
-                }
+
+                //if (ds.Tables[0].Rows.Count != 0 || ds != null)
+                //{
+                objJsonResult.code = "1";
+                objJsonResult.count = 1;
+                objJsonResult.Message = "Sucess锛�";
+                objJsonResult.data = ds.Tables[0];
+                return objJsonResult;
+                //}
+                //else
+                //{
+                //objJsonResult.code = "0";
+                //objJsonResult.count = 0;
+                //objJsonResult.Message = "鏃犳暟鎹�";
+                //objJsonResult.data = null;
+                //return objJsonResult;
+                //}
             }
             catch (Exception e)
             {

--
Gitblit v1.9.1