From ea3b8223434673ca6d911bfcd6cdcafa773cb5f0 Mon Sep 17 00:00:00 2001
From: qinchulong <qinchulong@hnkhzn.com>
Date: 星期一, 03 三月 2025 22:01:01 +0800
Subject: [PATCH] 更新入库逻辑

---
 项目代码/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/GZJ/GZJJob.cs |   16 +++++++++++++++-
 1 files changed, 15 insertions(+), 1 deletions(-)

diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/GZJ/GZJJob.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/GZJ/GZJJob.cs"
index 674b8c5..549a68f 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/GZJ/GZJJob.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/GZJ/GZJJob.cs"
@@ -95,6 +95,7 @@
                         var station=_dt_stationInfoRepository.QueryFirst(v=>v.msg== "涓滆法鏋跺瓙");
                         task.SourceAddress = station.Row + "-" + station.Column + "-1";
                         task.TargetAddress = _locationInfoService.GetInLocation(storagemode.storagemode).LocationCode;
+                        
                         task.Grade = 1;
                         task.Remark = (int)MateTypeEnum.ZiChan;
                     }
@@ -146,10 +147,23 @@
                     {
                         throw new Exception($"瑙勬暣鏈哄綋鍓嶄俊鍙蜂笉婊¤冻鍏ュ簱浠诲姟鐢熸垚鏉′欢");
                     }
+                    //鏌ユ壘鐩搁偦鐨勫簱浣�
+                    Dt_LocationInfo Towlocation = new Dt_LocationInfo();
+                    var Onelocation = _LocationInfoRepository.QueryFirst(v => v.LocationCode == task.TargetAddress);
+                    if (Onelocation.Depth == 1)
+                    {
+                        Towlocation = _LocationInfoRepository.QueryFirst(v => v.Row == Onelocation.Row && v.Column == Onelocation.Column && v.Depth == 2);
+                    }
+                    else
+                    {
+                        Towlocation = _LocationInfoRepository.QueryFirst(v => v.Row == Onelocation.Row && v.Column == Onelocation.Column && v.Depth == 1);
+                    }
+                    task.NextAddress = Towlocation.LocationCode;
                     task.Roadway = "TC01";
                     task.TaskType = (int)TaskInboundTypeEnum.Inbound;
                     task.TaskState = (int)TaskInStatusEnum.InNew;
-
+                    task.PalletCode = "text";
+                    task.CurrentAddress = "text";
                     _dt_taskRepositiry.AddData(task);
 
                     #endregion

--
Gitblit v1.9.3