From 874ceff175a7308da045943fb7def1f6c6560a51 Mon Sep 17 00:00:00 2001 From: dengjunjie <dengjunjie@hnkhzn.com> Date: 星期二, 26 三月 2024 11:31:08 +0800 Subject: [PATCH] 优化NG任务触发逻辑 --- 代码管理/PCS/WCS_Server/WIDESEA_WCS/JobsPart/Common/RestockHCJ.cs | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/PCS/WCS_Server/WIDESEA_WCS/JobsPart/Common/RestockHCJ.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/PCS/WCS_Server/WIDESEA_WCS/JobsPart/Common/RestockHCJ.cs" index 98b94fe..14b31a9 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/PCS/WCS_Server/WIDESEA_WCS/JobsPart/Common/RestockHCJ.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/PCS/WCS_Server/WIDESEA_WCS/JobsPart/Common/RestockHCJ.cs" @@ -43,7 +43,7 @@ var area = task.agv_Traytype == "SmallTray" ? "11" : "10"; //鎵�1搴撳尯鐨勭┖鎵樹綅 var EmptyStation = stationinfoRepository.Find(x => x.area == area && x.quantity > 0 && x.stationCode.Contains("A") && x.location_state == "Stroge"/*LocationStateEnum.Stroge.ToString()*/ && x.enable) - .OrderBy(x => x.line).OrderByDescending(x => x.column).FirstOrDefault(); + .OrderBy(x => x.column).OrderBy(x => x.line).FirstOrDefault(); #region 涓�涓尯鍩熷彧鑳芥湁涓�涓┖鎵樹换鍔� //bool ok = false; @@ -55,6 +55,7 @@ #endregion if (EmptyStation == null) EmptyStation = stationinfoRepository.Find(x => x.area == area && x.quantity > 0 && x.stationCode.Contains(area == "10" ? "D" : "C") && x.enable).OrderByDescending(x => x.column).FirstOrDefault(); + if (EmptyStation == null) continue; #region 搴撳唴瀛樺湪浠诲姟鍗犵敤 if (EmptyStation.location_state == LocationStateEnum.Busy.ToString()) continue; -- Gitblit v1.9.3