From c57ec7977738765a3a813d73f20e09a89867e39b Mon Sep 17 00:00:00 2001
From: 647556386 <647556386@qq.com>
Date: 星期四, 10 四月 2025 23:08:36 +0800
Subject: [PATCH] 前端页面更新

---
 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/PalletCodeInfoService.cs |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/PalletCodeInfoService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/PalletCodeInfoService.cs"
index ade79eb..25c032c 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/PalletCodeInfoService.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/PalletCodeInfoService.cs"
@@ -89,6 +89,7 @@
         //    }
         //}
 
+
         public WebResponseContent AddData(int warehouseId, int count, int palletTypeId)
         {
             try
@@ -103,11 +104,10 @@
                     List<Dt_PalletCodeInfo> palletCodeInfos = new List<Dt_PalletCodeInfo>();
                     int serialNo = 0;
                     DateTime now = DateTime.Now;
-                    Dt_PalletCodeInfo palletCodeInfo = BaseDal.QueryFirst(x => x.WarehouseId == warehouseId, new Dictionary<string, OrderByType> { { nameof(Dt_PalletCodeInfo.SerialNo), OrderByType.Desc } });
+                    Dt_PalletCodeInfo palletCodeInfo = BaseDal.QueryFirst(x => x.WarehouseId == warehouseId && x.PalletTypeId==palletTypeId && x.CreateDate.Year == now.Year && x.CreateDate.Month == now.Month && x.CreateDate.Day == now.Day, new Dictionary<string, OrderByType> { { nameof(Dt_PalletCodeInfo.SerialNo), OrderByType.Desc } });
                     if (palletCodeInfo != null && palletCodeInfo.CreateDate.Year == now.Year && palletCodeInfo.CreateDate.Month == now.Month && palletCodeInfo.CreateDate.Day == now.Day)
                     {
                         serialNo = palletCodeInfo.SerialNo + 1;
-
                     }
                     else
                     {
@@ -122,7 +122,7 @@
                             SerialNo = serialNo,
                             PalletCode = palletTypeInfo.CodeStartStr + now.ToString("yyyyMMdd") + serialNo.ToString().PadLeft(3, '0'),
                             PalletType = 1,
-                            PalletTypeId = 0,
+                            PalletTypeId = palletTypeId,
                             WarehouseId = warehouseId,
                             Status = 0,
                             Size = 0
@@ -134,7 +134,7 @@
                 }
                 return WebResponseContent.Instance.OK();
             }
-            catch(Exception ex)
+            catch (Exception ex)
             {
                 return WebResponseContent.Instance.Error(ex.Message);
             }

--
Gitblit v1.9.3